Sprockets 2.0.0.beta.11 breaks assets

133 views
Skip to first unread message

Matt Smart

unread,
Jun 21, 2011, 3:35:33 PM6/21/11
to Ruby on Rails: Core
Hello!

I'm really not sure what the change was the broke it, but rails
3.1.0.rc4 with the version of sprockets that just got tagged today
(2.0.0.beta.11) no longers works with the assets pipeline. I get the
following errors in my server logs:

-----
Started GET "/assets/application.css" for 127.0.0.1 at 2011-06-21
15:23:44 -0400
Served asset /application.css - 404 Not Found (0ms)

ActionController::RoutingError (No route matches [GET] "/assets/
application.css"):
-----
and
-----
Started GET "/assets/application.js" for 127.0.0.1 at 2011-06-21
15:23:44 -0400
Served asset /application.js - 404 Not Found (0ms)

ActionController::RoutingError (No route matches [GET] "/assets/
application.js"):
-----

putting the following line in my Gemfile seems to fix the problem:

gem 'sprockets', '= 2.0.0.beta.10'

Maybe someone has an idea of what part of sprockets 2.0.0.beta.11
broke things?

Ryan Bigg

unread,
Jun 21, 2011, 7:05:45 PM6/21/11
to rubyonra...@googlegroups.com
Have you tried cloning this into a local dir and specifying that as a path like this:

gem 'sprockets', :path => "vendor/sprockets"

And then attempt to run a git bisect over that directory to figure out what, if anything, broke between beta10 and beta11? I mean, you *do* have good and bad refs to start from.
--
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Core" group.
To post to this group, send email to rubyonra...@googlegroups.com.
To unsubscribe from this group, send email to rubyonrails-co...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/rubyonrails-core?hl=en.

Ryan Bigg

unread,
Jun 21, 2011, 7:13:27 PM6/21/11
to rubyonra...@googlegroups.com
Oh, and I can confirm this issue.

I would have thought this would have been picked up before beta11 was released, given it's basically *the* functionality in Sprockets.

Matthew Smart

unread,
Jun 21, 2011, 7:38:36 PM6/21/11
to rubyonra...@googlegroups.com
I ran a bisect and found this:

4b7afcc3553c149261f457c3de88ff9d5458a3f6 is the first bad commit
commit 4b7afcc3553c149261f457c3de88ff9d5458a3f6
Author: Joshua Peek <jo...@joshpeek.com>
Date:   Sat Jun 11 12:35:13 2011 -0500

    Create Base class for Environment and Index

:040000 040000 5423b6f2fc31d6834207ada0252fa2e61086be74 0b0396b560ccb5947bf5c47668e6629c7c60e525 M lib
:040000 040000 112d4ec7a3a494c29693546cc19abb2a1ba4e475 8fe7693a9440ae64fd7ae79dc37f7cf5e4607ae4 M test

I'm not quite sure how to narrow the problem down further. There were quite a lot of changes in that commit.

Anurag

unread,
Jun 21, 2011, 5:05:01 PM6/21/11
to Ruby on Rails: Core
I am having the same problem with sprockets 2.0.0.beta.11. The assets
are not getting generated. Rolling back to beta 10 solves the problem.

Nik

unread,
Jun 23, 2011, 9:13:36 PM6/23/11
to Ruby on Rails: Core
I have the same problem, too, Anurag, how do you roll back to beta 10,
I try doing that in the Gemfile, but it says that it cannot find
2.0.0.beta.11 (?!) and just gives up instead of installing and using
2.0.0.beta.10

Ryan Bigg

unread,
Jun 27, 2011, 1:17:20 AM6/27/11
to rubyonra...@googlegroups.com
Nik: Specify this line in your Gemfile:

 gem 'sprockets', '2.0.0.beta10'

Make sure there isn't one there for 2.0.0.beta11 or anything else mentioning sprockets.

Then run bundle update sprockets. This will change it to the correct version.

Luiz Felipe Garcia Pereira

unread,
Jun 27, 2011, 7:02:36 AM6/27/11
to rubyonra...@googlegroups.com
Even with beta10, sprockets are not working with 3-1-stable rails branch


--
Luiz Felipe G. Pereira

Anurag

unread,
Aug 2, 2011, 3:31:06 PM8/2/11
to Ruby on Rails: Core
This issue seems to have been fixed in Rails RC5. Add this line to
your Gemfile.

gem 'rails', '3.1.0.rc5'

We don't have to override the version of sprockets now. The version
that is picked up by default is sprockets-2.0.0.beta.12, which seems
to contain a fix.

On Jun 21, 12:35 pm, Matt Smart <m.d.sm...@gmail.com> wrote:
Reply all
Reply to author
Forward
0 new messages