Closed tachyonicClock closed 1 month ago
All modified and coverable lines are covered by tests :white_check_mark:
Project coverage is 87.21%. Comparing base (
09f325f
) to head (e2e60a5
).
:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.
Looks like I have some maintenance tasks before the CI will run.
@Thrameos I'm working on a test and it seems emoji still don't work although that appears to be a different reason.
The emoji thing seems to be a problem with java itself
java -classpath "😊/mypackage.jar" mypackage.MyClass
Error: A JNI error has occurred, please check your installation and try again
Exception in thread "main" java.lang.IllegalArgumentException: Error decoding percent encoded characters
at java.base/sun.net.www.ParseUtil.decode(ParseUtil.java:218)
at java.base/jdk.internal.loader.FileURLMapper.getPath(FileURLMapper.java:64)
...
I am hoping it is safe to ignore emoji. Although a coworker of mine had great fun using the poop emoji when we added internationalization to string conversions, I think that it is an edge case.
It is also a good idea to add a line to "doc/CHANGELOG.rst" describing the change so that others will know it is fixes. Thanks for taking the time to add tests.
Since Java appears to have difficulties with emojis in classpaths, it's probably impossible to fix this issue. The important thing is to support non-English character sets that are likely in user paths. That is the problem that prompted me to open this issue in the first place. Although a poop emoji directory does sound like a good place to store certain parts of java :D.
I've added my changes to the changelog. Let me know if its not in the right place or the wording is bad.
Honestly I do not understand right now, why the pipeline isnt converging. On the main branch everything was fine.
@tachyonicClock I think the hung tests are due to the process creation within the new regression test. Could you please check, if using https://pypi.org/project/pytest-forked/ and marking the test with the provided marker could be a solution?
@pytest.mark.forked
def test_with_leaky_state():
run_some_monkey_patches()
This would require of course to install pytest-forked for the test suite. It should go to test-requirements.txt. Thank you!
I fixed the hanging issue and packaged it with the related tests in test_startup.py
. These are run as sub-processes using `subrun'. I'm running into an issue with them failing on Windows. I'll try to fix this later this week.
Last week I tried fixing this on windows but ran into some other issues related to UTF-8 vs UTF-16 character encoding on Windows in the JNI. It will likely take me a little longer to figure out a solution or workaround.
@tachyonicClock Thanks for your work on this so far! Any updates on this one? We would like to conclude a set of changes for the next release and I would like to include this fix if it also works on Windows.
native/java/org/jpype/pkg/JPypePackageManager.java
). A pre-existing fix removed % signs if '%2520'
was present. This did not fix doubly encoded Unicode characters and risked removing % signs that were intentional. The new version will work in these cases.project/jars/unicode_à😎
to describe how to build the Unicode jar test case. I tried to follow the pattern of other examples, but I'm not confident I did this correctly.
Fix #1194