Opened 4 years ago

Last modified 20 months ago

#2839 accepted enhancement

Buildbot does not consistenly do logging

Reported by: sa2ajj Owned by: craig
Priority: patches-accepted Milestone: 0.9.+
Version: master Keywords: logging, simple
Cc: craig5@…

Description

In many places a log.{msg,err} (log is import from twisted.python) is used to log various information that might be useful later.

However there's a significant chunk of code that uses print to produce all kind of debug/error output.

I'm not sure this is a major ticket, I just wonder if there're any kind of guidelines about how logging should be performed and if there's a need to convert those prints to either log.msg or log.err?

Change History (5)

comment:1 Changed 4 years ago by dustin

print in a twistd environment ends up in the logfile.

However, in production code we should always be logging, not printing. Based on a quick grep, I see that we *almost* always adhere to this standard. Legitimate exceptions are:

  • scripts and clients like 'create-master' or 'debug' that actually want to produce stdout
  • contrib (it can do whatever it wants)

Cleaning up any other occurrences would be a good fix.

comment:2 Changed 4 years ago by dustin

  • Keywords simple added
  • Milestone changed from undecided to 0.9.0
  • Priority changed from major to patches-accepted
  • Type changed from undecided to enhancement

comment:3 Changed 4 years ago by craig

  • Cc craig5@… added
  • Owner set to craig
  • Status changed from new to accepted

comment:4 Changed 4 years ago by sa2ajj

  • Milestone changed from 0.9.0 to 0.9.+
Note: See TracTickets for help on using tickets.