From def68ed59dcc050510b4b30d093b768b665a5be1 Mon Sep 17 00:00:00 2001 From: bikegeek Date: Thu, 2 Nov 2023 14:17:56 -0600 Subject: [PATCH 1/4] Issue #401 replaced line_logger with logger in line 698 --- metplotpy/plots/line/line.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/metplotpy/plots/line/line.py b/metplotpy/plots/line/line.py index 54ac8b9a..7aa1d831 100644 --- a/metplotpy/plots/line/line.py +++ b/metplotpy/plots/line/line.py @@ -695,7 +695,7 @@ def write_html(self) -> None: # save html self.figure.write_html(html_name, include_plotlyjs=False) - self.line_logger.info(f"Finished writing to html file: {datetime.now()}") + logger.info(f"Finished writing to html file: {datetime.now()}") def write_output_file(self) -> None: """ From 7313a84dca8c449a9cf4b7b6e4673ec88e385d13 Mon Sep 17 00:00:00 2001 From: bikegeek Date: Thu, 2 Nov 2023 15:51:48 -0600 Subject: [PATCH 2/4] issue #401 don't remove the nan.points1 plot as cleanup --- test/line/test_line_plot.py | 1 - 1 file changed, 1 deletion(-) diff --git a/test/line/test_line_plot.py b/test/line/test_line_plot.py index 9f2d976f..6448a588 100644 --- a/test/line/test_line_plot.py +++ b/test/line/test_line_plot.py @@ -140,7 +140,6 @@ def test_no_nans_in_points_files(): os.remove(os.path.join(path, plot_file)) os.remove(os.path.join(intermed_path, points_file_1)) os.remove(os.path.join(intermed_path, points_file_2)) - os.remove("./intermed_files/nan.points1") except OSError as e: # Typically when files have already been removed or # don't exist. Ignore. From b95be64c2a3dca5107ac5274b1230cd420cb8765 Mon Sep 17 00:00:00 2001 From: bikegeek Date: Fri, 3 Nov 2023 09:00:43 -0600 Subject: [PATCH 3/4] Issue #401 move this file from the intermediate files directory. It doesn't belong there since it is not created during a test and is a file that is supposed to persist --- test/line/nan.points1 | 3 +++ 1 file changed, 3 insertions(+) create mode 100644 test/line/nan.points1 diff --git a/test/line/nan.points1 b/test/line/nan.points1 new file mode 100644 index 00000000..444d5e5b --- /dev/null +++ b/test/line/nan.points1 @@ -0,0 +1,3 @@ +NaN NaN NaN NaN 14.182521 14.703459 0.216470 0.121860 0.311080 +14.615340 14.336420 14.894260 14.645345 14.338789 14.951901 0.022085 -0.056724 0.100894 +14.858610 NaN 15.168714 14.981590 14.720549 15.242631 -0.076490 -0.170358 0.017378 From fb4e157d7dd4955a52f5a8d46c39d7529ac54f9e Mon Sep 17 00:00:00 2001 From: bikegeek Date: Fri, 3 Nov 2023 09:01:22 -0600 Subject: [PATCH 4/4] issue #401 refer to the nan.points1 in a new directory --- test/line/test_line_plot.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/line/test_line_plot.py b/test/line/test_line_plot.py index 6448a588..203de672 100644 --- a/test/line/test_line_plot.py +++ b/test/line/test_line_plot.py @@ -122,7 +122,7 @@ def test_no_nans_in_points_files(): assert nans_found == False # Verify that the nan.points1 file does indeed trigger a "nans_found" - with open("./intermed_files/nan.points1", "r") as f: + with open("./nan.points1", "r") as f: data = f.read() if "NaN" in data: nans_found = True