Summary
Upgrading the embedded Python dependencies from requests==2.32.5 / charset_normalizer==3.4.5 to requests==2.33.1 / charset_normalizer==3.4.6 causes an embedded GraalPy application to fail at runtime with:
LookupError: no such codec is supported.
We hit this in the graalvm/graal-languages-demos repo in the GraalPy Micronaut and Spring Boot guides. The checked-in GraalPy/GraalVM version did not change; only the resolved Python dependency set drifted.
Environment
- GraalPy plugin / runtime:
25.0.2
- JVM test runtime: Oracle GraalVM JDK
21.0.8+12.1
- Embedded mode via GraalPy build tools / VFS
- Reproduced locally on 2026-04-01
Dependency change
Last passing embedded env resolved:
requests==2.32.5
charset_normalizer==3.4.5
urllib3==2.6.3
idna==3.11
certifi==2026.2.25
vader-sentiment==3.2.1.1
Failing embedded env resolved:
requests==2.33.1
charset_normalizer==3.4.6
urllib3==2.6.3
idna==3.11
certifi==2026.2.25
vader-sentiment==3.2.1.1
Reproduction shape
In Java, we create an embedded GraalPy context and evaluate:
from vader_sentiment.vader_sentiment import SentimentIntensityAnalyzer
SentimentIntensityAnalyzer()
With the newer dependency set, bean initialization fails and the embedded eval throws:
Caused by: LookupError: LookupError: no such codec is supported.
at <python>.<module>(Unknown)
at org.graalvm.polyglot.Context.eval(Context.java:449)
This is the local failure we reproduced in the Micronaut example:
Message: LookupError: no such codec is supported.
Path Taken:
new o.e.SentimentAnalysisController(SentimentAnalysis sentimentAnalysis)
---> new o.e.SentimentAnalysisController([SentimentAnalysis sentimentAnalysis])
Caused by: LookupError: LookupError: no such codec is supported.
at <python>.<module>(Unknown)
at org.graalvm.polyglot.Context.eval(Context.java:449)
at org.example.SentimentAnalysis.<init>(SentimentAnalysis.java:20)
Workaround
Pinning the embedded Python dependencies back to:
requests==2.32.5
charset_normalizer==3.4.5
makes the same local reproduction pass again.
Notes
The exact codec name is not included in the thrown exception text, but vader_sentiment initializes using codecs.open(..., encoding="utf-8"), so this may be related to codec availability / registration during embedded startup or transitive imports in this dependency combination.
If useful, I can provide a reduced reproducer based on the GraalPy Micronaut guide setup.
Summary
Upgrading the embedded Python dependencies from
requests==2.32.5/charset_normalizer==3.4.5torequests==2.33.1/charset_normalizer==3.4.6causes an embedded GraalPy application to fail at runtime with:We hit this in the
graalvm/graal-languages-demosrepo in the GraalPy Micronaut and Spring Boot guides. The checked-in GraalPy/GraalVM version did not change; only the resolved Python dependency set drifted.Environment
25.0.221.0.8+12.1Dependency change
Last passing embedded env resolved:
requests==2.32.5charset_normalizer==3.4.5urllib3==2.6.3idna==3.11certifi==2026.2.25vader-sentiment==3.2.1.1Failing embedded env resolved:
requests==2.33.1charset_normalizer==3.4.6urllib3==2.6.3idna==3.11certifi==2026.2.25vader-sentiment==3.2.1.1Reproduction shape
In Java, we create an embedded GraalPy context and evaluate:
With the newer dependency set, bean initialization fails and the embedded eval throws:
This is the local failure we reproduced in the Micronaut example:
Workaround
Pinning the embedded Python dependencies back to:
requests==2.32.5charset_normalizer==3.4.5makes the same local reproduction pass again.
Notes
The exact codec name is not included in the thrown exception text, but
vader_sentimentinitializes usingcodecs.open(..., encoding="utf-8"), so this may be related to codec availability / registration during embedded startup or transitive imports in this dependency combination.If useful, I can provide a reduced reproducer based on the GraalPy Micronaut guide setup.