adambeynon 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 http://irclog.whitequark.org/opal
e_dub has joined #opal
abowhill has joined #opal
gverri has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
DrShoggoth has quit [Quit: Leaving]
fkchang has joined #opal
<fkchang> adambeynon: ping
e_dub has quit [Quit: It's a hard knock life]
e_dub has joined #opal
<adambeynon> hi fkchang
dfranciosi has joined #opal
elia has joined #opal
<fkchang> adambeynon: having a hard time getting opal-rspec to run out of a different directory than spec (in a rails project, don't want it to run the rails specs), I tried making a custom erb file as main in the rake task which doesn't seem to take.
<adambeynon> fkchang: how are you running it? through the raketask? or config.ru?
<adambeynon> fkchang: have you seen the rails controller for opal-rspec? allows you to run the specs in the browser
<fkchang> tried to do both
<fkchang> rake and a custom *.ru file
<fkchang> rake task times out, rspec.ru complains about AssetPaths not being part of ActionView
<fkchang> haven't seen the rails controller. That'd be a start but I'd like to do it w/rake and phantomjs
meh` has joined #opal
<fkchang> adambeynon: gotta sleep, it's 2am, appreciate any tips
<adambeynon> fkchang: I'm out and about, but I will try it myself when I'm home. I will email or gist any solution. I haven't actually tried it myself, but il sure it should be able to work
<meh`> what are we talking about?
kludge` has quit [Ping timeout: 252 seconds]
<fkchang> opal-rspec in a directory other than spec (cuz my rails specs r there), via phantomjs
<fkchang> g'nit
<fkchang> e
kludge` has joined #opal
fkchang has quit [Ping timeout: 260 seconds]
elia has quit [Quit: Computer has gone to sleep.]
DouweM has joined #opal
elia has joined #opal
dfranciosi has quit [Remote host closed the connection]
dfranciosi has joined #opal
GitHub35 has joined #opal
GitHub35 has left #opal [#opal]
<GitHub35> opal/master b0573f9 Elia Schito: Let's try again with jruby/rubinius
<GitHub35> [opal] elia pushed 2 new commits to master: http://git.io/KbNSlg
<GitHub35> opal/master e152ec4 Elia Schito: Use a thread instead of fork and give some <3 to jruby
travis-ci has joined #opal
<travis-ci> [travis-ci] opal/opal#1592 (master - b0573f9 : Elia Schito): The build passed.
<travis-ci> [travis-ci] Build details : http://travis-ci.org/opal/opal/builds/15399577
travis-ci has left #opal [#opal]
<adambeynon> elia: the Travis web app seems to be really broken on iOS. I will be back on a laptop in 10 mins. Will have a look then
elia has quit [Ping timeout: 272 seconds]
elia has joined #opal
<adambeynon> elia: that parse error is really strange
<adambeynon> restarting it now
<adambeynon> maybe just a random error
<elia> adambeynon, I got it locally too, but sadly have no time to dig in now
<adambeynon> oh, hmm, not sure. I will install the same jruby version and have a look
<adambeynon> or rubinius, even
travis-ci has joined #opal
<travis-ci> [travis-ci] opal/opal#1592 (master - b0573f9 : Elia Schito): The build passed.
travis-ci has left #opal [#opal]
<travis-ci> [travis-ci] Build details : http://travis-ci.org/opal/opal/builds/15399577
<adambeynon> elia: looks to be a bug with StringScanner when parsing in rubinius if there is unicode characters
<adambeynon> it doesnt handle the unicode characters correctly
<adambeynon> and the index in the scanner seems to be wrong for scanner.peek()
<elia> cc: brixen
<adambeynon> for each unicode character the index is 1 less than it should be
<adambeynon> maybe #check() would work instead
<adambeynon> i will try that
<elia> adambeynon, if there's a bug I'm quite sure rbx guy are more than eager to have it fixed :)
<adambeynon> elia: yeap. just confirmed that scanner.check(/::/) works, but scanner.peek() has the wrong index
<adambeynon> I will write an isolated test case to show it
<adambeynon> and open an issue
<adambeynon> (and to 100% confirm it is that, not something stupid im missing ;)
fkchang has joined #opal
<adambeynon> elia: Should I push a fix for rubinius+strscan? its basically changing a method from peek() to check(). the parser uses check() in all other cases anyway
<adambeynon> can still open an issue for rubinius
<adambeynon> but atleast we will have a working gem on rbz
<adambeynon> rbx*
<meh`> I vote for both
<adambeynon> pushing now
GitHub122 has joined #opal
GitHub122 has left #opal [#opal]
<GitHub122> [opal] adambeynon pushed 1 new commit to master: http://git.io/6bDtgw
<GitHub122> opal/master 5f7ec71 Adam Beynon: Replace use of scanner.peek with scanner.check to fix rbx parse bug...
<adambeynon> of course, the strscan code is now in the rubysl-strscan gem
<adambeynon> so its actually outside of rubinius
<elia> adambeynon, I agree with meh`
travis-ci has joined #opal
<travis-ci> [travis-ci] opal/opal#1593 (master - 5f7ec71 : Adam Beynon): The build passed.
travis-ci has left #opal [#opal]
<travis-ci> [travis-ci] Build details : http://travis-ci.org/opal/opal/builds/15406671
aep has joined #opal
brixen has quit [*.net *.split]
ryanstewart2 has quit [Ping timeout: 338 seconds]
ryanstewart has joined #opal
brixen_ has joined #opal
marcandre has joined #opal
dfranciosi has quit []
abowhill has quit [Quit: Page closed]
abowhill has joined #opal
moi2 has joined #opal
moi2 has left #opal [#opal]
elia has quit [Ping timeout: 250 seconds]
GitHub146 has joined #opal
GitHub146 has left #opal [#opal]
<GitHub146> [opal] adambeynon pushed 1 new commit to master: http://git.io/TjZqRQ
<GitHub146> opal/master 71218a2 Adam Beynon: Add remaining array specs from rubyspec
gverri has joined #opal
travis-ci has joined #opal
<travis-ci> [travis-ci] opal/opal#1594 (master - 71218a2 : Adam Beynon): The build passed.
<travis-ci> [travis-ci] Build details : http://travis-ci.org/opal/opal/builds/15411282
travis-ci has left #opal [#opal]
GitHub101 has joined #opal
GitHub101 has left #opal [#opal]
<GitHub101> [opal] adambeynon pushed 1 new commit to master: http://git.io/jjztXw
<GitHub101> opal/master 516ab31 Adam Beynon: Allow directory names inside spec/rubyspecs for all spec files to run
<meh`> adambeynon, \o/
<adambeynon> :D
<meh`> I wanted to do that for a long time
<adambeynon> lol yep - it was getting quite ridiculous
travis-ci has joined #opal
<travis-ci> [travis-ci] opal/opal#1595 (master - 516ab31 : Adam Beynon): The build was broken.
<travis-ci> [travis-ci] Build details : http://travis-ci.org/opal/opal/builds/15412132
travis-ci has left #opal [#opal]
<adambeynon> oh noooooo
<meh`> lol
<adambeynon> ruby 1.8
<adambeynon> AGAIN
<meh`> drop that shit already :(
<adambeynon> undefined method `exist?' for Dir:Class
<adambeynon> meh`: yeh, not sure its worth hanging onto anymore....
GitHub36 has joined #opal
<GitHub36> opal/master 32e0f6e Adam Beynon: Fix for 1.8.x not having Dir.exist?
GitHub36 has left #opal [#opal]
<GitHub36> [opal] adambeynon pushed 1 new commit to master: http://git.io/dNg6pQ
<adambeynon> the only argument for 1.8 is that there isnt really anything major that breaks it
<adambeynon> small minor fixes Im fine with
<adambeynon> e.g. ^^
<meh`> yeah but they add up
<adambeynon> true. well, as we are so close to 0.6, maybe that is a good time for "the last 1.8.x compatible release"
GitHub108 has joined #opal
<GitHub108> opal/master effb5f6 Adam Beynon: Cleanup spec whitelist for hash specs
<GitHub108> [opal] adambeynon pushed 1 new commit to master: http://git.io/76l4RQ
GitHub108 has left #opal [#opal]
<adambeynon> back a little later..
<fkchang> many of the point here are what I want to do for opal on front and backends http://differential.io/blog/meteor-killin-rails
<adambeynon> fkchang: yeap. Im looking at different ideas with one of my more mvc heavy apps
<adambeynon> e.g. a whitelist on having Vienna models available client side to match server side models
<adambeynon> also with haml + erb support, having certain templates available on both
<adambeynon> the only tricky part is that this cant be automatic, its got to be opt-in
<adambeynon> e.g. I dont want the User and ShoppingCart models client side
<adambeynon> fkchang: getting opal-activesupport up to scratch is a big part as well
<adambeynon> but yeah, really got to go ;) back laters
<meh`> apparently I'm using an outdated browser
<meh`> (firefox nightly)
travis-ci has joined #opal
<travis-ci> [travis-ci] opal/opal#1597 (master - effb5f6 : Adam Beynon): The build was fixed.
travis-ci has left #opal [#opal]
<travis-ci> [travis-ci] Build details : http://travis-ci.org/opal/opal/builds/15412945
<meh`> fkchang, well, let's make it happen with lissio then
<meh`> fkchang, there's already the Lissio::Server set up, we just have to hook something up in it
<meh`> and obviously add the client stuff
ryanstout has joined #opal
<meh`> now if only there was a way to get the source code of a Ruby block
<meh`> let's see
<meh`> adambeynon, ping
<meh`> adambeynon, come on, I need to do this super awesome thing and I need you to do it :<
DrShoggoth has joined #opal
ylluminate` has quit [Ping timeout: 252 seconds]
<meh`> elia_, adambeynon, fkchang, https://github.com/meh/paggio#with-opal :>
elia has joined #opal
DrShoggoth has quit [Read error: Connection reset by peer]
DrShoggoth has joined #opal
<elia> adambeynon, I'm removing the allow failure for rbx/jruby
ryanstout has quit [Quit: ryanstout]
<fkchang> meh`: re: meteor w/lissio, I'm game. I think there's some room to run a lissio server type thing on node aw well
<fkchang> meh`: re: paggio, cool, so this drives opal-browser now too, so now you can print out what the markup would look like in opal-browser.
GitHub18 has joined #opal
<GitHub18> opal/master 37b4166 Elia Schito: Get jruby/rbx out of the allowed failures pit...
<GitHub18> [opal] elia pushed 1 new commit to master: http://git.io/Rg1M_w
GitHub18 has left #opal [#opal]
e_dub has quit [Quit: It's a hard knock life]
ryanstout has joined #opal
GitHub189 has joined #opal
<GitHub189> opal-rails/0-6-stable 505ab02 Elia Schito: Update "gotcha" and include the sprockets fix
GitHub189 has left #opal [#opal]
<GitHub189> opal-rails/0-6-stable 3e252b9 Elia Schito: Get gems from git and cleanup gemspec
<GitHub189> [opal-rails] elia created 0-6-stable (+3 new commits): http://git.io/YOcHIg
<GitHub189> opal-rails/0-6-stable a1618c0 Elia Schito: Add fun
GitHub63 has joined #opal
<GitHub63> [opal-rails] elia force-pushed 0-6-stable from 505ab02 to f5d260e: http://git.io/Z7DChg
<GitHub63> opal-rails/0-6-stable 7ca6acf Elia Schito: Reference the PR that fixes the GOTCHAS...
GitHub63 has left #opal [#opal]
<GitHub63> opal-rails/0-6-stable 8eb8673 Elia Schito: Add fun
<GitHub63> opal-rails/0-6-stable f5d260e Elia Schito: Update "gotcha" and include the sprockets fix
GitHub137 has joined #opal
<GitHub137> [opal-rails] elia pushed 1 new commit to 0-6-stable: http://git.io/o_DpqA
GitHub173 has joined #opal
<GitHub137> opal-rails/0-6-stable 73f4a7e Elia Schito: Bump version
GitHub137 has left #opal [#opal]
<GitHub173> [opal-rails] elia tagged v0.6.2 at d1f2c8a: http://git.io/DWJ-4g
GitHub173 has left #opal [#opal]
travis-ci has joined #opal
<travis-ci> [travis-ci] Change view : https://github.com/opal/opal-rails/compare/3e252b904c2f^...505ab02b9d73
<travis-ci> [travis-ci] opal/opal-rails#77 (0-6-stable - 505ab02 : Elia Schito): The build failed.
travis-ci has left #opal [#opal]
<travis-ci> [travis-ci] Build details : http://travis-ci.org/opal/opal-rails/builds/15420305
travis-ci has joined #opal
<travis-ci> [travis-ci] opal/opal-rails#78 (0-6-stable - f5d260e : Elia Schito): The build passed.
travis-ci has left #opal [#opal]
<travis-ci> [travis-ci] Build details : http://travis-ci.org/opal/opal-rails/builds/15420571
travis-ci has joined #opal
<travis-ci> [travis-ci] opal/opal-rails#79 (0-6-stable - 73f4a7e : Elia Schito): The build passed.
<travis-ci> [travis-ci] Build details : http://travis-ci.org/opal/opal-rails/builds/15420589
travis-ci has left #opal [#opal]
GitHub56 has joined #opal
<GitHub56> [opal-rails] elia force-pushed master from c1ac10d to 2dc6c50: http://git.io/_X7Eqw
<GitHub56> opal-rails/master 529efbd Elia Schito: opal-sprocket has been merged into opal
GitHub56 has left #opal [#opal]
<GitHub56> opal-rails/master 719a995 Elia Schito: Target latest opal
<GitHub56> opal-rails/master a0836e3 Elia Schito: …and latest opal-sprockets
travis-ci has joined #opal
<travis-ci> [travis-ci] opal/opal-rails#80 (v0.6.2 - 73f4a7e : Elia Schito): The build passed.
travis-ci has left #opal [#opal]
<travis-ci> [travis-ci] Build details : http://travis-ci.org/opal/opal-rails/builds/15420593
<travis-ci> [travis-ci] Change view : https://github.com/opal/opal-rails/compare/v0.6.2
travis-ci has joined #opal
<travis-ci> [travis-ci] opal/opal-rails#81 (master - 2dc6c50 : Elia Schito): The build failed.
<travis-ci> [travis-ci] Build details : http://travis-ci.org/opal/opal-rails/builds/15420839
travis-ci has left #opal [#opal]
<meh`> fkchang, not yet, I still have to do the backport
<meh`> but it will soon
<adambeynon> meh`: source code of a ruby block at runtime?
<meh`> adambeynon, already got it
<meh`> now I only have to make the DSLs a bit more solid
<meh`> then scrap the opal-browser stuff
<meh`> and use paggio inside opal-browser
<meh`> since it creates an usable middle thingy
<meh`> and on top of it you can transform it into a string at all times
<meh`> which will obviously be good for opal-inspector
<meh`> fkchang, but it's pretty nice standalone too, I had to make a single page static website and I'd usually go with HAML/SCSS, but I was too lazy to remind myself how HAML and SCSS work so I wrote paggio instead
<elia> "[…] so I wrote paggio instead" → classic meh`
<meh`> lol
marcandre has quit [Remote host closed the connection]
marcandre has joined #opal
marcandre has quit [Remote host closed the connection]
ryanstout has quit [Quit: ryanstout]
<fkchang> meh`: I can wait on the back port. I was going to build into opal-inspector stuff to preview markup and stuff, or markup generated.
<fkchang> adambeynon: any progress w/storing the code/comments in opal?
<meh`> fkchang, well, I'm doing it now :)
<fkchang> nice, how's coming
<fkchang> I'm curious as to how we'll handle stuff defined on the class level, say inldes, attr_accessor, etc.
elia has quit [Read error: Connection reset by peer]
elia has joined #opal
<adambeynon> fkchang: the parts I am struggling with are the comments for things like attr_accessor etc? simple defs inside modules and classes are easy
<adambeynon> How to deliver this all to a browser session is also tricky though...
<meh`> adambeynon, I was thinking
<meh`> adambeynon, we really need some kind of simple stupid tool to transform a gem to a self-contained javascript file
<meh`> possibly with requires too
<meh`> like
<meh`> opal-gem opal-browser -r 'browser' -r 'browser/canvas'
<meh`> and it spits out an opal-browser.js
<adambeynon> meh`: would you want it to go through and include all requires?
<adambeynon> e.g. corelib and stlib stuff
<adambeynon> and other gems
<adambeynon> stdlib*
<adambeynon> I have thought of something similar, but could never decide on how to handle requires()
<adambeynon> e.g. I wanted a quick way to create an opal-jquery.js file for a "quick start at using opal"
<adambeynon> but then you could end up with 3 files all including set.rb
<meh`> adambeynon, no
<meh`> adambeynon, single things
<meh`> a gem, an stdlib, opal itsel
<meh`> opal-parser
<meh`> so you can generate them on the go
<meh`> and include them
<meh`> I'm specifically thinking about paggio here
<meh`> where I include the gems separately
<adambeynon> opal-parser requires 3 stdlib files, so getting that working, for example, would be a pain
<meh`> adambeynon, well, actually, yes
<meh`> adambeynon, yeah, just realized that
<meh`> mmh
<adambeynon> meh`: as much of a pain as sprockets is, using it as a kind of standard build system does keep things ticking over nicely...
<fkchang> adambeynon: so part of the whole "smalltalk like" experience of opal browser is to develop in the browser, then I'd want to send the changed code back to the server. At the moment, I imagine something similar to diffs/monkey patching. I thought an easy first step would be "show all the code and comments for a class", which is where I'd see comments and code at the class level. per the inspector editing, getting the code/comments per
<fkchang> method is straight forward, not certain where I'd put the editing for the in class stuff exactly
<adambeynon> (also, I hate client side require systems like requirejs)
<meh`> (yeah, I agree)
<adambeynon> fkchang: I wonder if workspaces in google chrome devtools might offer some help
<adambeynon> or even some APIs to interact with the server based stuff
<adambeynon> I havent looked into Workspaces much, but Im sure I have seen a presentation of a guy editing scss code in chrome
<adambeynon> and pushing it back up to remote
<fkchang> adambeynon: hmm, that could work, off of edubkendo's chrome page i though maybe working over there, but thought the ability to run tools in any browser that supports opal also is a benefit (can you say IE?)
<fkchang> At the simplest level, if we were doing just methods only, it'd be simple lookup, for X method what is the combined code/comments?
<fkchang> but Ruby isn't only methods
<fkchang> We could still do everything if we could generate unique names
<fkchang> I could push such a thing to the server too, though would have to support some way of monkeypatching code into the server. A quick short cut is to be able to generate the "what does the whole class look like now" and then paste that into a file
<adambeynon> fkchang: well, if we take one method at a time, we know the original start and end line numbers, so a simple diff between the two could be easy enough to push up
<adambeynon> even a simple 'replace line x...y with "this new code"'
elia has quit [Quit: Computer has gone to sleep.]
<fkchang> Yeah, at one point I was thinking of diffs and PR's, possible even a PR like system for you to go back on the server and "pick" what changes you want to keep
<fkchang> also thought about just outsource that to git on the server side
gverri has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<fkchang> that might be too hard to get out quickly, but I thought about, "show me what this class looks like now", or maybe "show me the complete code for every class that has changed" -- that could be quick to develop, and then tackle the more complicated stuff later
<adambeynon> fkchang: yep
<adambeynon> fkchang: btw, did you get the opal-rspec working?
<adambeynon> a custom runner.erb file should be able to do the trick