These are chat archives for opal/opal

7th
Jul 2016
Mitch VanDuyn
@catmando
Jul 07 2016 15:10
@elia - opal-rspec-rails and 0.10.x?
Elia Schito
@elia
Jul 07 2016 16:38
@catmando yeah, that's next, probably it will be based on the upcoming opal-rspec 0.6.0
Mitch VanDuyn
@catmando
Jul 07 2016 16:41
sooo any suggestions for testing against 0.10.x in themean time?
Elia Schito
@elia
Jul 07 2016 16:42
@catmando the first 0.6 beta should be out very soon (cc @wied03) in the meanwhile it should work using opal-rspec@master
Mitch VanDuyn
@catmando
Jul 07 2016 16:43
thanks I'll give it a whirl
Mitch VanDuyn
@catmando
Jul 07 2016 16:49
@elia - is eval throwing a different error in 0.10?
Mitch VanDuyn
@catmando
Jul 07 2016 17:10
seems like its changed behavior...
Elia Schito
@elia
Jul 07 2016 21:49
@catmando no idea but possible, can you be more specific?
Mitch VanDuyn
@catmando
Jul 07 2016 21:50
yeah, I confirmed... previous it looks like it raised StandardError if something goes wrong, now its raising Exception... no biggie.
Elia Schito
@elia
Jul 07 2016 21:51
@catmando let me know if you have any consideration on that, is that a kind of runtime error?
Mitch VanDuyn
@catmando
Jul 07 2016 21:53
for example:
begin
  `eval('Fred')` # Fred aint defined
rescue
  puts 'hi'
end
works < 0.10, fails in 0.10
rescue has to change to rescue Exception
Elia Schito
@elia
Jul 07 2016 21:54
you mean rescue Exception?
so it's JS eval right?
Mitch VanDuyn
@catmando
Jul 07 2016 21:55
yes rescue Exception, and yes js eval
Elia Schito
@elia
Jul 07 2016 21:56
I see, yeah, something has changed wrt rescuing native JS exceptions due to some edge case
Mitch VanDuyn
@catmando
Jul 07 2016 21:57
sure... wouldn't have noticed, except I was being a good boy, and cleaning up these RuboCop errors, (i.e. don't rescue Exception :-)
Elia Schito
@elia
Jul 07 2016 22:01
heheheh, yeah
actually we should come up with a way to rescue any JS error, like an arbitrary object and that stuff without resorting to x-stringsā€¦
Brady Wied
@wied03
Jul 07 2016 22:03
@elia @catmando - opal/opal#1280
Elia Schito
@elia
Jul 07 2016 22:06
ha! yeah, I guess it wasn't just a memory from hyperuranion :D
Elia Schito
@elia
Jul 07 2016 22:19
:tada: