Changeset 38beeab in sasview for sasview/sasview.py
- Timestamp:
- Apr 9, 2017 1:45:49 AM (7 years ago)
- Branches:
- master, ESS_GUI, ESS_GUI_Docs, ESS_GUI_batch_fitting, ESS_GUI_bumps_abstraction, ESS_GUI_iss1116, ESS_GUI_iss879, ESS_GUI_iss959, ESS_GUI_opencl, ESS_GUI_ordering, ESS_GUI_sync_sascalc, costrafo411, magnetic_scatt, release-4.2.2, ticket-1009, ticket-1094-headless, ticket-1242-2d-resolution, ticket-1243, ticket-1249, ticket885, unittest-saveload
- Children:
- 797a2e8
- Parents:
- 5af6f58
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
sasview/sasview.py
r5af6f58 r38beeab 18 18 import traceback 19 19 20 logger = logging.getLogger(__name__) 21 if not logger.root.handlers: 22 # Scripts running under py2exe do not have a __file__ global. Detect this and use sys.argv[0] instead. 23 try: 24 LOGGER_CONFIG_FILE = os.path.join(os.path.abspath(os.path.dirname(__file__)), 'logging.ini') 25 except NameError: # We are the main py2exe script, not a module 26 LOGGER_CONFIG_FILE = os.path.join(os.path.abspath(os.path.dirname(sys.argv[0])), 'logging.ini') 27 logging.config.fileConfig(LOGGER_CONFIG_FILE, disable_existing_loggers=False) 28 logging.captureWarnings(True) 20 from logger_config import SetupLogger 21 22 l = SetupLogger(__name__) 23 logger = l.config_production() 29 24 30 25 # Log the start of the session
Note: See TracChangeset
for help on using the changeset viewer.