Permalink
Browse files

Gotta log each spacer line separately to ensure each is tagged

  • Loading branch information...
jeremy committed Oct 7, 2012
1 parent 1a70499 commit d073116455d971b39091188a1644d204424b40e8
Showing with 4 additions and 1 deletion.
  1. +4 −1 railties/lib/rails/rack/logger.rb
@@ -23,7 +23,10 @@ def call(env)
def call_app(request, env)
# Put some space between requests in development logs.
- Rails.logger.info "\n\n" if Rails.env.development?
+ if Rails.env.development?
+ Rails.logger.info ''
+ Rails.logger.info ''
+ end
Rails.logger.info started_request_message(request)
@app.call(env)

3 comments on commit d073116

Owner

tenderlove replied Nov 9, 2012

Is this valuable information that needs to be logged? :trollface:

The aesthetic is not very pleasing to me:

I, [2012-11-09T11:10:04.739892 #56883]  INFO -- : Started GET "/assets/jquery_ujs.js?body=1" for 127.0.0.1 at 2012-11-09 11:10:04 +0900
I, [2012-11-09T11:10:04.739935 #56883]  INFO -- : Started GET "/assets/jquery_ujs.js?body=1" for 127.0.0.1 at 2012-11-09 11:10:04 +0900
I, [2012-11-09T11:10:04.744175 #56883]  INFO -- : 
I, [2012-11-09T11:10:04.744284 #56883]  INFO -- : 
I, [2012-11-09T11:10:04.744332 #56883]  INFO -- : 
I, [2012-11-09T11:10:04.744370 #56883]  INFO -- : 
I, [2012-11-09T11:10:04.744504 #56883]  INFO -- : Started GET "/assets/application.css?body=1" for 127.0.0.1 at 2012-11-09 11:10:04 +0900
I, [2012-11-09T11:10:04.744580 #56883]  INFO -- : Started GET "/assets/application.css?body=1" for 127.0.0.1 at 2012-11-09 11:10:04 +0900
I, [2012-11-09T11:10:04.748278 #56883]  INFO -- : 
I, [2012-11-09T11:10:04.748480 #56883]  INFO -- : 
I, [2012-11-09T11:10:04.748689 #56883]  INFO -- : 
I, [2012-11-09T11:10:04.748738 #56883]  INFO -- : 
I, [2012-11-09T11:10:04.748896 #56883]  INFO -- : Started GET "/assets/jquery.js?body=1" for 127.0.0.1 at 2012-11-09 11:10:04 +0900
I, [2012-11-09T11:10:04.748942 #56883]  INFO -- : Started GET "/assets/jquery.js?body=1" for 127.0.0.1 at 2012-11-09 11:10:04 +0900
Owner

jeremy replied Nov 9, 2012

😢

We could suppress dev logging at the assets endpoint in dev?

Owner

guilleiguaran replied Nov 9, 2012

@jeremy yes sir, it's on my TODO list 😃

Please sign in to comment.