From 9f7e424a06a21562f04a81d51dca32569b368101 Mon Sep 17 00:00:00 2001 From: everett Date: Mon, 30 Oct 2023 15:03:32 -0700 Subject: [PATCH] Minor changes to rpt warnings function --- swmmio/core.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/swmmio/core.py b/swmmio/core.py index e27cb62..f0f8aa0 100644 --- a/swmmio/core.py +++ b/swmmio/core.py @@ -179,7 +179,7 @@ def rpt_warnings(self, verbose=False): """ # first, make sure the rpt is valid if self.rpt_is_valid(verbose=verbose): - # check if the rpt has ERRORS output from SWMM + # check if the rpt has WARNINGS output from SWMM warnings = list() with open(self.rpt.path) as f: for line in f: @@ -188,7 +188,9 @@ def rpt_warnings(self, verbose=False): warnings.append(line[:-1]) elif '****************' in line: break - return warnings + else: + warnings = 'RPT file is not valid' + return warnings def conduits(self):