From 57b6672e5c6c2c8f32a928e300708f0b588120a7 Mon Sep 17 00:00:00 2001 From: Paul Haesler Date: Tue, 24 Oct 2023 10:43:14 +1100 Subject: [PATCH 1/6] Manually apply pre-commit hook updates. --- .pre-commit-config.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 4a5448b6..09964f5d 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -1,6 +1,6 @@ repos: - repo: https://github.com/pre-commit/pre-commit-hooks - rev: v4.4.0 + rev: v4.5.0 hooks: - id: check-yaml - id: end-of-file-fixer @@ -19,7 +19,7 @@ repos: # hooks: # - id: bandit - repo: https://github.com/PyCQA/pylint - rev: v3.0.0a7 + rev: v3.0.1 hooks: - id: pylint args: ["--disable=C,R,W,E1136"] From 7c508d19759114c313d305ce99efd85203bda76e Mon Sep 17 00:00:00 2001 From: Paul Haesler Date: Tue, 24 Oct 2023 10:48:32 +1100 Subject: [PATCH 2/6] treat "n", "no", "f" and "false" in $PYDEV_DEBUG as explicit "No debugging". --- datacube_ows/startup_utils.py | 9 +++++---- docs/environment_variables.rst | 2 +- tests/test_startup.py | 6 ++++++ 3 files changed, 12 insertions(+), 5 deletions(-) diff --git a/datacube_ows/startup_utils.py b/datacube_ows/startup_utils.py index 3331baf6..b9e9673e 100644 --- a/datacube_ows/startup_utils.py +++ b/datacube_ows/startup_utils.py @@ -50,10 +50,11 @@ def initialise_ignorable_warnings(): def initialise_debugging(log=None): # PYCHARM Debugging if os.environ.get("PYDEV_DEBUG"): - import pydevd_pycharm - pydevd_pycharm.settrace('172.17.0.1', port=12321, stdoutToServer=True, stderrToServer=True) - if log: - log.info("PyCharm Debugging enabled") + if os.environ["PYDEV_DEBUG"].lower() not in ("no", "false", "f", "n"): + import pydevd_pycharm + pydevd_pycharm.settrace('172.17.0.1', port=12321, stdoutToServer=True, stderrToServer=True) + if log: + log.info("PyCharm Debugging enabled") def before_send(event, hint): if 'exc_info' in hint: diff --git a/docs/environment_variables.rst b/docs/environment_variables.rst index a7b28b50..eaf51925 100644 --- a/docs/environment_variables.rst +++ b/docs/environment_variables.rst @@ -103,7 +103,7 @@ Dev Tools --------- PYDEV_DEBUG: - If set, activates PyDev remote debugging. + If set to anything other than "n", "f", "no" or "false" (case insensitive), activates PyDev remote debugging. DEFER_CFG_PARSE: If set, the configuration file is not read and parsed at startup. This diff --git a/tests/test_startup.py b/tests/test_startup.py index ea66134b..77c08c74 100644 --- a/tests/test_startup.py +++ b/tests/test_startup.py @@ -82,6 +82,12 @@ def test_initialise_nodebugging(monkeypatch): initialise_debugging() +def test_initialise_explicit_nodebugging(monkeypatch): + monkeypatch.setenv("PYDEV_DEBUG", "no") + from datacube_ows.startup_utils import initialise_debugging + initialise_debugging() + + def test_initialise_debugging(monkeypatch): monkeypatch.setenv("PYDEV_DEBUG", "YES") from datacube_ows.startup_utils import initialise_debugging From 55f5b8084fa9019dc4e4a90e6449a1b059fc5186 Mon Sep 17 00:00:00 2001 From: Paul Haesler Date: Tue, 24 Oct 2023 10:56:32 +1100 Subject: [PATCH 3/6] Add Emma's GH username to wordlist. --- wordlist.txt | 1 + 1 file changed, 1 insertion(+) diff --git a/wordlist.txt b/wordlist.txt index ba4d36e4..5493e3d5 100644 --- a/wordlist.txt +++ b/wordlist.txt @@ -138,6 +138,7 @@ ee ef efd eg +emmaai english entrypoint enum From a3565a33e4bf4ab3cb812bb2779c3f6312fe25b4 Mon Sep 17 00:00:00 2001 From: Paul Haesler Date: Tue, 24 Oct 2023 11:04:53 +1100 Subject: [PATCH 4/6] Correct spelling --- HISTORY.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/HISTORY.rst b/HISTORY.rst index 85681c9c..7169542a 100644 --- a/HISTORY.rst +++ b/HISTORY.rst @@ -12,7 +12,7 @@ Datacube-ows version 1.8.x indicates that it is designed work with datacube-core Maintenance release. -* Changes to depenency version pins (#983, #942, #948, #949) +* Changes to dependency version pins (#983, #942, #948, #949) Includes contributions from @pindge, @emmaai and @SpacemanPaul. From 5c5a6b58ca22d7a44a9faef5498159175859842d Mon Sep 17 00:00:00 2001 From: Paul Haesler Date: Tue, 24 Oct 2023 10:59:09 +1100 Subject: [PATCH 5/6] Update HISTORY.rst and increment default version number for 1.8.36 release. --- HISTORY.rst | 7 +++++++ datacube_ows/__init__.py | 2 +- 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/HISTORY.rst b/HISTORY.rst index 7169542a..2b63d1d5 100644 --- a/HISTORY.rst +++ b/HISTORY.rst @@ -7,6 +7,13 @@ History Datacube-ows version 1.8.x indicates that it is designed work with datacube-core versions 1.8.x. +1.8.36 (2023-10-24) +------------------- + +* Fix Docker image and CI pipeline (#954) +* Make PYDEV_DEBUG behaviour less counter-intuitive (#955) +* Update HISTORY.rst and increment default version for release (#956??) + 1.8.35 (2023-09-01) ------------------- diff --git a/datacube_ows/__init__.py b/datacube_ows/__init__.py index 6b08afaf..d4d3d1fe 100644 --- a/datacube_ows/__init__.py +++ b/datacube_ows/__init__.py @@ -6,4 +6,4 @@ try: from ._version import version as __version__ except ImportError: - __version__ = "1.8.35+?" + __version__ = "1.8.36+?" From d74e498b27920c42e997c1a6dbf8cac42d270083 Mon Sep 17 00:00:00 2001 From: Paul Haesler Date: Tue, 24 Oct 2023 11:43:44 +1100 Subject: [PATCH 6/6] Rebase with #955 --- HISTORY.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/HISTORY.rst b/HISTORY.rst index 2b63d1d5..39aefdab 100644 --- a/HISTORY.rst +++ b/HISTORY.rst @@ -12,7 +12,7 @@ Datacube-ows version 1.8.x indicates that it is designed work with datacube-core * Fix Docker image and CI pipeline (#954) * Make PYDEV_DEBUG behaviour less counter-intuitive (#955) -* Update HISTORY.rst and increment default version for release (#956??) +* Update HISTORY.rst and increment default version for release (#956) 1.8.35 (2023-09-01) -------------------