Rails development environment circular dependency error

Last night I thought I did something that closed my rails development environment and I cannot undo what I did.

I ported the update to production and had some problems with precompiling the stylesheet, so I reversed the changes and decided to try precompiling on my development machine.

Long story short, precompilation failed on my development machine (local), but when I tried to start my test system, I got this error:

Asterisks :: CircularDependencyError in development / sessions # new

/app/assets/stylesheets/application.css is already required

I'm sure it has something to do with my attempt at precompilation, although it didn't work because everything worked fine before.

I tried to do precompile: clear because I read somewhere that will undo / remove the precompilation.

Am I missing something? Does the pre-compile config file represent where I need to manually reset?

This is rails 3.1 running on Ubuntu 11.10.


source to share

2 answers

This is because your application.css.scss most likely requires a css file that requires application.css.scss. You want to go through app/assets/stylesheets

and check the headers application.css.scss

and then the headers of all the files that are required to make sure none of them referenced application.css.scss




I fixed this by creating application.css.scss and importing each of my files there, for example:

@import "backend.css.scss"; @import "frontend.css.scss";

then he worked



All Articles