rstacruz / sinatra-assetpack

Package your assets transparently in Sinatra.
http://ricostacruz.com/sinatra-assetpack/
MIT License
541 stars 97 forks source link

Sinatra 1.3.0 error: private method `public' called for <klass>:Class #25

Closed jcoffin closed 11 years ago

jcoffin commented 12 years ago

Using Sinatra 1.3.0.

This simple sinatra app:

require "sinatra/base"
require "sinatra/assetpack"

class App < Sinatra::Base
  register Sinatra::AssetPack
  assets {
    css :application, '/css/application.css', [ '/css/screen.css' ]
  }
  get "/hi" do
    "Hello World!"
  end
end

Throws this exception:

/home/jcoffin/.rbenv/versions/1.9.2-p290/lib/ruby/gems/1.9.1/gems/sinatra-assetpack-0.0.10/lib/sinatra/assetpack/options.rb:47:in `initialize': private method `public' called for App:Class (NoMethodError)
    from /home/jcoffin/.rbenv/versions/1.9.2-p290/lib/ruby/gems/1.9.1/gems/sinatra-assetpack-0.0.10/lib/sinatra/assetpack/class_methods.rb:7:in `new'
    from /home/jcoffin/.rbenv/versions/1.9.2-p290/lib/ruby/gems/1.9.1/gems/sinatra-assetpack-0.0.10/lib/sinatra/assetpack/class_methods.rb:7:in `assets'
    from app.rb:7:in `<class:App>'
    from app.rb:4:in `<main>'
rstacruz commented 12 years ago

Fixed that error—however, tests still fail for 1.3.0. I'll look into it soon.

adambair commented 12 years ago

I'm also having this issue in: gems/sinatra-assetpack-0.0.10 with sinatra 1.3.3

Aupajo commented 12 years ago

Same here, sinatra-assetpack 0.0.10 with sinatra 1.3.1.

rstacruz commented 12 years ago

[Note to self: push 0.0.11 soon so people don't have to suffer :)]

coen-hyde commented 12 years ago

yes please :)

glortho commented 12 years ago

Same problem with assetpack 0.0.10 and sinatra 1.2.6

hlascelles commented 12 years ago

Same problem with 0.0.10 and Padrino 0.10.5

Using

gem 'sinatra-assetpack', :require => 'sinatra/assetpack', :git => 'git://github.com/rstacruz/sinatra-assetpack.git'

fixes it of course.... for now.

Aupajo commented 12 years ago

@rstacruz It's time to push :)

jonathannen commented 12 years ago

+1

cj commented 12 years ago

+1

coffeeaddict commented 12 years ago

+1

audy commented 12 years ago

+1

mmb commented 12 years ago

+1

Bastes commented 12 years ago

+1

motdotla commented 12 years ago

+1 for the gem bump

stnguyen commented 12 years ago

+1, pls bump the gem

Aupajo commented 12 years ago

Have sent @rstacruz an email.

Aupajo commented 12 years ago

Got an email on Friday – it's now been pushed. Hopefully the new version should be fine.

j15e commented 11 years ago

Closing this, fixed in 0.0.11 and/or new 0.1.0 released yesterday. Otherwise reopen.