sphinx-immaterial icon indicating copy to clipboard operation
sphinx-immaterial copied to clipboard

Theme does not work with rST Vscode Extension

Open twodrops opened this issue 3 years ago • 3 comments

I really like the immaterial theme, but it does not work with rST VsCode Extension. The problem is with the language server (Esbonio) used by the extension that it crashes with the async Google font download.

I did not find a way to turn off the font download. It would be nice, if the font download is made optional.

twodrops avatar Sep 22 '22 16:09 twodrops

Can you post anything that tells us why the font is causing the extension to crash?

If it is a problem with the path to the fonts not being relative to the sphinx-build output, then you can use the config option sphinx_immaterial_external_resource_cache_dir to tell the theme to download the fonts to your project's docs' build folder.

2bndy5 avatar Sep 22 '22 16:09 2bndy5

Unfortunately the extension does not seem to write much about this problem on the console even with debug log level.

/usr/local/lib/python3.10/site-packages/esbonio/lsp/sphinx/init.py:164: RuntimeWarning: coroutine 'add_google_fonts..do_fetch' was never awaited

sphinx_immaterial_external_resource_cache_dir worked well with local build but not with the build triggered by the extension,

There is some suggestion by the Esbonio developers here https://github.com/swyddfa/esbonio/issues/451#issuecomment-1255633191

twodrops avatar Sep 23 '22 04:09 twodrops

Maybe it is notable to say that I am using a VsCode DevContainer. But most other themes work fine with this setup and Esbonio.

twodrops avatar Sep 23 '22 04:09 twodrops

Solution released in v0.11.4

2bndy5 avatar May 31 '23 21:05 2bndy5