Skip to content

Issue with mkdocs / cairocffi #1382

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
dornech opened this issue Sep 1, 2024 · 2 comments
Open

Issue with mkdocs / cairocffi #1382

dornech opened this issue Sep 1, 2024 · 2 comments
Labels
Procedure Procedure

Comments

@dornech
Copy link

dornech commented Sep 1, 2024

I have some trouble using mkdocs because I run into this error using WinPython:
https://squidfunk.github.io/mkdocs-material/plugins/requirements/image-processing/#troubleshooting
Problem seems to be cairocffi not finding the cairo library.

After some investigation I found that the cairo library is present at %WINPYDIR%\Lib\site-packages\wx.

Furthermore I found out that cairocffi supports an environment variable CAIROCFFI_DLL_DIRECTORIES.
I thought setting this in env.bat would fix the problem but it did not. I added it to PATH as well. This did work.

...
:after_pyzo_conf


rem ******************
rem handle cairocffi / wx if included
rem ******************
set tmp_pyz=%WINPYDIR%\Lib\site-packages\wx
if not exist "%tmp_pyz%" goto end_wx_conf
set CAIROCFFI_DLL_DIRECTORIES=%WINPYDIR%\Lib\site-packages\wx
set "PATH=%WINPYDIR%\Lib\site-packages\wx;%PATH%;"
:end_wx_conf


set tmp_pyz


rem ******************
rem WinPython.ini part (removed from nsis)
rem ******************
...
@dornech dornech changed the title Issue with mkdocs / cairoffi Issue with mkdocs / cairocffi Sep 1, 2024
@stonebig
Copy link
Contributor

stonebig commented Sep 1, 2024

Unless the given package handles it less manually, this is a possible workaround

@dornech
Copy link
Author

dornech commented Sep 1, 2024

Well, I thought as such workarounds are implemented for qt5 and others, this might be an option ...

@stonebig stonebig added the Procedure Procedure label May 4, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Procedure Procedure
Projects
None yet
Development

No branches or pull requests

2 participants