Hmm…this is an interesting case. It's possible that we've not fully looked into calling super with explicit block args. Can you see if this can be reduced to a simple, self-contained example? Either way, it would be good to have a Trac ticket for this issue.
Thanks! - Josh On Thursday, January 12, 2012 at 9:37 AM, Francis Chong wrote: > Hi > > I can repeat the issue. It is working good with Sinatra 1.0.0 -> > > https://gist.github.com/1600852 > > > Kevin Poorman ©ó 2012¦~1¤ë12¤é ¤U¤È9:17 ¼g¹D¡G > > > Morning all, > > > > I'm having a go at setting up a macRuby app that utilizes Control Tower and > > Sinatra. > > I've no problem installing the gems for either, but the current versions of > > each seem to be mutually exclusive, as they require specific versions of > > Rack that do not match. > > > > I poked around and couldn't identify any reasons why a new version of Rack > > wouldn't work, so I forked/edited/built/installed ControlTower 1.0.me > > (http://1.0.me) and gave it a go. Control tower by itself seems to be doing > > Great. However, if I attempt to load sinatra for the never-been-done-before > > hello world example, I get this: > > > > /Users/kpoorman/Library/Developer/Xcode/DerivedData/ControlTowerTest-gpdchdkfcdvfgdczhlapcihrrkpc/Build/Products/Debug/ControlTowerTest.app/Contents/Resources/rb_main.rb:20:in > > `block': wrong number of arguments (1 for 0) (ArgumentError) > > from > > /Users/kpoorman/Library/Developer/Xcode/DerivedData/ControlTowerTest-gpdchdkfcdvfgdczhlapcihrrkpc/Build/Products/Debug/ControlTowerTest.app/Contents/Resources/rb_main.rb:17:in > > `<main>' > > > > Fast forward 30 minutes, and I've narrowed it down to a block of perfectly > > working MRI-ruby: > > > > return super(*args, &block) if respond_to? method_name > > > > Specifically, if I start loading Sinatra components in macirb, it works > > great until you hit a Set or Enable method call, which in turn invokes the > > Delegator mixing ¡K etc down to line 1601 of sinatra::base (version 1.4.0) > > which is above. > > > > So, I suppose I should use your time wisely and ask a couple of direct > > questions -- > > > > 1: what, if anything, am I doing wrong? > > 2: Is this version of sinatra incompatible with Control Tower? > > 2a: what version of sinatra *is* compatible ? > > 3: is this a Macruby bug? > > 3a: I like to think of myself as a fairly advanced ruby developer, with > > excellent knowledge of meta-programming and the sinatra framework, what I > > don't understand, is what's wrong with that code ? > > > > Thank you for your time! > > > > -Kevin > > _______________________________________________ > > MacRuby-devel mailing list > > MacRuby-devel@lists.macosforge.org > > (mailto:MacRuby-devel@lists.macosforge.org) > > http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel > > > > > _______________________________________________ > MacRuby-devel mailing list > MacRuby-devel@lists.macosforge.org (mailto:MacRuby-devel@lists.macosforge.org) > http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel > >
_______________________________________________ MacRuby-devel mailing list MacRuby-devel@lists.macosforge.org http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel