Reputation: 1215
I'm running on rails4, bootstrap 3 and I get the following error message in my terminal.
Started GET "/assets/bootstrap.css.map" for 127.0.0.1 at 2014-08-24 23:41:36 -0700
ActionController::RoutingError (No route matches [GET] "/assets/bootstrap.css.map"):
actionpack (4.1.4) lib/action_dispatch/middleware/debug_exceptions.rb:21:in `call'
actionpack (4.1.4) lib/action_dispatch/middleware/show_exceptions.rb:30:in `call'
railties (4.1.4) lib/rails/rack/logger.rb:38:in `call_app'
railties (4.1.4) lib/rails/rack/logger.rb:20:in `block in call'
activesupport (4.1.4) lib/active_support/tagged_logging.rb:68:in `block in tagged'
activesupport (4.1.4) lib/active_support/tagged_logging.rb:26:in `tagged'
activesupport (4.1.4) lib/active_support/tagged_logging.rb:68:in `tagged'
railties (4.1.4) lib/rails/rack/logger.rb:20:in `call'
actionpack (4.1.4) lib/action_dispatch/middleware/request_id.rb:21:in `call'
rack (1.5.2) lib/rack/methodoverride.rb:21:in `call'
rack (1.5.2) lib/rack/runtime.rb:17:in `call'
activesupport (4.1.4) lib/active_support/cache/strategy/local_cache_middleware.rb:26:in `call'
rack (1.5.2) lib/rack/lock.rb:17:in `call'
actionpack (4.1.4) lib/action_dispatch/middleware/static.rb:64:in `call'
rack (1.5.2) lib/rack/sendfile.rb:112:in `call'
railties (4.1.4) lib/rails/engine.rb:514:in `call'
railties (4.1.4) lib/rails/application.rb:144:in `call'
rack (1.5.2) lib/rack/lock.rb:17:in `call'
rack (1.5.2) lib/rack/content_length.rb:14:in `call'
rack (1.5.2) lib/rack/handler/webrick.rb:60:in `service'
Anyone have any ideas how to get rid of this?
EDIT:
This is my application.css
*= require_tree .
*= require_self
*= require_ladda-themeless
*= require login_form
*= require bootstrap
*/
Upvotes: 29
Views: 23941
Reputation: 41
my error: ActionController::RoutingError (No route matches [GET] "/assets/bootstrap.min.css.map"):
I created an empty bootstrap.min.css.map in assets folder, the error stopped.
Upvotes: -1
Reputation: 3266
The file that requests the bootstrap.css.map
is:
/vendor/assets/stylesheets/bootstrap.css
And removing this last line should fix the problem:
/*# sourceMappingURL=bootstrap.css.map */
See here what are map files used for.
Upvotes: 46
Reputation: 1797
I had the same problem and found this short answer on SO. From what I understand the map files are an aid to debugging tools in the browser. Quick fix is to find where this map file is included, by issuing a command line find.
find . -name "*.css" -o -name "*.scss" | xargs grep 'sourceMappingURL=bootstrap.css.map'
Then either delete the line from your css file or move it to where it will be looking for it.
Upvotes: 8
Reputation: 1215
Ok, so instead of having native bootstrap files under the app/assets folder, I just created custom.css.scss under app/assets/stylesheets and included @import "bootstrap";
Then, I removed all the bootstrap files from app/assets folder which solved the problem.
Upvotes: 5