meh` changed the topic of #opal to: http://opalrb.org - Ruby runtime and library on top of Javascript | 1.0.0 is near | This channel is logged at https://botbot.me/freenode/opal/
elia has quit [Quit: Computer has gone to sleep.]
elia has joined #opal
meh` has quit [Ping timeout: 272 seconds]
elia has quit [Quit: Computer has gone to sleep.]
fkchang has joined #opal
<fkchang> adambeynon: trying to update opal-irb to head, got a clue on
<fkchang> TypeError: Cannot read property 'substring' of undefined
<fkchang> at $StringScanner.def.$scan (file:///Users/fkchang/src/opal-irb/compiled/application.js:15457:37)
<fkchang> at $Lexer.def.$scan (file:///Users/fkchang/src/opal-irb/compiled/application.js:15872:42)
<fkchang> at $Lexer.def.$yylex (file:///Users/fkchang/src/opal-irb/compiled/application.js:16750:32)
<fkchang> at $Lexer.def.$next_token (file:///Users/fkchang/src/opal-irb/compiled/application.js:15915:22)
<fkchang> at $Parser.def.$next_token (file:///Users/fkchang/src/opal-irb/compiled/application.js:19572:27)
<fkchang> at $Parser.def.$_racc_do_parse_rb (file:///Users/fkchang/src/opal-irb/compiled/application.js:16835:28)
<fkchang> at $Parser.def.$do_parse (file:///Users/fkchang/src/opal-irb/compiled/application.js:16796:21)
<fkchang> at $Parser.def.$parse_to_sexp (file:///Users/fkchang/src/opal-irb/compiled/application.js:19564:23)
<fkchang> at $Parser.def.$parse (file:///Users/fkchang/src/opal-irb/compiled/application.js:19547:23)
<fkchang> at $Compiler.def.$compile (file:///Users/fkchang/src/opal-irb/compiled/application.js:25425:56)
j_mcnally has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
fkchang has quit [Ping timeout: 256 seconds]
j_mcnally has joined #opal
adambeynon has quit [Read error: Connection reset by peer]
pmarreck has quit [Ping timeout: 244 seconds]
adambeynon_ has joined #opal
bcavileer_ has quit [Write error: Connection reset by peer]
pmarreck has joined #opal
bcavileer_ has joined #opal
j_mcnally has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
elia has joined #opal
meh` has joined #opal
GitHub112 has joined #opal
<GitHub112> [opal-jquery] adambeynon closed pull request #59: Fix issues with Element#animate specs and add an #effect spec (master...master) http://git.io/ctdrag
GitHub112 has left #opal [#opal]
GitHub173 has joined #opal
<GitHub173> [opal-jquery] adambeynon pushed 2 new commits to master: http://git.io/ZQ7W3g
<GitHub173> opal-jquery/master 5a30a94 Jared White: Fix issues with Element#animate specs and add an #effect (fade_in and fade_out) spec
<GitHub173> opal-jquery/master d7ababd Adam Beynon: Merge pull request #59 from jaredcwhite/master...
GitHub173 has left #opal [#opal]
moon4u has joined #opal
elia has quit [Quit: (IRC Client: textualapp.com)]
elia has joined #opal
elia has quit [Client Quit]
f-3r has joined #opal
_elia has joined #opal
f-3r has quit [Ping timeout: 264 seconds]
moon4u has quit [Quit: Leaving]
j_mcnally has joined #opal
_elia has quit [Quit: Computer has gone to sleep.]
fkchang has joined #opal
<fkchang> adambeynon_: meh` does this error mean anything, I get this when I try to run specs
<fkchang> TypeError: 'undefined' is not an object (evaluating 'def.hash = nil')
fkchang has quit [Ping timeout: 265 seconds]
j_mcnally has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
fkchang has joined #opal
<meh`> fkchang, yeah, for some reason def is undefined
<meh`> but it sounds weird
<fkchang> looks like my sprockets_runner.js is being compiled against 0.6 instead of the 0.7 beta
<fkchang> do I need to upgrade opal-rspec?
<fkchang> actually that's it, I pegged it to 0.3.0 beta probably during some opal chaos
<fkchang> improvement, though these aren't reassuring
<fkchang> WARNING: Cannot handle dynamic require -- rspec/core/configuration:
<fkchang> WARNING: Cannot handle dynamic require -- rspec/core/configuration:533
<fkchang> WARNING: Cannot handle dynamic require -- rspec/core/configuration:857
<fkchang> WARNING: Cannot handle dynamic require -- rspec/core/configuration:1095
<fkchang> WARNING: Cannot handle dynamic require -- rspec/core/configuration:1095
<fkchang> WARNING: Cannot handle dynamic require -- rspec/core:
<fkchang> WARNING: Cannot handle dynamic require -- rspec/core:200
<fkchang> WARNING: Cannot handle dynamic require -- rspec/core:200
<fkchang> and it takes forever tgo run 9 specs
<fkchang> meh`: interestingly, I'm getting back a Promise where I expecgt an array
<meh`> fkchang, wat, where?
fkchang has quit [Ping timeout: 255 seconds]
j_mcnally has joined #opal
fkchang has joined #opal
<fkchang> oddly, rspec is telling that's the spec that's failing, but I don't see how the spec matches the error
<fkchang> Failures:
<fkchang>
<fkchang>
<fkchang>
<fkchang> 1) OpalIrb should return classes
<fkchang>
<fkchang> ArgumentError:
<fkchang> comparison of [#<Promise(970)>, HTTP] with ["Numeric", Numeric] failed
<fkchang> hmm, the spec fail is actually in this line
<fkchang> opal_classes = subject.opal_classes
j_mcnally has quit [Ping timeout: 250 seconds]
fkchang has quit [Ping timeout: 258 seconds]
elia has joined #opal
fkchang has joined #opal
elia has quit [Quit: Computer has gone to sleep.]
f-3r has joined #opal
<fkchang> meh`: adambeynon_ has Symbol#to_proc changed with 0.7? If I use this line, I get the Promise comparison classes.uniq.sort_by(&:name) but classes.uniq.sort_by { |cls| cls.name } works fine
elia has joined #opal
<adambeynon_> fkchang: It shouldn’t have changed… let me check
<fkchang> or perhaps it's to_proc returns a promise now
<adambeynon_> fkchang: nope, to_proc doesn’t handle promises at all
<adambeynon_> fkchang: hmmm, looks like there was a change since last release
<adambeynon_> cant see how it would have broken anything though...
<fkchang> it seems it's coz Im looping over Native objects
<fkchang> http://fkchang.github.io/opal-irb/index-embeddable.html#code:%24classes%20%3D%20%5B%5D%0A%24opal_js_object%20%3D%20Native(%60Opal%60)%20%20%20%20%23%20have%20to%20make%20this%20global%20right%20now%20coz%20not%20seen%20in%20the%20each%20closure%20w%2Fcurrent%20opal%0A%24opal_js_object.each%20%7B%7Ck%7C%0A%20%20attr%20%3D%20%24opal_js_object%5Bk%5D%0A%20%20%24classes%20%3C%3C%20attr%20if%20attr.is_a%3F(Class)%0A%20%20%7D%0A%24classes.uniq.sort_
<fkchang> adambeynon_: dunno if irc will trim the url, but if you click that, it'll show u the code in opal-rb
<fkchang> adambeynon_: full link in https://gist.github.com/fkchang/ee82009931ea3632d24a
<adambeynon_> fkchang: yeap, seeing the error here, trying to work out whats happening
<adambeynon_> must be an error inside to_proc
<fkchang> hmm, trying it in try opal, it works
<fkchang> http://opalrb.org/try/#code:%24classes%20%3D%20%5B%5D%0A%24opal_js_object%20%3D%20Native(%60Opal%60)%20%20%20%20%23%20have%20to%20make%20this%20global%20right%20now%20coz%20not%20seen%20in%20the%20each%20closure%20w%2Fcurrent%20opal%0A%24opal_js_object.each%20%7B%7Ck%7C%0A%20%20attr%20%3D%20%24opal_js_object%5Bk%5D%0A%20%20%24classes%20%3C%3C%20attr%20if%20attr.is_a%3F(Class)%0A%20%20%7D%0Ap%20%24classes.uniq.sort_by%20%26%3Aname
<adambeynon_> fkchang: strange
<adambeynon_> is there any class that shows up in opal-irb and not opalrb.org?
<adambeynon_> just thinking whether one of those classes respond to #name, and that is breaking something or other
<adambeynon_> possibly trying to forward something through Native#method_missing
<fkchang> adambeynon_: there would be opal irb classes, I can diff the lists
<adambeynon_> fkchang: also, I think you’re using opal-browser iirc.. maybe something in that or Paggio is using #name()
<fkchang> could be, this is what's in opal-irb that's not in try ruby
<fkchang> [OpalIrbLogRedirector, Foo, OpalIrb, Paggio, StringIO, Browser, OpenStruct, Timeout, OpalIrbJqconsole]
<fkchang> yet [OpalIrbLogRedirector, Foo, OpalIrb, Paggio, StringIO, Browser, OpenStruct, Timeout, OpalIrbJqconsole].map(&:name)
<fkchang> works fine
<adambeynon_> fkchang:
<adambeynon_> opal> [HTTP].map(&:name)
<adambeynon_> => [#<Promise(3491)>]
<fkchang> oh
<adambeynon_> seems to be HTTP from opal-jquery causing the issue
<adambeynon_> which is really confusing
<adambeynon_> fkchang: as it works fine in opalrb.org
<fkchang> yeah, also why is HTTP.name == "HTTP"
<fkchang> but the promise when mapped
<adambeynon_> fkchang: okay, found the issue
<adambeynon_> HTTP has overriden the send method
<adambeynon_> HTTP.send() => Promise
<fkchang> aha
<meh`> lol
<adambeynon_> and to_proc uses obj#send()
<meh`> adambeynon_, replace with __send__
<adambeynon_> meh`: seems the plan. is it generally acceptable to override #send() ?
<meh`> yes
<meh`> internally always use __send__
<meh`> it's like __id__
<meh`> if you don't know what's going on, never use #object_id
<fkchang> really, I hit a prob when I was trying to map the Vertx eventbus code into Opal, where they have EventBus.send -- don't remember exactly the issue, but I made the map to send_msg instead, maybe I'll undo that
<adambeynon_> meh`: righty-o
<adambeynon_> fkchang: If i fix on master, can you run things from git instead?
<adambeynon_> fkchang: pushed to master ^^ should do the trick
GitHub60 has joined #opal
<GitHub60> [opal] adambeynon pushed 1 new commit to master: http://git.io/muO53w
<GitHub60> opal/master 665fee6 Adam Beynon: String#to_proc now uses #__send__ instead of #send
GitHub60 has left #opal [#opal]
<adambeynon_> Off to watch some Boardwalk Empire.. back in an hour ;)
<fkchang> adambeynon_: thx
f-3r has quit [Ping timeout: 264 seconds]
fkchang has quit [Read error: Connection reset by peer]