-
-
Notifications
You must be signed in to change notification settings - Fork 925
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
Encoding issue in jruby 9.0.0.0 #3267
Comments
@deivid-rodriguez Could you try adding env var: JRUBY_OPTS='-J-Dfile.encoding=UTF-8' and see if this goes away? I am trying to fix this without requiring that but I am curious if this fixes the problem for you. |
I forgot to mention that I tried that and didn't work either. Thanks! |
@deivid-rodriguez ok. Yeah something which reduces this to a script we can run and see the issue will allow us to fix it the quickest. |
Here you go!
should do it. |
This will work but I was hoping to have something which ran as a single file and did not require loading a big env. |
This is a default Rails app plus I can further isolate the problem, but it's unlikely that I get the time to do it before October. Thanks for your work! |
@deivid-rodriguez ok I will fix the other known encoding issues and circle back to this. Having a reproduction is great in that we can at least know if it has been addressed. Thanks for that. I just get greedy and want it localized more :) |
@enebo That sounds great, I will circle back here as well if I get the time to further localize the issue for you! |
I believe I've narrowed this down to: "".force_encoding('US-ASCII').match("Període\\ de\\ retorn".force_encoding('UTF-8')) Investigating. |
I have a fix. We do not follow the correct path for constructing the regexp from the match string, and so the encoding does not get negotiated correctly. |
Thanks!! |
Hi!
My tests pass under MRI 2.2.3 but fail under jruby 9.0.0.0. This is the error I'm getting:
Adding magic utf-8 comments where the utf-8 string is defined does not help.
I'll try to post a proper reproduction if necessary, I just wanted to get feedback about it first in case this is a known issue.
Thanks!
The text was updated successfully, but these errors were encountered: