Topic: application.css isn't precompiled... but it is.

Configuration is Ruby 1.8.7 / RubyGems 1.7.2 / Rails 3.1.1 on local test machine as well as web server.

Precompiled using rake assets:precompile

The process finishes without error.

Production log file indicates:

Compiled application.css  (6ms)  (pid 17887)

When I hit the site I get a 500 error. Production log file is as follows:

Completed 500 Internal Server Error in 5ms

ActionView::Template::Error (application.css isn't precompiled):
    2: <html>
    3: <head>
    4:   <title>Dispatch</title>
    5:   <%= stylesheet_link_tag    "application" %>
    6:   <%= javascript_include_tag "application" %>
    7:   <%= csrf_meta_tags %>
    8: </head>
  app/views/layouts/application.html.erb:5:in `_app_views_layouts_application_html_erb__409274279_23456256023560'

I've searched for an answer and tried many different things but have so far been unable to solve this problem, including changing settings in production.rb file:

config.assets.precompile += %w[active_admin.css active_admin.js]
Did not work.

Another site suggested setting:
config.assets.compile = true

Still no dice.

This is driving me nuts because it seems to be a problem of the needle-in-a-haystack variety.

I'd be forever grateful if someone could provide some guidance for my bleary-eyed quest.

Last edited by PaulP (2011-11-19 00:51:56)

Re: application.css isn't precompiled... but it is.

Did you ever find a solution to this?  I'm having the same problem.

In my config, I have:

 config.assets.manifest = Rails.root.join("public/assets")

And I have verified that public/assets/application.css and application.css.gz are both in fact there with the correct contents.  And also verified that they are readable by the server.

But I'm still getting the error:  ActionView::Template::Error (application.css isn't precompiled)

I'm running ruby 1.9.2, rails 3.1.3 in production mode, and passenger 3.0.11.

Last edited by kclair (2011-12-21 14:50:42)

Re: application.css isn't precompiled... but it is.

Interestingly, enabling digests fixed this for me.

Re: application.css isn't precompiled... but it is.

same for me - except that my site was running fine until I disabled digests...
then I get the application.css isn't precompiled error