Odd UnsupportedCharsetException

Hi,

I wanted to try out mechanize on jruby and ran into some problems. I’m
using 1.4.0 on windows xp and it’s mechanize 0.9.3 and nokogiri 1.4.1.

It all works fine on OSX and my laptop windows machine, but on my work
desktop I’m receiving a weird charset exception. It looks like it may be
more jruby/java related than gem related so using this list.

All I’m doing is from jirb:
agent = WWW::Mechanize.get
agent.get(“http://www.google.com”)

and it bombs out with with the error given at end of message.

my java version is the following both on laptop and desktop:
java version “1.6.0_17”
Java™ SE Runtime Environment (build 1.6.0_17-b04)
Java HotSpot™ Client VM (build 14.3-b01, mixed mode, sharing)

Any ideas of where to start digging on this?

Error message:
null:-1:in forName': java.nio.charset.UnsupportedCharsetException: x-JISAutoDetect from RubyNKF.java:128:in guess’
from org/jruby/RubyNKF$s_method_1_0$RUBYINVOKER$guess.gen:-1:in
call' from CachingCallSite.java:310:in cacheAndCall’
from CachingCallSite.java:149:in call' from CallOneArgNode.java:57:in interpret’
from LocalAsgnNode.java:123:in interpret' from NewlineNode.java:104:in interpret’
from BlockNode.java:71:in interpret' from InterpretedMethod.java:173:in call’
from DefaultMethod.java:169:in call' from CachingCallSite.java:310:in cacheAndCall’
from CachingCallSite.java:149:in call' from CallOneArgNode.java:57:in interpret’
from InstAsgnNode.java:95:in interpret' from OpAsgnOrNode.java:105:in interpret’
from NewlineNode.java:104:in interpret' from BlockNode.java:71:in interpret’
from InterpretedMethod.java:229:in call' from DefaultMethod.java:193:in call’
from CachingCallSite.java:340:in cacheAndCall' from CachingCallSite.java:198:in callBlock’
from CachingCallSite.java:203:in call' from RubyClass.java:720:in call’
from DynamicMethod.java:184:in call' from CachingCallSite.java:330:in cacheAndCall’
from CachingCallSite.java:189:in call' from CallTwoArgNode.java:59:in interpret’
from LocalAsgnNode.java:123:in interpret' from NewlineNode.java:104:in interpret’
from IfNode.java:117:in interpret' from NewlineNode.java:104:in interpret’
from IfNode.java:119:in interpret' from NewlineNode.java:104:in interpret’
from BlockNode.java:71:in interpret' from InterpretedMethod.java:173:in call’
from DefaultMethod.java:169:in call' from CachingCallSite.java:310:in cacheAndCall’
from CachingCallSite.java:149:in call' from CallOneArgNode.java:57:in interpret’
from NewlineNode.java:104:in interpret' from RootNode.java:129:in interpret’
from ASTInterpreter.java:98:in evalWithBinding' from RubyKernel.java:966:in eval’
from
org/jruby/RubyKernel$s_method_0_3$RUBYFRAMEDINVOKER$eval.gen:-1:in
call' from DynamicMethod.java:150:in call’
from CachingCallSite.java:67:in call' from FCallManyArgsNode.java:60:in interpret’
from NewlineNode.java:104:in interpret' from InterpretedMethod.java:112:in call’
from InterpretedMethod.java:124:in call' from DefaultMethod.java:144:in call’
from CachingCallSite.java:67:in call' from CallManyArgsNode.java:59:in interpret’
from FCallOneArgNode.java:36:in interpret' from NewlineNode.java:104:in interpret’
from BlockNode.java:71:in interpret' from InterpretedMethod.java:210:in call’
from DefaultMethod.java:185:in call' from CachingCallSite.java:187:in call’
from CallTwoArgNode.java:59:in interpret' from NewlineNode.java:104:in interpret’
from BlockNode.java:71:in interpret' from RescueNode.java:225:in executeBody’
from RescueNode.java:147:in interpretWithJavaExceptions' from RescueNode.java:110:in interpret’
from BeginNode.java:83:in interpret' from NewlineNode.java:104:in interpret’
from BlockNode.java:71:in interpret' from InterpretedBlock.java:317:in evalBlockBody’
from InterpretedBlock.java:251:in yield' from InterpretedBlock.java:185:in yieldSpecific’
from Block.java:99:in yieldSpecific' from ZYieldNode.java:25:in interpret’
from NewlineNode.java:104:in interpret' from EnsureNode.java:96:in interpret’
from BeginNode.java:83:in interpret' from NewlineNode.java:104:in interpret’
from BlockNode.java:71:in interpret' from InterpretedMethod.java:192:in call’
from DefaultMethod.java:177:in call' from CachingCallSite.java:156:in callBlock’
from CachingCallSite.java:173:in callIter' from FCallOneArgBlockNode.java:34:in interpret’
from NewlineNode.java:104:in interpret' from InterpretedBlock.java:317:in evalBlockBody’
from InterpretedBlock.java:216:in yieldSpecific' from Block.java:117:in yieldSpecific’
from YieldTwoNode.java:31:in interpret' from NewlineNode.java:104:in interpret’
from IfNode.java:117:in interpret' from NewlineNode.java:104:in interpret’
from BlockNode.java:71:in interpret' from RescueNode.java:225:in executeBody’
from RescueNode.java:147:in interpretWithJavaExceptions' from RescueNode.java:110:in interpret’
from BeginNode.java:83:in interpret' from NewlineNode.java:104:in interpret’
from InterpretedBlock.java:317:in evalBlockBody' from InterpretedBlock.java:268:in yield’
from Block.java:194:in yield' from RubyKernel.java:1182:in loop_1_9’
from
org/jruby/RubyKernel$s_method_0_0$RUBYFRAMEDINVOKER$loop_1_9.gen:-1:in
call' from CachingCallSite.java:300:in cacheAndCall’
from CachingCallSite.java:118:in callBlock' from CachingCallSite.java:133:in callIter’
from FCallNoArgBlockNode.java:32:in interpret' from NewlineNode.java:104:in interpret’
from InterpretedBlock.java:317:in evalBlockBody' from InterpretedBlock.java:268:in yield’
from Block.java:194:in yield' from RubyKernel.java:1014:in rbCatch’
from
org/jruby/RubyKernel$s_method_1_0$RUBYFRAMEDINVOKER$rbCatch.gen:-1:in
call' from CachingCallSite.java:320:in cacheAndCall’
from CachingCallSite.java:158:in callBlock' from CachingCallSite.java:173:in callIter’
from FCallOneArgBlockNode.java:34:in interpret' from NewlineNode.java:104:in interpret’
from BlockNode.java:71:in interpret' from InterpretedMethod.java:155:in call’
from DefaultMethod.java:161:in call' from CachingCallSite.java:300:in cacheAndCall’
from CachingCallSite.java:118:in callBlock' from CachingCallSite.java:123:in call’
from CallNoArgBlockNode.java:64:in interpret' from NewlineNode.java:104:in interpret’
from BlockNode.java:71:in interpret' from InterpretedMethod.java:136:in call’
from DefaultMethod.java:153:in call' from CachingCallSite.java:290:in cacheAndCall’
from CachingCallSite.java:109:in call' from CallNoArgNode.java:61:in interpret’
from NewlineNode.java:104:in interpret' from InterpretedBlock.java:317:in evalBlockBody’
from InterpretedBlock.java:268:in yield' from Block.java:194:in yield’
from RubyKernel.java:1014:in rbCatch' from org/jruby/RubyKernel$s_method_1_0$RUBYFRAMEDINVOKER$rbCatch.gen:-1:in call’
from CachingCallSite.java:320:in cacheAndCall' from CachingCallSite.java:158:in callBlock’
from CachingCallSite.java:173:in callIter' from FCallOneArgBlockNode.java:34:in interpret’
from NewlineNode.java:104:in interpret' from BlockNode.java:71:in interpret’
from InterpretedMethod.java:173:in call' from DefaultMethod.java:169:in call’
from CachingCallSite.java:310:in cacheAndCall' from CachingCallSite.java:149:in call’
from jirb:19:in __file__' from jirb:-1:in load’
from Ruby.java:628:in runScript' from Ruby.java:550:in runNormally’
from Ruby.java:396:in runFromMain' from Main.java:272:in run’
from Main.java:117:in run' from Main.java:97:in main’

Hi Patrik,

Strange error indeed. I tried on my system, and no problem so far, so
I can 't reproduce it.

Maybe it depends on what google.com returns, since it does some magic
behind the scenes and determines the language based on IP, so for me
it returns www.google.de content.

I wonder what it returns in your cases (and I bet that there are two
different results, one of which causes the exception)…

Thanks,
–Vladimir

On Tue, Jan 5, 2010 at 11:04 AM, Patrik S. [email protected]
wrote:

agent = WWW::Mechanize.get
Any ideas of where to start digging on this?
from CachingCallSite.java:149:in call' from OpAsgnOrNode.java:105:in interpret’
from CachingCallSite.java:189:in call' from CachingCallSite.java:310:in cacheAndCall’
from CachingCallSite.java:67:in call' from InterpretedMethod.java:210:in call’
from BlockNode.java:71:in interpret' from InterpretedMethod.java:192:in call’
from IfNode.java:117:in interpret' from RubyKernel.java:1182:in loop_1_9’
from Block.java:194:in yield' from InterpretedMethod.java:155:in call’
from CachingCallSite.java:109:in call' from CachingCallSite.java:158:in callBlock’
from Ruby.java:628:in `runScript’

http://xircles.codehaus.org/manage_email


To unsubscribe from this list, please visit:

http://xircles.codehaus.org/manage_email

On the other hand, looking at the exception, it seems that there is no
x-JISAutoDetect decoder could be found…

What does this print for you?

jruby -rjava -e “p
java.nio.charset.Charset.forName(‘x-JISAutoDetect’).newDecoder”

This could be a problem with x32 JRE on Windows XP, it seems. If you
downloaded Java from java.com (meaning, small JRE), then such
installation won’t have charsets.jar which is required for
x-JISAutoDetect.

Try to install full version from java.sun.com or just copy
charsets.jar to JRE’s lib dir, that should do the trick, I just
verified that.

Thanks,
–Vladimir

On Tue, Jan 5, 2010 at 12:19 PM, Vladimir S. [email protected]
wrote:

different results, one of which causes the exception)…

It all works fine on OSX and my laptop windows machine, but on my work
java version “1.6.0_17”
x-JISAutoDetect
from DefaultMethod.java:169:in call' from CachingCallSite.java:198:in callBlock’
from IfNode.java:119:in interpret' from RubyKernel.java:966:in eval’
from CachingCallSite.java:67:in call' from RescueNode.java:225:in executeBody’
from NewlineNode.java:104:in interpret' from InterpretedBlock.java:317:in evalBlockBody’
from BeginNode.java:83:in interpret' from CachingCallSite.java:133:in callIter’
from CachingCallSite.java:158:in callBlock' from NewlineNode.java:104:in interpret’
from RubyKernel.java:1014:in rbCatch' from DefaultMethod.java:169:in call’

Posted via http://www.ruby-forum.com/.


To unsubscribe from this list, please visit:

http://xircles.codehaus.org/manage_email


To unsubscribe from this list, please visit:

http://xircles.codehaus.org/manage_email

Vladimir S. wrote:

Try to install full version from java.sun.com or just copy
charsets.jar to JRE’s lib dir, that should do the trick, I just
verified that.

I removed all JRE/JDK and jruby related things and resinstalled. Now
works fine on desktop as well. Some sort of pilot error on my part when
installing things before.

Thanks

Hi Patrik,

The bug has been fixed on master branch now, patch Koichiro Ohba. Now,
for those JREs that doesn’t have charsets.jar (like the
non-internationalized JRE from java.com), JRuby will print Ruby-level
error with the info what’s wrong and how to solve id, instead of
java-level crash.

Thanks,
–Vladimir

On Tue, Jan 5, 2010 at 4:11 PM, Patrik S. [email protected]
wrote:


Posted via http://www.ruby-forum.com/.


To unsubscribe from this list, please visit:

http://xircles.codehaus.org/manage_email


To unsubscribe from this list, please visit:

http://xircles.codehaus.org/manage_email

Vladimir S. wrote:

Hi Patrik,

The bug has been fixed on master branch now, patch Koichiro Ohba. Now,
for those JREs that doesn’t have charsets.jar (like the
non-internationalized JRE from java.com), JRuby will print Ruby-level
error with the info what’s wrong and how to solve id, instead of
java-level crash.

Thanks,
–Vladimir

Please i am having the same problem as Patrick. I tried the solutions
above with no luck!!! Any suggestions?

On Tue, Jan 5, 2010 at 4:11 PM, Patrik S. [email protected]
wrote:

Vladimir S. wrote:

Try to install full version from java.sun.com or just copy
charsets.jar to JRE’s lib dir, that should do the trick, I just
verified that.

I removed all JRE/JDK and jruby related things and resinstalled. Now
works fine on desktop as well. Some sort of pilot error on my part when
installing things before.

I’ve also filed: http://jira.codehaus.org/browse/JRUBY-4417
“NKF.guess crashes JRuby in some cases”

Thanks,
–Vladimir


To unsubscribe from this list, please visit:

http://xircles.codehaus.org/manage_email

Hi Felipe,

The only proper solution is to install proper Java (JDK or JRE,
doesn’t matter) from java.sun.com:

http://java.sun.com/javase/downloads/index.jsp

Thanks,
–Vladimir

On Sat, Jan 16, 2010 at 8:58 PM, Felipe Mattosinho
[email protected] wrote:

–Vladimir

http://xircles.codehaus.org/manage_email


To unsubscribe from this list, please visit:

http://xircles.codehaus.org/manage_email

Hi Vladimir,

What do you mean from proper java? Well i just downloaded the JDK 6
update 18 from Sun’s web site. Then i unistalled all the previous
version, cleaned my registry and installed the new one again. The
problem persist!
What would be the right one?!
Thanks for your fast reply!!!

Vladimir S. wrote:

Hi Felipe,

The only proper solution is to install proper Java (JDK or JRE,
doesn’t matter) from java.sun.com:

http://java.sun.com/javase/downloads/index.jsp

Thanks,
–Vladimir

On Sat, Jan 16, 2010 at 8:58 PM, Felipe Mattosinho
[email protected] wrote:

� --Vladimir

� �http://xircles.codehaus.org/manage_email


To unsubscribe from this list, please visit:

http://xircles.codehaus.org/manage_email

Hi Felipe,

On Sun, Jan 17, 2010 at 12:05 AM, Felipe Mattosinho
[email protected] wrote:

What do you mean from proper java?

One needs full international Java version from java.sun.com site
(not the small JRE from java.com).

Well i just downloaded the JDK 6
update 18 from Sun’s web site. Then  i unistalled all the previous
version, cleaned my registry and installed the new one again. The
problem persist!

Interesting. Let’s assume that the directory where you installed JDK6
is D:/java6.
You should have the following JAR file in your installation:

D:/java6/jre/lib/charsets.jar

Do you have it? That’s the first thing to check.

If you do, but still having problems, make sure you do use this
particular version of java when launching JRuby.
What jruby -v does print for you? Is %JAVA_HOME% correct?

Thanks,
–Vladimir

To unsubscribe from this list, please visit:


To unsubscribe from this list, please visit:

http://xircles.codehaus.org/manage_email

When I was still on the Windows platform I remember a common problem
being
that some Java installers put a java.exe in C:\Windows or
C:\Windows\system32 leading to all kinds of version problems.

I don’t know how the jruby startup scripts/executable determines which
java
to run, but it might be a good idea to check if you have a .exe in the
above
mentioned folders and if so simply remove it.

//Peter

Interesting. Let’s assume that the directory where you installed JDK6
is D:/java6.
You should have the following JAR file in your installation:
D:/java6/jre/lib/charsets.jar

Yes the installation is correct. I have it under my folder C:\Program
Files\Java\jdk1.6.0_18 which is the folder pointed by JAVA_HOME
Also, the jdk1.6 update 18 is the last release downloaded at Sun’s web
site.
Then under C:\Program Files\Java\jdk1.6.0_18\jre\lib , i have the file
charsets.jar.

Do you have it? That’s the first thing to check.

If you do, but still having problems, make sure you do use this
particular version of java when launching JRuby.
What jruby -v does print for you? Is %JAVA_HOME% correct?

This is exactly what jruby -v prints out for me. That was expected
right?

jruby -v

jruby 1.4.0(ruby 1.8.7 patchlevel 174) (2009-11-02 69fbfa3) (Java
HotSpot™ Client VM 1.6.0_18) [x86-java]

Thanks for your help!

Felipe

Peter Sönnergren Lind wrote:

When I was still on the Windows platform I remember a common problem
being
that some Java installers put a java.exe in C:\Windows or
C:\Windows\system32 leading to all kinds of version problems.

I don’t know how the jruby startup scripts/executable determines which
java
to run, but it might be a good idea to check if you have a .exe in the
above
mentioned folders and if so simply remove it.

//Peter

Unfortunately this trick didnt work for me! I think i will give up, and
I’ll assume that this a problem with my machine with java and jruby
togheter, some underlying installation problem…

Thanks a lot

On Sun, Jan 17, 2010 at 5:59 PM, Felipe Mattosinho
[email protected] wrote:

Unfortunately this trick didnt work for me! I think i will give up, and
I’ll assume that this a problem with my machine with java and jruby
togheter, some underlying installation problem…

Could you try to copy the charsets.jar to JRuby’s lib directory, so it
will get included in JRuby’s startup classpath (that works on on
Windows, right Vladimir)?

Bear with us :slight_smile: we want to make it work for you, so it will work for
the next person after you that has the same problem.

  • Charlie

To unsubscribe from this list, please visit:

http://xircles.codehaus.org/manage_email

Could you try to copy the charsets.jar to JRuby’s lib directory, so it
will get included in JRuby’s startup classpath (that works on on
Windows, right Vladimir)?

After following your hint, the error now changed to the following

An unexpected error has been detected by Java Runtime Environment:

EXCEPTION_ACCESS_VIOLATION (0xc0000005) at pc=0x7c91b1fa, pid=5848,

tid=6068

Java VM: Java HotSpot™ Client VM (11.0-b15 mixed mode windows-x86)

Problematic frame:

C [ntdll.dll+0x1b1fa]

An error report file with more information is saved as:

C:\Documents and Settings\Administrador\Meus documentos\Aptana

Projects\TheProject\hs_err_pid5848.log

If you would like to submit a bug report, please visit:

Bug Report

The crash happened outside the Java Virtual Machine in native code.

See problematic frame for where to report the bug.

I just want to remember that the same application works flawlessly with
Ruby. I wanted to use JRuby however to extend with some JAVA API that i
will need in the future. As the owner of this post already said, these
are the gems that i am using.
Mechanize(0.9.3)
Nokogiri(1.4.1)

Bear with us :slight_smile: we want to make it work for you, so it will work for
the next person after you that has the same problem.

  • Charlie

Ok i’ll stay with you guys. Thanks again

Regards,

I wanted to put the log generated by the system as an attachment , put i
cant, it says it is too large. So i copied some parts (i took the stack
out of it) at the end of this post.
The strange thing that i noticed is that jruby -v
prints

“jruby 1.4.0(ruby 1.8.7 patchlevel 174) (2009-11-02 69fbfa3) (Java
HotSpot™ Client VM 1.6.0_18) [x86-java]”

And at the bottom (the very end) of this log file that i am sending ,
under SYSTEM sector my VM is the following:

“vm_info: Java HotSpot™ Client VM (11.0-b15) for windows-x86 JRE
(1.6.0_10-b33), built on Sep 26 2008 01:00:43 by “java_re” with MS VC++
7.1”

Isnt it strange?!

An unexpected error has been detected by Java Runtime Environment:

EXCEPTION_ACCESS_VIOLATION (0xc0000005) at pc=0x7c91b1fa, pid=5848,

tid=6068

Java VM: Java HotSpot™ Client VM (11.0-b15 mixed mode windows-x86)

Problematic frame:

C [ntdll.dll+0x1b1fa]

If you would like to submit a bug report, please visit:

Bug Report

The crash happened outside the Java Virtual Machine in native code.

See problematic frame for where to report the bug.

--------------- T H R E A D ---------------

Current thread (0x172d3000): JavaThread “Thread-5” daemon
[_thread_in_native, id=6068, stack(0x18400000,0x18500000)]

siginfo: ExceptionCode=0xc0000005, writing address 0x00000010

Registers:
EAX=0x00000000, EBX=0x00000000, ECX=0x0000143c, EDX=0x185e7b00
ESP=0x184f4f24, EBP=0x184f4f98, ESI=0x185e7af0, EDI=0x00000000
EIP=0x7c91b1fa, EFLAGS=0x00010246

Top of Stack: (sp=0x184f4f24)
0x184f4f24: 17908cd8 17908ef0 179055e0 00000000
0x184f4f34: 184f4f74 7c90e900 7c9101c0 ffffffff
0x184f4f44: 7c9101bb 77c0c3c9 17900000 00000000
0x184f4f54: 77c0c3ce 17908cd8 1369a208 179055e0
0x184f4f64: ffffffff 7c802600 184f4f58 00001440
0x184f4f74: 184ffc64 77c15c94 77bf2088 ffffffff
0x184f4f84: 77c0c3ce 77c0c3e7 0000000c 00000000
0x184f4f94: 0000143c 184f4fc8 7c901046 005e7af0

Instructions: (pc=0x7c91b1fa)
0x7c91b1ea: 8b 46 10 3b c3 89 45 fc 0f 84 9e 00 00 00 8b 06
0x7c91b1fa: ff 40 10 8b 45 fc 83 e0 01 89 45 e8 8b 06 ff 40

Stack: [0x18400000,0x18500000], sp=0x184f4f24, free space=979k
Native frames: (J=compiled Java code, j=interpreted, Vv=VM code,
C=native code)
C [ntdll.dll+0x1b1fa]
C [ntdll.dll+0x1046]
j com.kenai.jffi.Foreign.invokeVrI(J)I+0
j com.kenai.jffi.Invoker.invokeVrI(Lcom/kenai/jffi/Function;)I+8
j
oy/runtime/builtin/IRubyObject;Ljava/lang/String;Lorg/jruby/runtime/Block;)Lorg/jruby/runtime/builtin/IRubyObject;
j
org.jruby.RubyObject.send(Lorg/jruby/runtime/ThreadContext;Lorg/jruby/runtime/builtin/IRubyObject;Lorg/jruby/runtime/Block;)Lorg/jruby/runtime/builtin/IRubyObject;+17

--------------- P R O C E S S ---------------

Java Threads: ( => current thread )
0x17363800 JavaThread “Thread-7” daemon [_thread_blocked, id=772,
stack(0x18800000,0x18900000)]
=>0x172d3000 JavaThread “Thread-5” daemon [_thread_in_native, id=6068,
stack(0x18400000,0x18500000)]
0x172ca800 JavaThread “Thread-2” daemon [_thread_in_native, id=4816,
stack(0x18300000,0x18400000)]
0x16c34c00 JavaThread “Low Memory Detector” daemon [_thread_blocked,
id=4644, stack(0x17140000,0x17240000)]
0x16c2e800 JavaThread “CompilerThread0” daemon [_thread_blocked,
id=5836, stack(0x170f0000,0x17140000)]
0x16c2d000 JavaThread “Attach Listener” daemon [_thread_blocked,
id=4756, stack(0x16ff0000,0x170f0000)]
0x16c2bc00 JavaThread “Signal Dispatcher” daemon [_thread_blocked,
id=1228, stack(0x16ef0000,0x16ff0000)]
0x16c1bc00 JavaThread “Finalizer” daemon [_thread_blocked, id=2684,
stack(0x16df0000,0x16ef0000)]
0x16c17400 JavaThread “Reference Handler” daemon [_thread_blocked,
id=4408, stack(0x16cf0000,0x16df0000)]
0x002b6800 JavaThread “main” [_thread_blocked, id=2080,
stack(0x008c0000,0x009c0000)]

Other Threads:
0x16c12400 VMThread [stack: 0x16ca0000,0x16cf0000] [id=4360]
0x16c48400 WatcherThread [stack: 0x17240000,0x17290000] [id=1432]

VM state:not at safepoint (normal execution)

VM Mutex/Monitor currently owned by a thread: None

Heap
def new generation total 3008K, used 1377K [0x02a40000, 0x02d80000,
0x03df0000)
eden space 2688K, 40% used [0x02a40000, 0x02b4f710, 0x02ce0000)
from space 320K, 91% used [0x02ce0000, 0x02d28fb8, 0x02d30000)
to space 320K, 0% used [0x02d30000, 0x02d30000, 0x02d80000)
tenured generation total 39332K, used 26074K [0x03df0000, 0x06459000,
0x12a40000)
the space 39332K, 66% used [0x03df0000, 0x05766a08, 0x05766c00,
0x06459000)
compacting perm gen total 20992K, used 20837K [0x12a40000, 0x13ec0000,
0x16a40000)
the space 20992K, 99% used [0x12a40000, 0x13e99570, 0x13e99600,
0x13ec0000)
No shared spaces configured.

Dynamic libraries:
0x00400000 - 0x00424000 C:\Arquivos de programas\Aptana
Studio\jre\bin\java.exe
0x7c900000 - 0x7c9b3000 C:\WINDOWS\system32\ntdll.dll
0x7c800000 - 0x7c900000 C:\WINDOWS\system32\kernel32.dll
0x77f50000 - 0x77ffb000 C:\WINDOWS\system32\ADVAPI32.dll
0x77db0000 - 0x77e42000 C:\WINDOWS\system32\RPCRT4.dll
0x77f20000 - 0x77f31000 C:\WINDOWS\system32\Secur32.dll
0x7c340000 - 0x7c396000 C:\Arquivos de programas\Aptana
Studio\jre\bin\msvcr71.dll
0x6d800000 - 0x6da56000 C:\Arquivos de programas\Aptana
Studio\jre\bin\client\jvm.dll
0x7e360000 - 0x7e3f1000 C:\WINDOWS\system32\USER32.dll
0x77e50000 - 0x77e99000 C:\WINDOWS\system32\GDI32.dll
0x76b20000 - 0x76b4e000 C:\WINDOWS\system32\WINMM.dll
0x76360000 - 0x7637d000 C:\WINDOWS\system32\IMM32.DLL
0x6d280000 - 0x6d288000 C:\Arquivos de programas\Aptana
Studio\jre\bin\hpi.dll
0x76bd0000 - 0x76bdb000 C:\WINDOWS\system32\PSAPI.DLL
0x6d7b0000 - 0x6d7bc000 C:\Arquivos de programas\Aptana
Studio\jre\bin\verify.dll
0x6d320000 - 0x6d33f000 C:\Arquivos de programas\Aptana
Studio\jre\bin\java.dll
0x6d7f0000 - 0x6d7ff000 C:\Arquivos de programas\Aptana
Studio\jre\bin\zip.dll
0x6d560000 - 0x6d569000 C:\Arquivos de programas\Aptana
Studio\jre\bin\management.dll
0x178a0000 - 0x178f2000 C:\WINDOWS\jna22835.tmp
0x77bf0000 - 0x77c48000 C:\WINDOWS\system32\msvcrt.dll
0x6d610000 - 0x6d623000 C:\Arquivos de programas\Aptana
Studio\jre\bin\net.dll
0x71a70000 - 0x71a87000 C:\WINDOWS\system32\WS2_32.dll
0x71a60000 - 0x71a68000 C:\WINDOWS\system32\WS2HELP.dll
0x6d630000 - 0x6d639000 C:\Arquivos de programas\Aptana
Studio\jre\bin\nio.dll
0x67e40000 - 0x67e50000 C:\WINDOWS\jffi22836.tmp
0x7c9c0000 - 0x7d1de000 C:\WINDOWS\system32\shell32.dll
0x77ea0000 - 0x77f16000 C:\WINDOWS\system32\SHLWAPI.dll
0x773b0000 - 0x774b3000
C:\WINDOWS\WinSxS\x86_Microsoft.Windows.Common-Controls_6595b64144ccf1df_6.0.2600.5512_x-ww_35d4ce83\comctl32.dll
0x769a0000 - 0x76a55000 C:\WINDOWS\system32\USERENV.dll
0x5bcb0000 - 0x5bd05000 C:\WINDOWS\system32\netapi32.dll
0x18150000 - 0x1816a000 C:\Arquivos de programas\HTTP Debugger
Pro\mfnsp32.dll
0x71a10000 - 0x71a50000 C:\WINDOWS\system32\mswsock.dll
0x60b30000 - 0x60b88000 C:\WINDOWS\system32\hnetcfg.dll
0x18260000 - 0x182d2000 c:\arquivos de programas\http debugger
pro\mfnhks32.dll
0x71a50000 - 0x71a58000 C:\WINDOWS\System32\wshtcpip.dll
0x68000000 - 0x68036000 C:\WINDOWS\system32\rsaenh.dll
0x76f00000 - 0x76f27000 C:\WINDOWS\system32\DNSAPI.dll
0x76f90000 - 0x76f98000 C:\WINDOWS\System32\winrnr.dll
0x76f40000 - 0x76f6d000 C:\WINDOWS\system32\WLDAP32.dll
0x18610000 - 0x18635000 C:\Arquivos de programas\Bonjour\mdnsNSP.dll
0x76d40000 - 0x76d59000 C:\WINDOWS\system32\Iphlpapi.dll
0x76fa0000 - 0x76fa6000 C:\WINDOWS\system32\rasadhlp.dll
0x18500000 - 0x185f1000 C:\Arquivos de
programas\jruby-1.4.0\lib\ruby\gems\1.8\gems\nokogiri-1.4.1-java\ext\nokogiri\libxml2.dll
0x71a90000 - 0x71a9a000 C:\WINDOWS\system32\WSOCK32.dll
0x18670000 - 0x18749000 C:\Arquivos de
programas\jruby-1.4.0\lib\ruby\gems\1.8\gems\nokogiri-1.4.1-java\ext\nokogiri\iconv.dll
0x18750000 - 0x18762000 C:\Arquivos de
programas\jruby-1.4.0\lib\ruby\gems\1.8\gems\nokogiri-1.4.1-java\ext\nokogiri\zlib1.dll
0x18770000 - 0x1879c000 C:\Arquivos de
programas\jruby-1.4.0\lib\ruby\gems\1.8\gems\nokogiri-1.4.1-java\ext\nokogiri\libxslt.dll
0x187a0000 - 0x187b0000 C:\Arquivos de
programas\jruby-1.4.0\lib\ruby\gems\1.8\gems\nokogiri-1.4.1-java\ext\nokogiri\libexslt.dll

VM Arguments:
jvm_args: -Xverify:none -Xmx256m -Xss1024k -Djruby.base=C:\Arquivos de
programas\jruby-1.4.0 -Djruby.home=C:\Arquivos de programas\jruby-1.4.0
-Djruby.lib=C:\Arquivos de programas\jruby-1.4.0\lib
-Djruby.shell=cmd.exe -Djruby.script=jruby.bat
java_command: org.jruby.Main -e RUBY_PLATFORM=‘java mswin’ -e
load(ARGV.shift) – script/server mongrel --port=3003
–environment=development
Launcher Type: SUN_STANDARD

Environment Variables:
JAVA_HOME=C:\Arquivos de programas\Aptana Studio\jre
CLASSPATH=.

--------------- S Y S T E M ---------------

OS: Windows XP Build 2600 Service Pack 3

CPU:total 1 (1 cores per cpu, 1 threads per core) family 15 model 36
stepping 2, cmov, cx8, fxsr, mmx, sse, sse2, sse3, mmxext, 3dnow,
3dnowext

Memory: 4k page, physical 1046704k(72680k free), swap 2517996k(1030452k
free)

vm_info: Java HotSpot™ Client VM (11.0-b15) for windows-x86 JRE
(1.6.0_10-b33), built on Sep 26 2008 01:00:43 by “java_re” with MS VC++
7.1

time: Mon Jan 18 05:38:57 2010
elapsed time: 45 seconds

On Sun, Jan 17, 2010 at 10:57 PM, Felipe Mattosinho
[email protected] wrote:

“jruby 1.4.0(ruby 1.8.7 patchlevel 174) (2009-11-02 69fbfa3) (Java
HotSpot™ Client VM 1.6.0_18) [x86-java]”

Perhaps it’s time we had you try a 1.5-dev build…

And at the bottom (the very end) of this log file that i am sending ,
under SYSTEM sector my VM is the following:

“vm_info: Java HotSpot™ Client VM (11.0-b15) for windows-x86 JRE
(1.6.0_10-b33), built on Sep 26 2008 01:00:43 by “java_re” with MS VC++
7.1”

As you discovered, Aptana is using a rather old version of Java 6, but
I don’t think this is the cause of the crash…

Stack: [0x18400000,0x18500000], Â sp=0x184f4f24, Â free space=979k
Native frames: (J=compiled Java code, j=interpreted, Vv=VM code,
C=native code)
C Â [ntdll.dll+0x1b1fa]
C Â [ntdll.dll+0x1046]
j  com.kenai.jffi.Foreign.invokeVrI(J)I+0
j  com.kenai.jffi.Invoker.invokeVrI(Lcom/kenai/jffi/Function;)I+8

The crash is happening in FFI, probably when invoking some function
for Nokogiri. This is why I think it may be a good idea to try
1.5-dev, since there have been many FFI fixes and we’ve moved to a
different backend library. Would you be willing to give it a shot?
http://ci.jruby.org/snapshots has nightly builds.

  • Charlie

To unsubscribe from this list, please visit:

http://xircles.codehaus.org/manage_email

Just one more thing. As it is possible to see by the log file i am using
aptana studio. And aptana mantains a copy of the jre inside their
folder, that is the reason for the other version. Despite that, I am
starting my application directly at the command shell on windows, and i
am receiving the same problem.
The only difference is the Java version, as expected!

A fatal error has been detected by the Java Runtime Environment:

EXCEPTION_ACCESS_VIOLATION (0xc0000005) at pc=0x7c91b1fa, pid=4996,

tid=4492

JRE version: 6.0_18-b07

Java VM: Java HotSpot™ Client VM (16.0-b13 mixed mode, sharing

windows-x86
)

Problematic frame:

C [ntdll.dll+0x1b1fa]

An error report file with more information is saved as:

C:\Documents and Settings\Administrador\Meus documentos\Aptana

Projects\ThePro
ject\hs_err_pid4996.log

If you would like to submit a bug report, please visit:

Bug Report

The crash happened outside the Java Virtual Machine in native code.

See problematic frame for where to report the bug.

Perhaps it’s time we had you try a 1.5-dev build…

Hi Charlie,I installed the 1.5 dev as you said, but that didn’t help me!
Here is part of my new log file generated by the same crash message from
the last message. Of course i erased some information from the stack
part, as the file had 140 kb of data!

A fatal error has been detected by the Java Runtime Environment:

EXCEPTION_ACCESS_VIOLATION (0xc0000005) at pc=0x7c91b1fa, pid=3808,

tid=3192

JRE version: 6.0_18-b07

Java VM: Java HotSpot™ Client VM (16.0-b13 mixed mode, sharing

windows-x86 )

Problematic frame:

C [ntdll.dll+0x1b1fa]

If you would like to submit a bug report, please visit:

Bug Report

The crash happened outside the Java Virtual Machine in native code.

See problematic frame for where to report the bug.

--------------- T H R E A D ---------------

Current thread (0x03a53800): JavaThread “Thread-6” daemon
[_thread_in_native, id=3192, stack(0x041f0000,0x042f0000)]

siginfo: ExceptionCode=0xc0000005, writing address 0x00000010

Registers:
EAX=0x00000000, EBX=0x00000000, ECX=0x00000444, EDX=0x043d7b00
ESP=0x042e4c94, EBP=0x042e4d08, ESI=0x043d7af0, EDI=0x00000000
EIP=0x7c91b1fa, EFLAGS=0x00010246

Top of Stack: (sp=0x042e4c94)
0x042e4c94: 003ea510 003ea728 003e6d50 00000000
0x042e4ca4: 042e4ce4 7c90e900 7c9101c0 ffffffff
0x042e4cb4: 7c9101bb 77c0c3c9 003e0000 00000000
0x042e4cc4: 77c0c3ce 003ea510 331ed290 003e6d50
0x042e4cd4: ffffffff 7c802600 042e4cc8 00000448
0x042e4ce4: 042efad8 77c15c94 77bf2088 ffffffff
0x042e4cf4: 77c0c3ce 77c0c3e7 0000000c 00000000
0x042e4d04: 00000444 042e4d48 7c901046 003d7af0

Instructions: (pc=0x7c91b1fa)
0x7c91b1ea: 8b 46 10 3b c3 89 45 fc 0f 84 9e 00 00 00 8b 06
0x7c91b1fa: ff 40 10 8b 45 fc 83 e0 01 89 45 e8 8b 06 ff 40

Stack: [0x041f0000,0x042f0000], sp=0x042e4c94, free space=3d3042e47c8k
Native frames: (J=compiled Java code, j=interpreted, Vv=VM code,
C=native code)
C [ntdll.dll+0x1b1fa]
C [ntdll.dll+0x1046]
j com.kenai.jffi.Foreign.invokeVrI(J)I+0
j com.kenai.jffi.Invoker.invokeVrI(Lcom/kenai/jffi/Function;)I+8

Dynamic libraries:
0x00400000 - 0x0041d000 C:\jruby-1.5.0\bin\jruby.exe
0x7c900000 - 0x7c9b3000 C:\WINDOWS\system32\ntdll.dll
0x7c800000 - 0x7c900000 C:\WINDOWS\system32\kernel32.dll
0x77f50000 - 0x77ffb000 C:\WINDOWS\system32\ADVAPI32.DLL
0x77db0000 - 0x77e42000 C:\WINDOWS\system32\RPCRT4.dll
0x77f20000 - 0x77f31000 C:\WINDOWS\system32\Secur32.dll
0x77bf0000 - 0x77c48000 C:\WINDOWS\system32\msvcrt.dll
0x7e360000 - 0x7e3f1000 C:\WINDOWS\system32\USER32.dll
0x77e50000 - 0x77e99000 C:\WINDOWS\system32\GDI32.dll
0x76360000 - 0x7637d000 C:\WINDOWS\system32\IMM32.DLL
0x684c0000 - 0x684ec000 C:\jruby-1.5.0\bin\jruby.dll
0x71a70000 - 0x71a87000 C:\WINDOWS\system32\WS2_32.DLL
0x71a60000 - 0x71a68000 C:\WINDOWS\system32\WS2HELP.dll
0x6d8b0000 - 0x6db47000 C:\Arquivos de
programas\Java\jdk1.6.0_18\jre\bin\client\jvm.dll
0x76b20000 - 0x76b4e000 C:\WINDOWS\system32\WINMM.dll
0x7c340000 - 0x7c396000 C:\Arquivos de
programas\Java\jdk1.6.0_18\jre\bin\MSVCR71.dll
0x6d860000 - 0x6d86c000 C:\Arquivos de
programas\Java\jdk1.6.0_18\jre\bin\verify.dll
0x6d3e0000 - 0x6d3ff000 C:\Arquivos de
programas\Java\jdk1.6.0_18\jre\bin\java.dll
0x6d340000 - 0x6d348000 C:\Arquivos de
programas\Java\jdk1.6.0_18\jre\bin\hpi.dll
0x76bd0000 - 0x76bdb000 C:\WINDOWS\system32\PSAPI.DLL
0x6d8a0000 - 0x6d8af000 C:\Arquivos de
programas\Java\jdk1.6.0_18\jre\bin\zip.dll
0x6d6c0000 - 0x6d6d3000 C:\Arquivos de
programas\Java\jdk1.6.0_18\jre\bin\net.dll
0x6d6e0000 - 0x6d6e9000 C:\Arquivos de
programas\Java\jdk1.6.0_18\jre\bin\nio.dll
0x6b5c0000 - 0x6b5d5000
C:\jruby-1.5.0\lib\native\i386-Windows\jffi-0.6.dll
0x7c9c0000 - 0x7d1de000 C:\WINDOWS\system32\shell32.dll
0x77ea0000 - 0x77f16000 C:\WINDOWS\system32\SHLWAPI.dll
0x773b0000 - 0x774b3000
C:\WINDOWS\WinSxS\x86_Microsoft.Windows.Common-Controls_6595b64144ccf1df_6.0.2600.5512_x-ww_35d4ce83\comctl32.dll
0x5d510000 - 0x5d5aa000 C:\WINDOWS\system32\comctl32.dll
0x769a0000 - 0x76a55000 C:\WINDOWS\system32\USERENV.dll
0x10000000 - 0x1001a000 C:\Arquivos de programas\HTTP Debugger
Pro\mfnsp32.dll
0x71a10000 - 0x71a50000 C:\WINDOWS\system32\mswsock.dll
0x60b30000 - 0x60b88000 C:\WINDOWS\system32\hnetcfg.dll
0x04050000 - 0x040c2000 c:\arquivos de programas\http debugger
pro\mfnhks32.dll
0x71a50000 - 0x71a58000 C:\WINDOWS\System32\wshtcpip.dll
0x68000000 - 0x68036000 C:\WINDOWS\system32\rsaenh.dll
0x5bcb0000 - 0x5bd05000 C:\WINDOWS\system32\netapi32.dll
0x76f00000 - 0x76f27000 C:\WINDOWS\system32\DNSAPI.dll
0x76f90000 - 0x76f98000 C:\WINDOWS\System32\winrnr.dll
0x76f40000 - 0x76f6d000 C:\WINDOWS\system32\WLDAP32.dll
0x04400000 - 0x04425000 C:\Arquivos de programas\Bonjour\mdnsNSP.dll
0x76d40000 - 0x76d59000 C:\WINDOWS\system32\Iphlpapi.dll
0x76fa0000 - 0x76fa6000 C:\WINDOWS\system32\rasadhlp.dll
0x042f0000 - 0x043e1000
C:\jruby-1.5.0\lib\ruby\gems\1.8\gems\nokogiri-1.4.1-java\ext\nokogiri\libxml2.dll
0x71a90000 - 0x71a9a000 C:\WINDOWS\system32\WSOCK32.dll
0x04460000 - 0x04539000
C:\jruby-1.5.0\lib\ruby\gems\1.8\gems\nokogiri-1.4.1-java\ext\nokogiri\iconv.dll
0x04540000 - 0x04552000
C:\jruby-1.5.0\lib\ruby\gems\1.8\gems\nokogiri-1.4.1-java\ext\nokogiri\zlib1.dll
0x04560000 - 0x0458c000
C:\jruby-1.5.0\lib\ruby\gems\1.8\gems\nokogiri-1.4.1-java\ext\nokogiri\libxslt.dll
0x04590000 - 0x045a0000
C:\jruby-1.5.0\lib\ruby\gems\1.8\gems\nokogiri-1.4.1-java\ext\nokogiri\libexslt.dll

VM Arguments:
jvm_args: -Djdk.home=C:\Arquivos de programas\Java\jdk1.6.0_18
-Djruby.home=C:\jruby-1.5.0 -Djruby.script=jruby -Djruby.shell=cmd.exe
-Djffi.boot.library.path=C:\jruby-1.5.0\lib\native\i386-Windows;C:\jruby-1.5.0\lib\native\x86_64-Windows
-Xmx500m -Xss1024k -Djruby.memory.max=500m -Djruby.stack.max=1024k
-Xbootclasspath/a:C:\jruby-1.5.0\lib\jruby.jar
java_command: org.jruby.Main
Launcher Type: generic

Environment Variables:
JAVA_HOME=C:\Arquivos de programas\Java\jdk1.6.0_18
CLASSPATH=.;C:\Arquivos de programas\Java\jre6\lib\ext\QTJava.zip
PATH=C:\Arquivos de programas\MiKTeX
2.8\miktex\bin;C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;C:\Arquivos
de programas\ATI Technologies\ATI Control Panel;C:\Arquivos de
programas\TortoiseSVN\bin;C:\Arquivos de programas\ATI
Technologies\ATI.ACE\Core-Static;C:\Arquivos de programas\Microsoft SQL
Server\90\Tools\binn;C:\Arquivos de
programas\QuickTime\QTSystem;C:\WINDOWS\system32\Wbem;C:\ARQUIV~1\Dell\OPENMA~1\PRINTE~1;C:\ARQUIV~1\Dell\OPENMA~1\PRINTE~1\oware\bin;C:\jruby-1.5.0\bin;c:\Ruby\bin;
USERNAME=Administrador
OS=Windows_NT
PROCESSOR_IDENTIFIER=x86 Family 15 Model 36 Stepping 2, AuthenticAMD

--------------- S Y S T E M ---------------

OS: Windows XP Build 2600 Service Pack 3

CPU:total 1 (1 cores per cpu, 1 threads per core) family 15 model 36
stepping 2, cmov, cx8, fxsr, mmx, sse, sse2, sse3, mmxext, 3dnow,
3dnowext

Memory: 4k page, physical 1046704k(241936k free), swap 2517996k(1336384k
free)

vm_info: Java HotSpot™ Client VM (16.0-b13) for windows-x86 JRE
(1.6.0_18-b07), built on Dec 17 2009 13:35:55 by “java_re” with MS VC++
7.1 (VS2003)

time: Tue Jan 19 21:47:35 2010
elapsed time: 42 seconds

I really hope that we can fix this soon!

Regards and thanks again

Hey Guys,

I’m sorry but since i had no reply from my last post in the last days, i
had to move on with my project which is already delayed.I’m sorry, but i
can’t debug this Jruby stuff anymore. Sorry guys that i can’t help you
with that, but now i decided to use Ruby!
If you guys have any news, just let me know!
Best Regards and thanks for trying to help me with this problem!

Regards,

Felipe