-
-
Notifications
You must be signed in to change notification settings - Fork 7.9k
[Bug]: ImportError: /home/travis/miniconda/envs/env/lib/python3.11/lib-dynload/pyexpat.cpython-311-x86_64-linux-gnu.so: undefined symbol: XML_SetReparseDeferralEnabled #28235
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
Comments
I'm not too sure there is much for us to do here... the line in matplotlib that is failing is an import of a standard library module (plistlib). In particular, the comment on the above thread that is directed to "Linux distro maintainers" indicates that care must be taken to ensure that It looks like you are using conda, so the same caution would apply to the source of your python installation (either upstream anaconda main or e.g. conda forge) My first recommendation would be to ensure that all updates are applied, as a compatible expat appears to be available on conda. It looks like conda forge does not provide a pin for expat version in the python recipe: All that said, and while I stand by my assessment that the primary problem is upstream packaging here, plistlib is, I believe, only actually used in MacOS specific code (other than the import)... so I think we could possibly move the import such that it doesn't happen on other platforms. I do believe you would still have problems with other xml tasks which use the stdlib module, though, so while the specific problem could be mitigated, it is not a full solution. |
I see what you mean by standard library, however, the reason why |
Yes, we did introduce that import in this version, that much is true. But I still think it is mostly just indicating a broken upstream package chain, that likely is fixed by ensuring upgrades are applied. |
I tried this in a new environment:
and it imports fine. Then I also tried with |
Ah, ok, got it. π We are able to address it like this: sudo apt install libexpat1 libexpat1-dev but it feels like I shouldn't need to do that. In our case, the travis config looks like this:
and then we use a more or less conventional conda installation (from The main suspect that I see in all that is that we're using jammy. Maybe that's just too old? Or that at some point someone will update it? Ok, feel free to close this issue. |
I would have expected you to get expat from conda, actually, but yeah, CPython introduced a version dependency on expat. |
For me I was on python 3.12 and expat 3.6.2 on conda so I downgraded expat with |
Bug summary
New failure in our ci this morning
Code for reproduction
Actual outcome
Expected outcome
no exception
Additional information
No response
Operating system
Ubuntu 22.04.3 LTS
Matplotlib Version
matplotlib-3.9.0-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Matplotlib Backend
No response
Python version
3.11
Jupyter version
n/a
Installation
pip
The text was updated successfully, but these errors were encountered: