Skip to content
This repository has been archived by the owner on Sep 28, 2022. It is now read-only.

Handle SWMM simulation error more smoothly #410

Open
barrc opened this issue Mar 11, 2020 · 1 comment
Open

Handle SWMM simulation error more smoothly #410

barrc opened this issue Mar 11, 2020 · 1 comment
Assignees

Comments

@barrc
Copy link
Contributor

barrc commented Mar 11, 2020

In the Delphi GUI, if you run a simulation that has errors, you get a popup that says:
"Run was unsuccessful. See Status Report for reasons." After you click OK, the status report opens.

In the new UI, if you run the same inp file, you get a popup that stays:
"Exception running simulation: Fatal error occured SWMM Error code 133 None". If you click OK, it launches the status report. Then you get another popup that says "Error opening model output: C:\Users\path\to\output\file.out File Error 435: invalid file - not created by SWMM None". We should handle an error more smoothly.

@barrc barrc self-assigned this Mar 18, 2020
@barrc
Copy link
Contributor Author

barrc commented Mar 18, 2020

I'm working on this ticket. The output API returns Error 435 if the magic numbers from the .out file do not match:

// Is this a valid SWMM binary output file?
if (magic1 != magic2) errorcode = 435;

It looks like the Closing Records section of the .out file is not being written in some cases, so magic2 is not equal to magic1. If I run SWMM from the command line, the second magic number is written.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant