lektor/lektor-markdown-highlighter

ClassNotFound: no lexer for alias u'yaml=' found

Closed this issue ยท 4 comments

roll commented

Hi,

Thanks for the very useful plugin.

We had spotless experience using it for a long period of time but we run into a very weird problem around a month ago.

It stopped to understand yaml syntax on Travis. It works locally ๐Ÿ˜•. Here is a build log:

https://travis-ci.org/frictionlessdata/website/builds/400004280

Could you please take a look?

cc @serahrono

I noticed that an earlier successful build used v0.1 of lektor-markdown-highlighter, but a new failure used v0.2. That's a clue perhaps, but, not much has changed here. That might be a red herring.

I was hoping to find a different pygments version, since I suspect this is more their problem, but its the same in both builds.

Did you only recently add yaml code blocks?

The error looks like just what you would get if you actually had ```yaml+= starting off a code block in markdown, but I don't see that in some of the error prone contents.lr files in your repo. And I doubt you'd have suddenly included so many anyway. I'm not sure what's causing this. Perhaps see if the pygments folk have an idea?

You could pass the verbose flag with lektor [server/build/deploy] -v, and that should get a traceback to be output. That may help.

roll commented

@nixjdm
Thank you very much for such a quick answer and help!

lektor ... -v was a key to find the issue. Because of the lektor-markdown-header-anchors plugin, the error was mentioned for every page. After anchors removal, I figured out that we dynamically pull some contents on the Travis build stage. And yes it uses yaml= and yaml=+ (probably thanks to hackmd.io). It was a pure fun to had 0 yaml mentions (ag yaml) in the codebase on some point of debugging and still getting this error ๐Ÿ˜– ๐Ÿ˜„

Thanks again. Fixed on our side.