Skip to content
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

javac-parser is broken with Python >= 3.10 #6

Open
williamjallen opened this issue Mar 24, 2024 · 0 comments
Open

javac-parser is broken with Python >= 3.10 #6

williamjallen opened this issue Mar 24, 2024 · 0 comments

Comments

@williamjallen
Copy link

I get the following error when importing javac_parser with Python 3.10 and above:

Traceback (most recent call last):
  File ..., line 1, in </module><module>
    import javac_parser
  File "/usr/local/lib/python3.10/dist-packages/javac_parser/__init__.py", line 19, in </module><module>
    from .javac_parser import Java
  File "/usr/local/lib/python3.10/dist-packages/javac_parser/javac_parser.py", line 28, in </module><module>
    from py4j.java_gateway import JavaGateway, launch_gateway, GatewayParameters
  File "/usr/local/lib/python3.10/dist-packages/py4j/java_gateway.py", line 2336, in </module><module>
    __import__("py4j.java_collections")
  File "/usr/local/lib/python3.10/dist-packages/py4j/java_collections.py", line 13, in </module><module>
    from collections import (
ImportError: cannot import name 'MutableMapping' from 'collections' (/usr/lib/python3.10/collections/__init__.py)

This appears to be coming from your usage of py4j. Can you update py4j to get this working again?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant