Skip to content
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

bson: rb_sym_to_s not implemented #1575

Closed
deepj opened this issue Feb 6, 2019 · 4 comments
Closed

bson: rb_sym_to_s not implemented #1575

deepj opened this issue Feb 6, 2019 · 4 comments

Comments

@deepj
Copy link

deepj commented Feb 6, 2019

To reproduce:

require 'bson'

BSON::CodeWithScope.new('this.value = name', { :name => 'test' }).to_bson

Error:

RuntimeError: rb_sym_to_s not implemented
	from ruby.c:2752:in `rb_tr_error'
	from ruby.c:4236:in `rb_sym_to_s'
	from ~/.gem/truffleruby/2.4.4/gems/bson-4.4.2/ext/bson/bson_native.c:326:in `put_hash_callback'
	from ~/.rubies/truffleruby-1.0.0-rc12/lib/truffle/truffle/cext.rb:1036:in `execute_without_conversion'
	from ~/.rubies/truffleruby-1.0.0-rc12/lib/truffle/truffle/cext.rb:1036:in `block in rb_hash_foreach'
	from ~/.rubies/truffleruby-1.0.0-rc12/lib/truffle/truffle/cext.rb:1035:in `each'
	from ~/.rubies/truffleruby-1.0.0-rc12/lib/truffle/truffle/cext.rb:1035:in `rb_hash_foreach'
	from ruby.c:1574:in `rb_hash_foreach'
	from ~/.gem/truffleruby/2.4.4/gems/bson-4.4.2/ext/bson/bson_native.c:357:in `rb_bson_byte_buffer_put_hash'
	from ~/.rubies/truffleruby-1.0.0-rc12/lib/truffle/truffle/cext.rb:296:in `execute_without_conversion'
	from ~/.rubies/truffleruby-1.0.0-rc12/lib/truffle/truffle/cext.rb:296:in `execute_with_mutex'
	from ~/.rubies/truffleruby-1.0.0-rc12/lib/truffle/truffle/cext_ruby.rb:41:in `put_hash'
	from ~/.gem/truffleruby/2.4.4/gems/bson-4.4.2/lib/bson/hash.rb:42:in `to_bson'
	from ~/.gem/truffleruby/2.4.4/gems/bson-4.4.2/lib/bson/code_with_scope.rb:94:in `to_bson'
	from (irb):11
	from ~/.rubies/truffleruby-1.0.0-rc12/bin/irb:29:in `<main>'
@chrisseaton
Copy link
Collaborator

This'll be a one-line fix.

@aardvark179 aardvark179 self-assigned this Feb 7, 2019
@aardvark179
Copy link
Contributor

I've now got a fixes for all the unexpectedly failing BSON tests in CI. The redefinition of NilClass#== by BSON did throw for a little bit.

@aardvark179 aardvark179 added this to the 1.0.0-rc13 milestone Feb 15, 2019
@aardvark179
Copy link
Contributor

The fix for this is now merged.

@deepj
Copy link
Author

deepj commented Feb 15, 2019

@aardvark179 Just a question. Do you say all BSON specs are just passed?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants