-
-
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
The i18n gem does not work in AOT mode #4416
Comments
Interestingly, the |
This is minor and we're trying to get 9.1.7.0. Assigning to 9.2, since that would be a nice time to work out any remaining kinks in the JIT. |
getting a different failures (same without rake loader being loaded) - most are variations of :
... I do seem to be having issues starting this up with current master (targeted for 9.1.7) |
@headius there definitely seems to be a regression when running FORCE compiled on master :
|
@kares Ahh, thank you for bisecting. I'll look into that. Might be able to just revert those changes and fix the issue in a different way. |
Looks like something wrong with how we do load versus running target script directly. If I put... module Foo
end ...in a file, I can -X+C that file just fine, but if I load it under -X+C it produces that same TypeError. |
Good news! It seems the fix was simpler than we expected. The problem appears to be that we weren't testing the top-level "container" module when loading scripts with AOT. As a result, any modules or classes they attempted to define would raise that TypeError, because the containing module (into which they would be defined) was null. My fix is being tested in #4431, but I confirmed it lets both i18n's test suite and one of our own suites both run properly (and all green) with AOT enabled. |
@glebm If you can confirm with a JRuby master build, we'd appreciate it. I was able to run i18n tests fine with this patch. rvm install jruby-head should work, but it's pretty easy to clone and build too. See BUILDING.md. |
Environment
Expected Behavior
The i18n gem test suite passes in AOT mode:
Actual Behavior
The text was updated successfully, but these errors were encountered: