rasem icon indicating copy to clipboard operation
rasem copied to clipboard

no implicit conversion of Symbol into Integer when instantiating SVGImage

Open KidA001 opened this issue 8 years ago • 1 comments

i = Rasem::SVGImage.new(100, 100) do
  line(0, 0, 100, 100)
end
TypeError: no implicit conversion of Symbol into Integer
	from /.rvm/gems/ruby-2.3.3/gems/rasem-0.7.1/lib/rasem/svg_image.rb:426:in `[]'
	from /.rvm/gems/ruby-2.3.3/gems/rasem-0.7.1/lib/rasem/svg_image.rb:426:in `initialize'
	from (irb):17:in `new'
	from (irb):17
	from /.rvm/rubies/ruby-2.3.3/bin/irb:11:in `<main>'

Ruby 2.3.3 rasem-0.7.1

KidA001 avatar Jan 30 '17 17:01 KidA001

I just ran into this too, after upgrading from 0.6.1 to 0.7.1.

It seems this commit made some big changes to the API: https://github.com/aseldawy/rasem/commit/788f6874ff7dc44f65c63e36c8863f676ca196c9

@aseldawy have you considered using Semantic Versioning? That would help to communicate when there is an API-breaking change like this.

You could also use a CHANGELOG to document any breaking changes.

andyw8 avatar Feb 12 '17 02:02 andyw8