-
Notifications
You must be signed in to change notification settings - Fork 48
Closed
Labels
DefectBug or undesirable behaviourBug or undesirable behaviourMajorBig change in the code or important change in behaviourBig change in the code or important change in behaviour
Milestone
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-levelhttp://trac.sasview.org/ticket/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().
Migrated from http://trac.sasview.org/ticket/652
{
"status": "closed",
"changetime": "2016-10-06T15:53:56",
"_ts": "2016-10-06 15:53:56.981250+00:00",
"description": "Reported by PaulK:\n\nLogging is broken on sasview when \"Error while determining build number\" is emitted.\n\nAccording to the following, if a log message is emitted before logging is configured, then the configuration is ignored:\n\n http://stackoverflow.com/questions/29853011/root-logger-ignoring-logger-level#29853012\n\nLogging 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.\n\nRather 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().\n",
"reporter": "smk78",
"cc": "",
"resolution": "fixed",
"workpackage": "SasView Bug Fixing",
"time": "2016-09-08T09:59:05",
"component": "SasView",
"summary": "Logging is broken when \"error while determining build number\" is emitted",
"priority": "major",
"keywords": "",
"milestone": "SasView 4.1.0",
"owner": "wojciech",
"type": "defect"
}Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
DefectBug or undesirable behaviourBug or undesirable behaviourMajorBig change in the code or important change in behaviourBig change in the code or important change in behaviour