NAVADMC / ADSM

A simulation of disease spread in livestock populations. Includes detection and containment simulation.
Other
10 stars 5 forks source link

Command Window Error Messaages #471

Closed casesp closed 9 years ago

casesp commented 9 years ago

When starting the adsm.exe program for the first time, the popped-up command window contains a lot of debugging information, along with error and alert messages.

This was run for the first time, as a fresh install of adsm, on a fresh Windows 7 Professional virtual machine (VMWare) with a 4 core CPU and 6Gb RAM.

Capture:

Importing Python dependencies and setting local path... C:\Users\scase\Desktop\ADSM_3.2.22-RC5.1 Preparing Django environment... [03/Apr/2015:09:29:57] ENGINE Bus STARTING [03/Apr/2015:09:29:57] ENGINE Started monitor thread '_TimeoutMonitor'. [03/Apr/2015:09:29:57] ENGINE Started monitor thread 'Autoreloader'. nginx: [alert] could not open error log file: CreateFile() "logs/error.log" fail ed (3: The system cannot find the path specified) [03/Apr/2015:09:29:58] ENGINE Serving on http://127.0.0.1:8001 [03/Apr/2015:09:29:58] ENGINE Bus STARTED [Errno 2] No such file or directory: 'C:\Users\scase\Documents\ADSM Workspac e\Sample Scenario with Outputs\population_map.png' [Errno 2] No such file or directory: 'C:\Users\scase\Documents\ADSM Workspac e\Sample Scenario with Outputs\population_thumbnail.png' Deleting C:\Users\scase\Documents\ADSM Workspace\settings\settings.sqlite3 Operations to perform: Synchronize unmigrated apps: floppyforms, productionserver, crispy_forms Apply all migrations: admin, Results, auth, ADSMSettings, sessions, ScenarioCr eator, contenttypes Synchronizing apps without migrations: Creating tables... Installing custom SQL... Installing indexes... Running migrations: Applying ADSMSettings.0001_initial... OK Applying ADSMSettings.0002_simulationprocessrecord... OK Applying ADSMSettings.0003_smsession_simulation_has_started... OK Applying ScenarioCreator.0001_initial... OK Applying Results.0001_initial... OK Applying ScenarioCreator.0002_contact_ratehelp_text... OK Applying ScenarioCreator.0003_auto_20150126_1358... OK Applying ScenarioCreator.0004_auto_20150302_1619... OK Applying contenttypes.0001_initial... OK Applying auth.0001_initial... OK Applying admin.0001_initial... OK Applying sessions.0001_initial... OK Deleting C:\Users\scase\Documents\ADSM Workspace\settings\activeSession.sqlite3 Operations to perform: Synchronize unmigrated apps: floppyforms, productionserver, crispy_forms Apply all migrations: admin, Results, auth, ADSMSettings, sessions, ScenarioCr eator, contenttypes Synchronizing apps without migrations: Creating tables... Installing custom SQL... Installing indexes... Running migrations: Applying ADSMSettings.0001_initial... OK Applying ADSMSettings.0002_simulationprocessrecord... OK Applying ADSMSettings.0003_smsession_simulation_has_started... OK Applying ScenarioCreator.0001_initial... OK Applying Results.0001_initial... OK Applying ScenarioCreator.0002_contact_ratehelp_text... OK Applying ScenarioCreator.0003_auto_20150126_1358... OK Applying ScenarioCreator.0004_auto_20150302_1619... OK Applying contenttypes.0001_initial... OK Applying auth.0001_initial... OK Applying admin.0001_initial... OK Applying sessions.0001_initial... OK Checking Scenario version Operations to perform: Synchronize unmigrated apps: floppyforms, productionserver, crispy_forms Apply all migrations: admin, Results, auth, ADSMSettings, sessions, ScenarioCr eator, contenttypes Synchronizing apps without migrations: Creating tables... Installing custom SQL... Installing indexes... Running migrations: No migrations to apply. Operations to perform: Synchronize unmigrated apps: floppyforms, productionserver, crispy_forms Apply all migrations: admin, Results, auth, ADSMSettings, sessions, ScenarioCr eator, contenttypes Synchronizing apps without migrations: Creating tables... Installing custom SQL... Installing indexes... Running migrations: No migrations to apply.

Done creating database

Issue: Several error and alert messages appear in the command window, which should not be there for a first run of the program:

1) [alert] could not open error log file: CreateFile() "logs/error.log" fail ed (3: The system cannot find the path specified): This message should not happen. If this is the first time this program is run, and it was, the program should create its needed files and directories, not tell the user that there is a problem.

2) [Errno 2] No such file or directory: 'C:\Users\scase\Documents\ADSM Workspac e\Sample Scenario with Outputs\population_map.png': Is this a missing file, or another issue like in number 1 above?

3) [Errno 2] No such file or directory: 'C:\Users\scase\Documents\ADSM Workspac e\Sample Scenario with Outputs\population_thumbnail.png': Is this a missing file or another issue like number 1 above?

Suggestions:
1) If the alert and error messages are indeed important, they should not be mixed with normal debugging chatter. They are easily lost this way. I would suggest turning off the normal debugging messages (they use unnecessary system resources anyway), and just show the alerts and errors.

2) If the program needs to have certain files in place before running, it should check for these during the first-time run, and create or install what it needs, not tell the user that something is wrong with their system.

casesp commented 9 years ago

Issues need to stay open until a code release can be verified as having addressed it.

casesp commented 9 years ago

Last tested in 3.3.0-RC2.4 (69fb5d6)

Will test again when it is ready.

BryanHurst commented 9 years ago

1) The nginx log file is now properly instantiated in the workspace folder.

2-3) Sample scenario files are all now properly copied and integrity checked at startup.

The production release branch now has the ability to hide debug messages.

BryanHurst commented 9 years ago

Each of the fixes listed above have their own issues in the testing queue. Closing.