pprzetacznik / IElixir

Jupyter's kernel for Elixir programming language
Apache License 2.0
357 stars 44 forks source link

Pygments lexer name correct? #29

Closed cdegroot closed 6 years ago

cdegroot commented 7 years ago

https://github.com/pprzetacznik/IElixir/blob/master/lib/ielixir/socket/shell.ex#L54 sets the Pygments lexer name to its class name, but that seems to trigger an error in my version of Jupyter when triggering its use:

opt/anaconda3/lib/python3.6/site-packages/nbconvert/filters/highlight.py:131: UserWarning: No lexer found for language 'pygments.lexers.erlang.ElixirLexer'. Treating as plain text.
warn("No lexer found for language %r. Treating as plain text." % language)

When I manually edit the notebook to just specify "Elixir", the error doesn't appear. Interactive testing shows the same - Pygments' get_lexer_by_name seems to expect just "Elixir", not the full classname.

Maybe my version? I'm running Anaconda 4.3.0 on Linux with Python3, which includes Jupyter 4.2.1.

pprzetacznik commented 7 years ago

Hi @cdegroot, can you test it right now as I have updated packages and changed lexer in there? Thx in advance.