#652 closed defect (fixed)

Logging is broken when "error while determining build number" is emitted

Reported by: smk78 Owned by: wojciech
Priority: major Milestone: SasView 4.1.0
Component: SasView Keywords:
Cc: Work Package: SasView Bug Fixing

Description

Reported by PaulK:

Logging is broken on sasview when "Error while determining build number" is emitted.

According to the following, if a log message is emitted before logging is configured, then the configuration is ignored:

http://stackoverflow.com/questions/29853011/root-logger-ignoring-logger-level#29853012

Logging is configured in sasview/sasview.py, which is not run until after sasview/_init_.py, but sasview/_init_.py gives a warning when the git command is run.

Rather than calling git at runtime in sasview/_init_.py, shouldn't we call it in setup.py so that it happens at install time? Note: be sure to capture the build number when uploading to pypi with "python setup.py sdist upload". run.py could poke the build number into sasview._init_ as part of prepare().

Change History (4)

comment:1 Changed 12 months ago by butler

  • Owner set to wojciech
  • Status changed from new to assigned

comment:2 Changed 12 months ago by butler

  • Milestone changed from SasView 4.0.0 to SasView 4.1.0

comment:3 Changed 12 months ago by wojciech

The logging is working now as the git revision number has been fixed in the commit: a3f1c11e89e334f2707e2834709485c8107d1e72

comment:4 Changed 12 months ago by wojciech

  • Resolution set to fixed
  • Status changed from assigned to closed
Note: See TracTickets for help on using tickets.