celluloid / reel-rack

UNMAINTAINED: See celluloid/celluloid#779
https://celluloid.io
MIT License
51 stars 24 forks source link

Doesn't work with Celluloid 0.17 #21

Open b-dean opened 8 years ago

b-dean commented 8 years ago

The very basic example in the wiki won't work with celluloid 0.17

config.ru looks like:

run Proc.new {|env| [200, {"Content-Type" => "text/html"}, "Hello Rack!"]}

Gemfile

source 'https://rubygems.org'
gem 'reel-rack', github: 'celluloid/reel-rack'

when I run it:

$ bundle exec reel-rack
I, [2015-09-14T18:45:13.747559 #4193]  INFO -- : Celluloid 0.17.1.2 is running in BACKPORTED mode. [ http://git.io/vJf3J ]
/tmp/foo/vendor/bundle/ruby/2.2.0/gems/celluloid-supervision-0.20.1.1/lib/celluloid/supervision/deprecate/supervise.rb:54:in `router': undefined method `services' for Celluloid:Module (NoMethodError)
    from /tmp/foo/vendor/bundle/ruby/2.2.0/gems/celluloid-supervision-0.20.1.1/lib/celluloid/supervision/deprecate/supervise.rb:11:in `supervise_as'
    from /tmp/foo/vendor/bundle/ruby/2.2.0/gems/celluloid-supervision-0.20.1.1/lib/celluloid/supervision/deprecate/supervise.rb:24:in `supervise_as'
    from /tmp/foo/vendor/bundle/ruby/2.2.0/bundler/gems/reel-rack-2edd5ff371a9/lib/rack/handler/reel.rb:18:in `run'
    from /tmp/foo/vendor/bundle/ruby/2.2.0/bundler/gems/reel-rack-2edd5ff371a9/lib/reel/rack/cli.rb:47:in `run'
    from /tmp/foo/vendor/bundle/ruby/2.2.0/bundler/gems/reel-rack-2edd5ff371a9/bin/reel-rack:5:in `<top (required)>'
    from /tmp/foo/vendor/bundle/ruby/2.2.0/bin/reel-rack:23:in `load'
    from /tmp/foo/vendor/bundle/ruby/2.2.0/bin/reel-rack:23:in `<main>'

works fine with gem 'celluloid', '< 0.17' in the Gemfile

b-dean commented 8 years ago

Could this have something to do with celluloid/reel#202? Maybe Reel doesn't work on the new Celluloid :frowning:

teoric commented 8 years ago

Indeed. I got this error when trying Gollum, which uses reel-rack. Adding require 'celluloid/current' as first line to /lib/rack/handler/reel.rb fixed the error for me.

chewi commented 6 years ago

I think this can be closed now.