java.lang.IllegalArgumentException in debug mode when using CLOB
----------------------------------------------------------------

                 Key: JRUBY-2433
                 URL: http://jira.codehaus.org/browse/JRUBY-2433
             Project: JRuby
          Issue Type: Bug
    Affects Versions: JRuby 1.1
            Reporter: Jaroslav Libak
            Assignee: Thomas E Enebo
             Fix For: JRuby 1.1+


I already reported this bug to 
http://rubyforge.org/tracker/index.php?func=detail&aid=19680&group_id=3085&atid=11903
 , but that tracker seems to be unused and I'm not sure where exactly the bug 
might be.

The following code causes exception when running in debuger with 
ruby-debug-base-0.10.0-java in jruby 1.1 (also jruby 1.1.1). It worked
fine in previous 1.1 RCs. If I run it without fast java debugger, it works. The 
problem only occurs if table contains a CLOB column and we write some value 
into it.

=========================================
require 'rubygems'

gem 'activerecord'
gem 'activerecord-jdbc-adapter'

require 'active_record'
require 'active_record/transactions'
require 'jdbc_adapter'
require 'active_record/connection_adapters/jdbc_adapter'

spec = { :adapter=> "jdbc",
  :driver=> "oracle.jdbc.driver.OracleDriver",
  :url=> "someurl",
  :encoding => "utf8",
  :username => "******",
  :password => "******"
}

class TestTable < ActiveRecord::Base
  set_table_name "TEST_TABLE"
end

ActiveRecord::Base.establish_connection(spec)
test_table = TestTable.create({
                          
:clob1=>"&#269;&#357;&#345;ôúä&#318;&#328;íéáúó&#314;aaa"
                        })

===============================

sun/reflect/NativeMethodAccessorImpl.java:-2:in `invoke0': 
java.lang.IllegalArgumentException: wrong number of arguments
(NativeException)
        from sun/reflect/NativeMethodAccessorImpl.java:39:in `invoke'
        from sun/reflect/DelegatingMethodAccessorImpl.java:25:in `invoke'
        from java/lang/reflect/Method.java:585:in `invoke'
        from org/jruby/internal/runtime/methods/ReflectedJavaMethod.java:141:in 
`call'
        from org/jruby/internal/runtime/methods/DynamicMethod.java:66:in `call'
        from org/jruby/runtime/CallSite.java:102:in `cacheAndCall'
        from org/jruby/runtime/CallSite.java:243:in `call'
        from org/jruby/evaluator/ASTInterpreter.java:657:in `callNode'
         ... 220 levels...
        from 
C:/work/svn/ng/runtime/jruby/jruby-1.1/lib/ruby/gems/1.8/gems/ruby-debug-ide-0.1.10/bin/rdebug-ide:74
        from C:\work\svn\ng\runtime\jruby\jruby-1.1\bin\rdebug-ide:19:in `load'
        from C:\work\svn\ng\runtime\jruby\jruby-1.1\bin\rdebug-ide:19
Complete Java stackTrace

java.lang.IllegalArgumentException: wrong number of arguments

        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

        at 
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)

        at 
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)

        at java.lang.reflect.Method.invoke(Method.java:585)

        at 
org.jruby.internal.runtime.methods.ReflectedJavaMethod.call(ReflectedJavaMethod.java:141)

        at 
org.jruby.internal.runtime.methods.DynamicMethod.call(DynamicMethod.java:66)

        at 
org.jruby.runtime.CallSite$InlineCachingCallSite.cacheAndCall(CallSite.java:102)

        at 
org.jruby.runtime.CallSite$InlineCachingCallSite.call(CallSite.java:243)

        at org.jruby.evaluator.ASTInterpreter.callNode(ASTInterpreter.java:657)

        at 
org.jruby.evaluator.ASTInterpreter.evalInternal(ASTInterpreter.java:308)

        at org.jruby.evaluator.ASTInterpreter.eval(ASTInterpreter.java:168)

        at 
org.jruby.internal.runtime.methods.DefaultMethod.call(DefaultMethod.java:176)

        at 
org.jruby.internal.runtime.methods.DynamicMethod.call(DynamicMethod.java:66)

        at 
org.jruby.runtime.CallSite$InlineCachingCallSite.cacheAndCall(CallSite.java:102)

        at 
org.jruby.runtime.CallSite$InlineCachingCallSite.call(CallSite.java:243)

        at org.jruby.evaluator.ASTInterpreter.callNode(ASTInterpreter.java:657)

        at 
org.jruby.evaluator.ASTInterpreter.evalInternal(ASTInterpreter.java:308)

        at org.jruby.evaluator.ASTInterpreter.blockNode(ASTInterpreter.java:631)

        at 
org.jruby.evaluator.ASTInterpreter.evalInternal(ASTInterpreter.java:302)

        at org.jruby.evaluator.ASTInterpreter.eval(ASTInterpreter.java:168)

        at org.jruby.runtime.InterpretedBlock.yield(InterpretedBlock.java:150)

        at org.jruby.runtime.InterpretedBlock.yield(InterpretedBlock.java:115)

        at org.jruby.runtime.Block.yield(Block.java:109)

        at org.jruby.RubyArray.each(RubyArray.java:1179)

        at sun.reflect.GeneratedMethodAccessor20.invoke(Unknown Source)

        at 
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)

        at java.lang.reflect.Method.invoke(Method.java:585)

        at 
org.jruby.internal.runtime.methods.ReflectedJavaMethod.call(ReflectedJavaMethod.java:143)

        at 
org.jruby.runtime.CallSite$InlineCachingCallSite.cacheAndCall(CallSite.java:87)

        at 
org.jruby.runtime.CallSite$InlineCachingCallSite.call(CallSite.java:256)

        at org.jruby.evaluator.ASTInterpreter.callNode(ASTInterpreter.java:662)

        at 
org.jruby.evaluator.ASTInterpreter.evalInternal(ASTInterpreter.java:308)

        at org.jruby.evaluator.ASTInterpreter.blockNode(ASTInterpreter.java:631)

        at 
org.jruby.evaluator.ASTInterpreter.evalInternal(ASTInterpreter.java:302)

        at org.jruby.evaluator.ASTInterpreter.eval(ASTInterpreter.java:168)

        at 
org.jruby.internal.runtime.methods.DefaultMethod.call(DefaultMethod.java:176)

        at 
org.jruby.internal.runtime.methods.AliasMethod.call(AliasMethod.java:60)

        at org.jruby.RubyObject.send(RubyObject.java:1173)

        at sun.reflect.GeneratedMethodAccessor84.invoke(Unknown Source)

        at 
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)

        at java.lang.reflect.Method.invoke(Method.java:585)

        at 
org.jruby.internal.runtime.methods.ReflectedJavaMethod.call(ReflectedJavaMethod.java:143)

        at 
org.jruby.internal.runtime.methods.DynamicMethod.call(DynamicMethod.java:66)

        at 
org.jruby.runtime.CallSite$InlineCachingCallSite.call(CallSite.java:240)

        at 
org.jruby.evaluator.ASTInterpreter.fCallNode(ASTInterpreter.java:1100)

        at 
org.jruby.evaluator.ASTInterpreter.evalInternal(ASTInterpreter.java:354)

        at 
org.jruby.evaluator.ASTInterpreter.localAsgnNode(ASTInterpreter.java:1256)

        at 
org.jruby.evaluator.ASTInterpreter.evalInternal(ASTInterpreter.java:387)

        at org.jruby.evaluator.ASTInterpreter.blockNode(ASTInterpreter.java:631)

        at 
org.jruby.evaluator.ASTInterpreter.evalInternal(ASTInterpreter.java:302)

        at org.jruby.evaluator.ASTInterpreter.eval(ASTInterpreter.java:168)

        at 
org.jruby.internal.runtime.methods.DefaultMethod.call(DefaultMethod.java:176)

        at 
org.jruby.internal.runtime.methods.DynamicMethod.call(DynamicMethod.java:66)

        at 
org.jruby.runtime.CallSite$InlineCachingCallSite.cacheAndCall(CallSite.java:102)

        at 
org.jruby.runtime.CallSite$InlineCachingCallSite.call(CallSite.java:243)

        at 
org.jruby.evaluator.ASTInterpreter.fCallNode(ASTInterpreter.java:1100)

        at 
org.jruby.evaluator.ASTInterpreter.evalInternal(ASTInterpreter.java:354)

        at org.jruby.evaluator.ASTInterpreter.blockNode(ASTInterpreter.java:631)

        at 
org.jruby.evaluator.ASTInterpreter.evalInternal(ASTInterpreter.java:302)

        at org.jruby.evaluator.ASTInterpreter.eval(ASTInterpreter.java:168)

        at 
org.jruby.internal.runtime.methods.DefaultMethod.call(DefaultMethod.java:176)

        at 
org.jruby.internal.runtime.methods.AliasMethod.call(AliasMethod.java:60)

        at 
org.jruby.internal.runtime.methods.DynamicMethod.call(DynamicMethod.java:70)

        at 
org.jruby.runtime.CallSite$InlineCachingCallSite.cacheAndCall(CallSite.java:117)

        at 
org.jruby.runtime.CallSite$InlineCachingCallSite.call(CallSite.java:275)

        at 
org.jruby.evaluator.ASTInterpreter.vcallNode(ASTInterpreter.java:1748)

        at 
org.jruby.evaluator.ASTInterpreter.evalInternal(ASTInterpreter.java:484)

        at org.jruby.evaluator.ASTInterpreter.eval(ASTInterpreter.java:168)

        at 
org.jruby.internal.runtime.methods.DefaultMethod.call(DefaultMethod.java:176)

        at 
org.jruby.internal.runtime.methods.AliasMethod.call(AliasMethod.java:60)

        at 
org.jruby.internal.runtime.methods.DynamicMethod.call(DynamicMethod.java:70)

        at 
org.jruby.runtime.CallSite$InlineCachingCallSite.cacheAndCall(CallSite.java:117)

        at 
org.jruby.runtime.CallSite$InlineCachingCallSite.call(CallSite.java:275)

        at 
org.jruby.evaluator.ASTInterpreter.vcallNode(ASTInterpreter.java:1748)

        at 
org.jruby.evaluator.ASTInterpreter.evalInternal(ASTInterpreter.java:484)

        at org.jruby.evaluator.ASTInterpreter.eval(ASTInterpreter.java:168)

        at 
org.jruby.internal.runtime.methods.DefaultMethod.call(DefaultMethod.java:176)

        at 
org.jruby.internal.runtime.methods.AliasMethod.call(AliasMethod.java:60)

        at 
org.jruby.internal.runtime.methods.AliasMethod.call(AliasMethod.java:60)

        at 
org.jruby.internal.runtime.methods.DynamicMethod.call(DynamicMethod.java:66)

        at 
org.jruby.runtime.CallSite$InlineCachingCallSite.cacheAndCall(CallSite.java:102)

        at 
org.jruby.runtime.CallSite$InlineCachingCallSite.call(CallSite.java:243)

        at 
org.jruby.evaluator.ASTInterpreter.fCallNode(ASTInterpreter.java:1100)

        at 
org.jruby.evaluator.ASTInterpreter.evalInternal(ASTInterpreter.java:354)

        at org.jruby.evaluator.ASTInterpreter.eval(ASTInterpreter.java:168)

        at org.jruby.runtime.InterpretedBlock.yield(InterpretedBlock.java:150)

        at org.jruby.runtime.Block.yield(Block.java:114)

        at 
org.jruby.evaluator.ASTInterpreter.yieldNode(ASTInterpreter.java:1817)

        at 
org.jruby.evaluator.ASTInterpreter.evalInternal(ASTInterpreter.java:493)

        at org.jruby.evaluator.ASTInterpreter.blockNode(ASTInterpreter.java:631)

        at 
org.jruby.evaluator.ASTInterpreter.evalInternal(ASTInterpreter.java:302)

        at 
org.jruby.evaluator.ASTInterpreter.rescueNode(ASTInterpreter.java:1517)

        at 
org.jruby.evaluator.ASTInterpreter.evalInternal(ASTInterpreter.java:452)

        at org.jruby.evaluator.ASTInterpreter.blockNode(ASTInterpreter.java:631)

        at 
org.jruby.evaluator.ASTInterpreter.evalInternal(ASTInterpreter.java:302)

        at 
org.jruby.evaluator.ASTInterpreter.ensureNode(ASTInterpreter.java:1072)

        at 
org.jruby.evaluator.ASTInterpreter.evalInternal(ASTInterpreter.java:348)

        at org.jruby.evaluator.ASTInterpreter.eval(ASTInterpreter.java:168)

        at 
org.jruby.internal.runtime.methods.DefaultMethod.call(DefaultMethod.java:176)

        at 
org.jruby.runtime.CallSite$InlineCachingCallSite.cacheAndCall(CallSite.java:87)

        at 
org.jruby.runtime.CallSite$InlineCachingCallSite.call(CallSite.java:256)

        at org.jruby.evaluator.ASTInterpreter.callNode(ASTInterpreter.java:662)

        at 
org.jruby.evaluator.ASTInterpreter.evalInternal(ASTInterpreter.java:308)

        at 
org.jruby.evaluator.ASTInterpreter.ensureNode(ASTInterpreter.java:1072)

        at 
org.jruby.evaluator.ASTInterpreter.evalInternal(ASTInterpreter.java:348)

        at org.jruby.evaluator.ASTInterpreter.blockNode(ASTInterpreter.java:631)

        at 
org.jruby.evaluator.ASTInterpreter.evalInternal(ASTInterpreter.java:302)

        at org.jruby.evaluator.ASTInterpreter.eval(ASTInterpreter.java:168)

        at 
org.jruby.internal.runtime.methods.DefaultMethod.call(DefaultMethod.java:176)

        at 
org.jruby.runtime.CallSite$InlineCachingCallSite.cacheAndCall(CallSite.java:87)

        at 
org.jruby.runtime.CallSite$InlineCachingCallSite.call(CallSite.java:256)

        at org.jruby.evaluator.ASTInterpreter.callNode(ASTInterpreter.java:662)

        at 
org.jruby.evaluator.ASTInterpreter.evalInternal(ASTInterpreter.java:308)

        at org.jruby.evaluator.ASTInterpreter.eval(ASTInterpreter.java:168)

        at 
org.jruby.internal.runtime.methods.DefaultMethod.call(DefaultMethod.java:176)

        at 
org.jruby.runtime.CallSite$InlineCachingCallSite.cacheAndCall(CallSite.java:87)

        at 
org.jruby.runtime.CallSite$InlineCachingCallSite.call(CallSite.java:256)

        at 
org.jruby.evaluator.ASTInterpreter.fCallNode(ASTInterpreter.java:1105)

        at 
org.jruby.evaluator.ASTInterpreter.evalInternal(ASTInterpreter.java:354)

        at org.jruby.evaluator.ASTInterpreter.eval(ASTInterpreter.java:168)

        at org.jruby.runtime.InterpretedBlock.yield(InterpretedBlock.java:150)

        at org.jruby.runtime.Block.yield(Block.java:114)

        at 
org.jruby.evaluator.ASTInterpreter.yieldNode(ASTInterpreter.java:1817)

        at 
org.jruby.evaluator.ASTInterpreter.evalInternal(ASTInterpreter.java:493)

        at org.jruby.evaluator.ASTInterpreter.blockNode(ASTInterpreter.java:631)

        at 
org.jruby.evaluator.ASTInterpreter.evalInternal(ASTInterpreter.java:302)

        at 
org.jruby.evaluator.ASTInterpreter.rescueNode(ASTInterpreter.java:1517)

        at 
org.jruby.evaluator.ASTInterpreter.evalInternal(ASTInterpreter.java:452)

        at org.jruby.evaluator.ASTInterpreter.eval(ASTInterpreter.java:168)

        at 
org.jruby.internal.runtime.methods.DefaultMethod.call(DefaultMethod.java:176)

        at 
org.jruby.runtime.CallSite$InlineCachingCallSite.cacheAndCall(CallSite.java:87)

        at 
org.jruby.runtime.CallSite$InlineCachingCallSite.call(CallSite.java:256)

        at 
org.jruby.evaluator.ASTInterpreter.fCallNode(ASTInterpreter.java:1105)

        at 
org.jruby.evaluator.ASTInterpreter.evalInternal(ASTInterpreter.java:354)

        at org.jruby.evaluator.ASTInterpreter.eval(ASTInterpreter.java:168)

        at 
org.jruby.internal.runtime.methods.DefaultMethod.call(DefaultMethod.java:176)

        at 
org.jruby.internal.runtime.methods.AliasMethod.call(AliasMethod.java:60)

        at 
org.jruby.internal.runtime.methods.DynamicMethod.call(DynamicMethod.java:66)

        at 
org.jruby.runtime.CallSite$InlineCachingCallSite.cacheAndCall(CallSite.java:102)

        at 
org.jruby.runtime.CallSite$InlineCachingCallSite.call(CallSite.java:243)

        at org.jruby.evaluator.ASTInterpreter.callNode(ASTInterpreter.java:657)

        at 
org.jruby.evaluator.ASTInterpreter.evalInternal(ASTInterpreter.java:308)

        at org.jruby.evaluator.ASTInterpreter.blockNode(ASTInterpreter.java:631)

        at 
org.jruby.evaluator.ASTInterpreter.evalInternal(ASTInterpreter.java:302)

        at org.jruby.evaluator.ASTInterpreter.eval(ASTInterpreter.java:168)

        at 
org.jruby.internal.runtime.methods.DefaultMethod.call(DefaultMethod.java:176)

        at 
org.jruby.internal.runtime.methods.DynamicMethod.call(DynamicMethod.java:66)

        at 
org.jruby.runtime.CallSite$InlineCachingCallSite.cacheAndCall(CallSite.java:102)

        at 
org.jruby.runtime.CallSite$InlineCachingCallSite.call(CallSite.java:243)

        at org.jruby.evaluator.ASTInterpreter.callNode(ASTInterpreter.java:657)

        at 
org.jruby.evaluator.ASTInterpreter.evalInternal(ASTInterpreter.java:308)

        at 
org.jruby.evaluator.ASTInterpreter.localAsgnNode(ASTInterpreter.java:1256)

        at 
org.jruby.evaluator.ASTInterpreter.evalInternal(ASTInterpreter.java:387)

        at org.jruby.evaluator.ASTInterpreter.blockNode(ASTInterpreter.java:631)

        at 
org.jruby.evaluator.ASTInterpreter.evalInternal(ASTInterpreter.java:302)

        at org.jruby.evaluator.ASTInterpreter.rootNode(ASTInterpreter.java:1615)

        at 
org.jruby.evaluator.ASTInterpreter.evalInternal(ASTInterpreter.java:458)

        at org.jruby.evaluator.ASTInterpreter.eval(ASTInterpreter.java:168)

        at org.jruby.Ruby.loadFile(Ruby.java:1854)

        at org.jruby.runtime.load.ExternalScript.load(ExternalScript.java:58)

        at org.jruby.runtime.load.LoadService.load(LoadService.java:211)

        at org.jruby.debug.Debugger.load(Debugger.java:136)

        at org.jruby.debug.RubyDebugger.debug_load(RubyDebugger.java:190)

        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

        at 
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)

        at 
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)

        at java.lang.reflect.Method.invoke(Method.java:585)

        at 
org.jruby.internal.runtime.methods.ReflectedJavaMethod.call(ReflectedJavaMethod.java:141)

        at 
org.jruby.internal.runtime.methods.DynamicMethod.call(DynamicMethod.java:66)

        at 
org.jruby.runtime.CallSite$InlineCachingCallSite.cacheAndCall(CallSite.java:102)

        at 
org.jruby.runtime.CallSite$InlineCachingCallSite.call(CallSite.java:243)

        at 
org.jruby.evaluator.ASTInterpreter.fCallNode(ASTInterpreter.java:1100)

        at 
org.jruby.evaluator.ASTInterpreter.evalInternal(ASTInterpreter.java:354)

        at org.jruby.evaluator.ASTInterpreter.blockNode(ASTInterpreter.java:631)

        at 
org.jruby.evaluator.ASTInterpreter.evalInternal(ASTInterpreter.java:302)

        at org.jruby.evaluator.ASTInterpreter.eval(ASTInterpreter.java:168)

        at 
org.jruby.internal.runtime.methods.DefaultMethod.call(DefaultMethod.java:176)

        at 
org.jruby.internal.runtime.methods.DynamicMethod.call(DynamicMethod.java:66)

        at 
org.jruby.runtime.CallSite$InlineCachingCallSite.cacheAndCall(CallSite.java:102)

        at 
org.jruby.runtime.CallSite$InlineCachingCallSite.call(CallSite.java:243)

        at org.jruby.evaluator.ASTInterpreter.callNode(ASTInterpreter.java:657)

        at 
org.jruby.evaluator.ASTInterpreter.evalInternal(ASTInterpreter.java:308)

        at org.jruby.evaluator.ASTInterpreter.blockNode(ASTInterpreter.java:631)

        at 
org.jruby.evaluator.ASTInterpreter.evalInternal(ASTInterpreter.java:302)

        at org.jruby.evaluator.ASTInterpreter.rootNode(ASTInterpreter.java:1615)

        at 
org.jruby.evaluator.ASTInterpreter.evalInternal(ASTInterpreter.java:458)

        at org.jruby.evaluator.ASTInterpreter.eval(ASTInterpreter.java:168)

        at org.jruby.Ruby.loadFile(Ruby.java:1854)

        at org.jruby.runtime.load.ExternalScript.load(ExternalScript.java:58)

        at org.jruby.runtime.load.LoadService.load(LoadService.java:211)

        at org.jruby.RubyKernel.load(RubyKernel.java:684)

        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

        at 
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)

        at 
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)

        at java.lang.reflect.Method.invoke(Method.java:585)

        at 
org.jruby.internal.runtime.methods.ReflectedJavaMethod.call(ReflectedJavaMethod.java:141)

        at 
org.jruby.internal.runtime.methods.DynamicMethod.call(DynamicMethod.java:66)

        at 
org.jruby.runtime.CallSite$InlineCachingCallSite.cacheAndCall(CallSite.java:102)

        at 
org.jruby.runtime.CallSite$InlineCachingCallSite.call(CallSite.java:243)

        at 
org.jruby.evaluator.ASTInterpreter.fCallNode(ASTInterpreter.java:1100)

        at 
org.jruby.evaluator.ASTInterpreter.evalInternal(ASTInterpreter.java:354)

        at org.jruby.evaluator.ASTInterpreter.blockNode(ASTInterpreter.java:631)

        at 
org.jruby.evaluator.ASTInterpreter.evalInternal(ASTInterpreter.java:302)

        at org.jruby.evaluator.ASTInterpreter.rootNode(ASTInterpreter.java:1615)

        at 
org.jruby.evaluator.ASTInterpreter.evalInternal(ASTInterpreter.java:458)

        at org.jruby.evaluator.ASTInterpreter.eval(ASTInterpreter.java:168)

        at org.jruby.Ruby.runInterpreter(Ruby.java:528)

        at org.jruby.Ruby.runNormally(Ruby.java:434)

        at org.jruby.Ruby.runFromMain(Ruby.java:310)

        at org.jruby.Main.run(Main.java:141)

        at org.jruby.Main.run(Main.java:88)

        at org.jruby.Main.main(Main.java:79)

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: 
http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira



---------------------------------------------------------------------
To unsubscribe from this list, please visit:

    http://xircles.codehaus.org/manage_email


Reply via email to