Skip to content

Instantly share code, notes, and snippets.

@soulcutter
Created September 8, 2012 04:48
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save soulcutter/3671893 to your computer and use it in GitHub Desktop.
Save soulcutter/3671893 to your computer and use it in GitHub Desktop.
JRuby NPE using Symbol#to_proc with --1.9
➜ saxerator git:(master) ✗ ruby -v
jruby 1.7.0.preview2 (1.9.3p203) 2012-09-07 f4306fa on Java HotSpot(TM) 64-Bit Server VM 1.6.0_33-b03-424-11M3720 [darwin-x86_64]
➜ saxerator git:(master) rspec spec/lib/dsl/for_tag_spec.rb
/Users/soulcutter/.rvm/gems/jruby-head@saxerator/gems/rspec-core-2.11.1/lib/rspec/core/example.rb:274 warning: singleton on non-persistent Java type Java::JavaLang::NullPointerException (http://wiki.jruby.org/Persistence)
F
Failures:
1) Saxerator::DSL#for_tag should only select the specified tag
Failure/Error: Unable to find matching line from backtrace
Java::JavaLang::NullPointerException:
# org.jruby.javasupport.util.RuntimeHelpers.invokedynamic(RuntimeHelpers.java:2672)
# org.jruby.RubyArray.compare(RubyArray.java:1967)
# org.jruby.util.RecursiveComparator.compare(RecursiveComparator.java:49)
# org.jruby.RubyArray.op_equal(RubyArray.java:1945)
# org.jruby.RubyArray$INVOKER$i$1$0$op_equal.call(RubyArray$INVOKER$i$1$0$op_equal.gen)
# org.jruby.internal.runtime.methods.JavaMethod$JavaMethodOneOrN.call(JavaMethod.java:746)
# org.jruby.RubyClass.finvoke(RubyClass.java:630)
# org.jruby.RubyBasicObject.send19(RubyBasicObject.java:1673)
# org.jruby.RubyBasicObject$INVOKER$i$send19.call(RubyBasicObject$INVOKER$i$send19.gen)
# org.jruby.internal.runtime.methods.JavaMethod$JavaMethodZeroOrOneOrTwoOrNBlock.call(JavaMethod.java:291)
# org.jruby.runtime.callsite.CachingCallSite.cacheAndCall(CachingCallSite.java:332)
# org.jruby.runtime.callsite.CachingCallSite.call(CachingCallSite.java:203)
# org.jruby.ast.CallTwoArgNode.interpret(CallTwoArgNode.java:59)
# org.jruby.ast.IfNode.interpret(IfNode.java:110)
# org.jruby.ast.NewlineNode.interpret(NewlineNode.java:104)
# org.jruby.evaluator.ASTInterpreter.INTERPRET_METHOD(ASTInterpreter.java:75)
# org.jruby.internal.runtime.methods.InterpretedMethod.call(InterpretedMethod.java:268)
# org.jruby.internal.runtime.methods.DefaultMethod.call(DefaultMethod.java:224)
# org.jruby.runtime.callsite.CachingCallSite.cacheAndCall(CachingCallSite.java:352)
# org.jruby.runtime.callsite.CachingCallSite.call(CachingCallSite.java:237)
# org.jruby.ast.FCallThreeArgNode.interpret(FCallThreeArgNode.java:40)
# org.jruby.ast.NewlineNode.interpret(NewlineNode.java:104)
# org.jruby.ast.BlockNode.interpret(BlockNode.java:71)
# org.jruby.evaluator.ASTInterpreter.INTERPRET_METHOD(ASTInterpreter.java:75)
# org.jruby.internal.runtime.methods.InterpretedMethod.call(InterpretedMethod.java:268)
# org.jruby.internal.runtime.methods.DefaultMethod.call(DefaultMethod.java:224)
# org.jruby.runtime.callsite.CachingCallSite.cacheAndCall(CachingCallSite.java:352)
# org.jruby.runtime.callsite.CachingCallSite.call(CachingCallSite.java:237)
# org.jruby.ast.FCallThreeArgNode.interpret(FCallThreeArgNode.java:40)
# org.jruby.ast.NewlineNode.interpret(NewlineNode.java:104)
# org.jruby.ast.IfNode.interpret(IfNode.java:118)
# org.jruby.ast.NewlineNode.interpret(NewlineNode.java:104)
# org.jruby.evaluator.ASTInterpreter.INTERPRET_BLOCK(ASTInterpreter.java:112)
# org.jruby.runtime.Interpreted19Block.evalBlockBody(Interpreted19Block.java:209)
# org.jruby.runtime.Interpreted19Block.yield(Interpreted19Block.java:197)
# org.jruby.runtime.Interpreted19Block.call(Interpreted19Block.java:128)
# org.jruby.runtime.Block.call(Block.java:89)
# org.jruby.RubyProc.call(RubyProc.java:261)
# org.jruby.internal.runtime.methods.ProcMethod.call(ProcMethod.java:64)
# org.jruby.internal.runtime.methods.DynamicMethod.call(DynamicMethod.java:208)
# org.jruby.internal.runtime.methods.DynamicMethod.call(DynamicMethod.java:204)
# org.jruby.runtime.callsite.CachingCallSite.cacheAndCall(CachingCallSite.java:312)
# org.jruby.runtime.callsite.CachingCallSite.call(CachingCallSite.java:169)
# org.jruby.runtime.callsite.EqCallSite.call(EqCallSite.java:37)
# org.jruby.ast.CallOneArgNode.interpret(CallOneArgNode.java:57)
# org.jruby.ast.NewlineNode.interpret(NewlineNode.java:104)
# org.jruby.evaluator.ASTInterpreter.INTERPRET_BLOCK(ASTInterpreter.java:112)
# org.jruby.runtime.Interpreted19Block.evalBlockBody(Interpreted19Block.java:209)
# org.jruby.runtime.Interpreted19Block.yield(Interpreted19Block.java:197)
# org.jruby.runtime.Interpreted19Block.yield(Interpreted19Block.java:180)
# org.jruby.runtime.Block.yieldNonArray(Block.java:141)
# org.jruby.RubyBasicObject.yieldUnder(RubyBasicObject.java:1789)
# org.jruby.RubyBasicObject.specificEval(RubyBasicObject.java:1813)
# org.jruby.RubyBasicObject.instance_eval19(RubyBasicObject.java:1699)
# org.jruby.RubyBasicObject$INVOKER$i$instance_eval19.call(RubyBasicObject$INVOKER$i$instance_eval19.gen)
# org.jruby.runtime.callsite.CachingCallSite.cacheAndCall(CachingCallSite.java:302)
# org.jruby.runtime.callsite.CachingCallSite.callBlock(CachingCallSite.java:144)
# org.jruby.runtime.callsite.CachingCallSite.call(CachingCallSite.java:148)
# org.jruby.ast.CallNoArgBlockPassNode.interpret(CallNoArgBlockPassNode.java:53)
# org.jruby.ast.NewlineNode.interpret(NewlineNode.java:104)
# org.jruby.ast.BlockNode.interpret(BlockNode.java:71)
# org.jruby.ast.RescueNode.executeBody(RescueNode.java:226)
# org.jruby.ast.RescueNode.interpretWithJavaExceptions(RescueNode.java:123)
# org.jruby.ast.RescueNode.interpret(RescueNode.java:113)
# org.jruby.ast.EnsureNode.interpret(EnsureNode.java:96)
# org.jruby.ast.BeginNode.interpret(BeginNode.java:83)
# org.jruby.ast.NewlineNode.interpret(NewlineNode.java:104)
# org.jruby.evaluator.ASTInterpreter.INTERPRET_BLOCK(ASTInterpreter.java:112)
# org.jruby.runtime.Interpreted19Block.evalBlockBody(Interpreted19Block.java:209)
# org.jruby.runtime.Interpreted19Block.yield(Interpreted19Block.java:160)
# org.jruby.runtime.Interpreted19Block.yieldSpecific(Interpreted19Block.java:133)
# org.jruby.runtime.Block.yieldSpecific(Block.java:99)
# org.jruby.ast.ZYieldNode.interpret(ZYieldNode.java:25)
# org.jruby.ast.NewlineNode.interpret(NewlineNode.java:104)
# org.jruby.ast.IfNode.interpret(IfNode.java:116)
# org.jruby.ast.NewlineNode.interpret(NewlineNode.java:104)
# org.jruby.ast.RescueNode.executeBody(RescueNode.java:226)
# org.jruby.ast.RescueNode.interpretWithJavaExceptions(RescueNode.java:123)
# org.jruby.ast.RescueNode.interpret(RescueNode.java:113)
# org.jruby.evaluator.ASTInterpreter.INTERPRET_METHOD(ASTInterpreter.java:75)
# org.jruby.internal.runtime.methods.InterpretedMethod.call(InterpretedMethod.java:161)
# org.jruby.internal.runtime.methods.DefaultMethod.call(DefaultMethod.java:184)
# org.jruby.runtime.callsite.CachingCallSite.cacheAndCall(CachingCallSite.java:302)
# org.jruby.runtime.callsite.CachingCallSite.callBlock(CachingCallSite.java:144)
# org.jruby.runtime.callsite.CachingCallSite.callIter(CachingCallSite.java:153)
# org.jruby.ast.FCallNoArgBlockNode.interpret(FCallNoArgBlockNode.java:32)
# org.jruby.ast.NewlineNode.interpret(NewlineNode.java:104)
# org.jruby.ast.IfNode.interpret(IfNode.java:118)
# org.jruby.ast.NewlineNode.interpret(NewlineNode.java:104)
# org.jruby.ast.RescueNode.executeBody(RescueNode.java:226)
# org.jruby.ast.RescueNode.interpretWithJavaExceptions(RescueNode.java:123)
# org.jruby.ast.RescueNode.interpret(RescueNode.java:113)
# org.jruby.ast.EnsureNode.interpret(EnsureNode.java:96)
# org.jruby.ast.BeginNode.interpret(BeginNode.java:83)
# org.jruby.ast.NewlineNode.interpret(NewlineNode.java:104)
# org.jruby.ast.BlockNode.interpret(BlockNode.java:71)
# org.jruby.evaluator.ASTInterpreter.INTERPRET_METHOD(ASTInterpreter.java:75)
# org.jruby.internal.runtime.methods.InterpretedMethod.call(InterpretedMethod.java:225)
# org.jruby.internal.runtime.methods.DefaultMethod.call(DefaultMethod.java:208)
# org.jruby.runtime.callsite.CachingCallSite.cacheAndCall(CachingCallSite.java:332)
# org.jruby.runtime.callsite.CachingCallSite.call(CachingCallSite.java:203)
# org.jruby.ast.CallTwoArgNode.interpret(CallTwoArgNode.java:59)
# org.jruby.ast.DAsgnNode.interpret(DAsgnNode.java:110)
# org.jruby.ast.NewlineNode.interpret(NewlineNode.java:104)
# org.jruby.ast.BlockNode.interpret(BlockNode.java:71)
# org.jruby.evaluator.ASTInterpreter.INTERPRET_BLOCK(ASTInterpreter.java:112)
# org.jruby.runtime.Interpreted19Block.evalBlockBody(Interpreted19Block.java:209)
# org.jruby.runtime.Interpreted19Block.yield(Interpreted19Block.java:160)
# org.jruby.runtime.Block.yield(Block.java:130)
# org.jruby.RubyArray.collect(RubyArray.java:2342)
# org.jruby.RubyArray.map19(RubyArray.java:2355)
# org.jruby.RubyArray$INVOKER$i$0$0$map19.call(RubyArray$INVOKER$i$0$0$map19.gen)
# org.jruby.runtime.callsite.CachingCallSite.cacheAndCall(CachingCallSite.java:302)
# org.jruby.runtime.callsite.CachingCallSite.callBlock(CachingCallSite.java:144)
# org.jruby.runtime.callsite.CachingCallSite.callIter(CachingCallSite.java:153)
# org.jruby.ast.CallNoArgBlockNode.interpret(CallNoArgBlockNode.java:64)
# org.jruby.ast.CallNoArgNode.interpret(CallNoArgNode.java:63)
# org.jruby.ast.NewlineNode.interpret(NewlineNode.java:104)
# org.jruby.evaluator.ASTInterpreter.INTERPRET_METHOD(ASTInterpreter.java:75)
# org.jruby.internal.runtime.methods.InterpretedMethod.call(InterpretedMethod.java:182)
# org.jruby.internal.runtime.methods.DefaultMethod.call(DefaultMethod.java:192)
# org.jruby.runtime.callsite.CachingCallSite.cacheAndCall(CachingCallSite.java:312)
# org.jruby.runtime.callsite.CachingCallSite.call(CachingCallSite.java:169)
# org.jruby.ast.FCallOneArgNode.interpret(FCallOneArgNode.java:36)
# org.jruby.ast.LocalAsgnNode.interpret(LocalAsgnNode.java:123)
# org.jruby.ast.NewlineNode.interpret(NewlineNode.java:104)
# org.jruby.ast.BlockNode.interpret(BlockNode.java:71)
# org.jruby.ast.RescueNode.executeBody(RescueNode.java:226)
# org.jruby.ast.RescueNode.interpretWithJavaExceptions(RescueNode.java:123)
# org.jruby.ast.RescueNode.interpret(RescueNode.java:113)
# org.jruby.ast.EnsureNode.interpret(EnsureNode.java:96)
# org.jruby.ast.BeginNode.interpret(BeginNode.java:83)
# org.jruby.ast.NewlineNode.interpret(NewlineNode.java:104)
# org.jruby.ast.BlockNode.interpret(BlockNode.java:71)
# org.jruby.evaluator.ASTInterpreter.INTERPRET_METHOD(ASTInterpreter.java:75)
# org.jruby.internal.runtime.methods.InterpretedMethod.call(InterpretedMethod.java:182)
# org.jruby.internal.runtime.methods.DefaultMethod.call(DefaultMethod.java:192)
# org.jruby.runtime.callsite.CachingCallSite.cacheAndCall(CachingCallSite.java:312)
# org.jruby.runtime.callsite.CachingCallSite.call(CachingCallSite.java:169)
# org.jruby.ast.CallOneArgNode.interpret(CallOneArgNode.java:57)
# org.jruby.ast.NewlineNode.interpret(NewlineNode.java:104)
# org.jruby.evaluator.ASTInterpreter.INTERPRET_BLOCK(ASTInterpreter.java:112)
# org.jruby.runtime.Interpreted19Block.evalBlockBody(Interpreted19Block.java:209)
# org.jruby.runtime.Interpreted19Block.yield(Interpreted19Block.java:160)
# org.jruby.runtime.Block.yield(Block.java:130)
# org.jruby.RubyArray.collect(RubyArray.java:2342)
# org.jruby.RubyArray.map19(RubyArray.java:2355)
# org.jruby.RubyArray$INVOKER$i$0$0$map19.call(RubyArray$INVOKER$i$0$0$map19.gen)
# org.jruby.runtime.callsite.CachingCallSite.cacheAndCall(CachingCallSite.java:302)
# org.jruby.runtime.callsite.CachingCallSite.callBlock(CachingCallSite.java:144)
# org.jruby.runtime.callsite.CachingCallSite.callIter(CachingCallSite.java:153)
# org.jruby.ast.CallNoArgBlockNode.interpret(CallNoArgBlockNode.java:64)
# org.jruby.ast.CallNoArgNode.interpret(CallNoArgNode.java:63)
# org.jruby.ast.IfNode.interpret(IfNode.java:110)
# org.jruby.ast.NewlineNode.interpret(NewlineNode.java:104)
# org.jruby.ast.BlockNode.interpret(BlockNode.java:71)
# org.jruby.ast.EnsureNode.interpret(EnsureNode.java:96)
# org.jruby.ast.BeginNode.interpret(BeginNode.java:83)
# org.jruby.ast.NewlineNode.interpret(NewlineNode.java:104)
# org.jruby.evaluator.ASTInterpreter.INTERPRET_BLOCK(ASTInterpreter.java:112)
# org.jruby.runtime.Interpreted19Block.evalBlockBody(Interpreted19Block.java:209)
# org.jruby.runtime.Interpreted19Block.yield(Interpreted19Block.java:160)
# org.jruby.runtime.Interpreted19Block.yieldSpecific(Interpreted19Block.java:138)
# org.jruby.runtime.Block.yieldSpecific(Block.java:108)
# org.jruby.ast.YieldOneNode.interpret(YieldOneNode.java:35)
# org.jruby.ast.NewlineNode.interpret(NewlineNode.java:104)
# org.jruby.ast.EnsureNode.interpret(EnsureNode.java:96)
# org.jruby.ast.BeginNode.interpret(BeginNode.java:83)
# org.jruby.ast.NewlineNode.interpret(NewlineNode.java:104)
# org.jruby.ast.BlockNode.interpret(BlockNode.java:71)
# org.jruby.evaluator.ASTInterpreter.INTERPRET_METHOD(ASTInterpreter.java:75)
# org.jruby.internal.runtime.methods.InterpretedMethod.call(InterpretedMethod.java:247)
# org.jruby.internal.runtime.methods.DefaultMethod.call(DefaultMethod.java:216)
# org.jruby.runtime.callsite.CachingCallSite.cacheAndCall(CachingCallSite.java:342)
# org.jruby.runtime.callsite.CachingCallSite.callBlock(CachingCallSite.java:212)
# org.jruby.runtime.callsite.CachingCallSite.callIter(CachingCallSite.java:221)
# org.jruby.ast.CallTwoArgBlockNode.interpret(CallTwoArgBlockNode.java:62)
# org.jruby.ast.NewlineNode.interpret(NewlineNode.java:104)
# org.jruby.ast.BlockNode.interpret(BlockNode.java:71)
# org.jruby.evaluator.ASTInterpreter.INTERPRET_METHOD(ASTInterpreter.java:75)
# org.jruby.internal.runtime.methods.InterpretedMethod.call(InterpretedMethod.java:225)
# org.jruby.internal.runtime.methods.DefaultMethod.call(DefaultMethod.java:208)
# org.jruby.runtime.callsite.CachingCallSite.cacheAndCall(CachingCallSite.java:332)
# org.jruby.runtime.callsite.CachingCallSite.call(CachingCallSite.java:203)
# org.jruby.ast.CallTwoArgNode.interpret(CallTwoArgNode.java:59)
# org.jruby.ast.NewlineNode.interpret(NewlineNode.java:104)
# org.jruby.ast.IfNode.interpret(IfNode.java:118)
# org.jruby.ast.NewlineNode.interpret(NewlineNode.java:104)
# org.jruby.ast.BlockNode.interpret(BlockNode.java:71)
# org.jruby.ast.EnsureNode.interpret(EnsureNode.java:96)
# org.jruby.evaluator.ASTInterpreter.INTERPRET_METHOD(ASTInterpreter.java:75)
# org.jruby.internal.runtime.methods.InterpretedMethod.call(InterpretedMethod.java:268)
# org.jruby.internal.runtime.methods.DefaultMethod.call(DefaultMethod.java:224)
# org.jruby.runtime.callsite.CachingCallSite.cacheAndCall(CachingCallSite.java:352)
# org.jruby.runtime.callsite.CachingCallSite.call(CachingCallSite.java:237)
# org.jruby.ast.FCallThreeArgNode.interpret(FCallThreeArgNode.java:40)
# org.jruby.ast.CallNoArgNode.interpret(CallNoArgNode.java:63)
# org.jruby.ast.FCallOneArgNode.interpret(FCallOneArgNode.java:36)
# org.jruby.ast.IfNode.interpret(IfNode.java:118)
# org.jruby.ast.NewlineNode.interpret(NewlineNode.java:104)
# org.jruby.evaluator.ASTInterpreter.INTERPRET_BLOCK(ASTInterpreter.java:112)
# org.jruby.runtime.Interpreted19Block.evalBlockBody(Interpreted19Block.java:209)
# org.jruby.runtime.Interpreted19Block.yield(Interpreted19Block.java:197)
# org.jruby.runtime.Interpreted19Block.call(Interpreted19Block.java:128)
# org.jruby.runtime.Block.call(Block.java:89)
# org.jruby.RubyProc.call(RubyProc.java:261)
# org.jruby.RubyProc.call(RubyProc.java:213)
# org.jruby.Ruby.tearDown(Ruby.java:2859)
# org.jruby.Ruby.tearDown(Ruby.java:2843)
# org.jruby.Main.internalRun(Main.java:268)
# org.jruby.Main.run(Main.java:231)
# org.jruby.Main.run(Main.java:215)
# org.jruby.Main.main(Main.java:195)
Finished in 0.596 seconds
1 example, 1 failure
Failed examples:
rspec ./spec/lib/dsl/for_tag_spec.rb:17 # Saxerator::DSL#for_tag should only select the specified tag
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment