1

I have a problem using antlr4. I installed it using brew install antlr and pip install antlr4-python3-runtime.

Now when I want to use it with antlr4 -Dlanguage=Python3 PSLGrammar.g4.

But this results in those 3 errors:

ssl.SSLCertVerificationError: [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: unable to get local issuer certificate (_ssl.c:1131)

urllib.error.URLError: <urlopen error [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: unable to get local issuer certificate (_ssl.c:1131)>

FileNotFoundError: [Errno 2] No such file or directory: '/Users/lucas/.m2/repository/org/antlr/antlr4'

I already tried the fix with executing Install Certificates.command inside my Python application folder.

Any other ideas?

Lucas Winkler
  • 51
  • 1
  • 8
  • How did you install antlr4? Remove the .m2 subdirectory, and retype `pip install antlr4-tools`. Then, type antlr4 and make sure you get the tool help output. Verify the antlr tool .jar is somewhere under .m2/ (use `find`). – kaby76 Apr 08 '23 at 01:56
  • @kaby76 I used pip3 install antlr4-tools and I am getting the same error. I have manually added antlr4-4.x.jar and antlr4-4.x-complete.jar as well. Can you please point out what I am missing here. – Supersic Jul 27 '23 at 19:32
  • actually, Install Certificates.command worked for me. @lucas try creating a symlink https://stackoverflow.com/questions/52805115/certificate-verify-failed-unable-to-get-local-issuer-certificate – Supersic Jul 27 '23 at 20:45

0 Answers0