From 03738adea084faaadf2ce06afe57869a544ce83e Mon Sep 17 00:00:00 2001 From: Chen Zhang Date: Tue, 2 Jan 2024 09:57:45 -0500 Subject: [PATCH 1/9] update pyoncat source to conda --- conda_environment.yml | 43 ++++++++++++++++++++++--------------------- 1 file changed, 22 insertions(+), 21 deletions(-) diff --git a/conda_environment.yml b/conda_environment.yml index 95a314ff..58541cf6 100644 --- a/conda_environment.yml +++ b/conda_environment.yml @@ -1,24 +1,25 @@ name: webmon channels: -- conda-forge + - conda-forge + - oncat dependencies: -- python=3.10 -- django=3.2 -- gunicorn -- httplib2 -- make -- oauthlib -- postgresql=14 -- psycopg2-binary=2.9.3 -- psutil -- python-ldap>=3.1 -- requests-oauthlib -- setuptools -- stomp.py=8 -- urllib3 -- versioningit~=1.1 -- pip -- pip: - - django-auth-ldap==4.1.0 - - django-health-check - - https://oncat.ornl.gov/packages/pyoncat-1.4.1-py3-none-any.whl + - python=3.10 + - django=3.2 + - gunicorn + - httplib2 + - make + - oauthlib + - postgresql=14 + - psycopg2-binary=2.9.3 + - psutil + - python-ldap>=3.1 + - requests-oauthlib + - setuptools + - stomp.py=8 + - urllib3 + - versioningit~=1.1 + - pyoncat + - pip + - pip: + - django-auth-ldap==4.1.0 + - django-health-check From 8d6240ba5d57594aeb13542e0343541b703d4a0a Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Tue, 2 Jan 2024 15:00:10 +0000 Subject: [PATCH 2/9] [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci --- conda_environment.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/conda_environment.yml b/conda_environment.yml index 58541cf6..0b3d6d49 100644 --- a/conda_environment.yml +++ b/conda_environment.yml @@ -1,7 +1,7 @@ name: webmon channels: - conda-forge - - oncat + - oncat dependencies: - python=3.10 - django=3.2 From f6e233e4610e154347af0db1df7aa4b70f80bad0 Mon Sep 17 00:00:00 2001 From: Chen Zhang Date: Tue, 2 Jan 2024 10:10:55 -0500 Subject: [PATCH 3/9] remove the version pin for pytest --- conda_development.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/conda_development.yml b/conda_development.yml index ffedb599..7bce78b5 100644 --- a/conda_development.yml +++ b/conda_development.yml @@ -3,7 +3,7 @@ channels: dependencies: - build - flake8 -- pytest<7 +- pytest - pytest-django - pytest-cov - python-dotenv From 839b4fe562d02ca4204f507b18740a311d70343f Mon Sep 17 00:00:00 2001 From: Chen Zhang Date: Tue, 2 Jan 2024 10:25:59 -0500 Subject: [PATCH 4/9] use pip to install pytest and plugins --- conda_development.yml | 32 ++++++++++++++++---------------- 1 file changed, 16 insertions(+), 16 deletions(-) diff --git a/conda_development.yml b/conda_development.yml index 7bce78b5..551341bf 100644 --- a/conda_development.yml +++ b/conda_development.yml @@ -1,18 +1,18 @@ channels: -- conda-forge + - conda-forge dependencies: -- build -- flake8 -- pytest -- pytest-django -- pytest-cov -- python-dotenv -- python-build -- pre-commit -- sphinx -- sphinx_rtd_theme=1.2.* -- lxml -- pip -- pip: - - check-wheel-contents - - pytest-pythonpath + - build + - flake8 + - python-dotenv + - python-build + - pre-commit + - sphinx + - sphinx_rtd_theme=1.2.* + - lxml + - pip + - pip: + - pytest + - pytest-django + - pytest-cov + - check-wheel-contents + - pytest-pythonpath From f819c4a8b0e39c6ebb29fc1d5527066c2311f208 Mon Sep 17 00:00:00 2001 From: Chen Zhang Date: Tue, 2 Jan 2024 10:47:34 -0500 Subject: [PATCH 5/9] force to use old version of pytest and plugin --- conda_development.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/conda_development.yml b/conda_development.yml index 551341bf..c2aabe2f 100644 --- a/conda_development.yml +++ b/conda_development.yml @@ -5,14 +5,14 @@ dependencies: - flake8 - python-dotenv - python-build + - pytest<7 + - pytest-django<4.6 + - pytest-cov - pre-commit - sphinx - sphinx_rtd_theme=1.2.* - lxml - pip - pip: - - pytest - - pytest-django - - pytest-cov - check-wheel-contents - pytest-pythonpath From f9aa987dbf4547b0ecffba1981dce7354ac89c8f Mon Sep 17 00:00:00 2001 From: Chen Zhang Date: Tue, 2 Jan 2024 10:55:00 -0500 Subject: [PATCH 6/9] add missing theme --- conda_environment.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/conda_environment.yml b/conda_environment.yml index 0b3d6d49..790ca87f 100644 --- a/conda_environment.yml +++ b/conda_environment.yml @@ -19,6 +19,7 @@ dependencies: - urllib3 - versioningit~=1.1 - pyoncat + - sphinx_rtd_theme=1.2.* # readthedocs use this env file, and we need to install this theme here - pip - pip: - django-auth-ldap==4.1.0 From 6c6078f3020422ef9f309cd07c186fd712d14aaf Mon Sep 17 00:00:00 2001 From: Chen Zhang Date: Tue, 2 Jan 2024 11:25:03 -0500 Subject: [PATCH 7/9] try older version of django --- conda_environment.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/conda_environment.yml b/conda_environment.yml index 790ca87f..48c64642 100644 --- a/conda_environment.yml +++ b/conda_environment.yml @@ -4,7 +4,7 @@ channels: - oncat dependencies: - python=3.10 - - django=3.2 + - django<3.2 - gunicorn - httplib2 - make From ba798ce8c44405fdda02eafb59d11dca8af57f85 Mon Sep 17 00:00:00 2001 From: Chen Zhang Date: Tue, 2 Jan 2024 11:38:09 -0500 Subject: [PATCH 8/9] revert changes --- conda_environment.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/conda_environment.yml b/conda_environment.yml index 48c64642..790ca87f 100644 --- a/conda_environment.yml +++ b/conda_environment.yml @@ -4,7 +4,7 @@ channels: - oncat dependencies: - python=3.10 - - django<3.2 + - django=3.2 - gunicorn - httplib2 - make From 87352d4248773d7b98c584bd57c6262ed977e2c3 Mon Sep 17 00:00:00 2001 From: Chen Zhang Date: Wed, 3 Jan 2024 09:21:48 -0500 Subject: [PATCH 9/9] pin the post processing agent to older version --- Dockerfile.autoreducer | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Dockerfile.autoreducer b/Dockerfile.autoreducer index bcdf3c2d..35b191a4 100644 --- a/Dockerfile.autoreducer +++ b/Dockerfile.autoreducer @@ -13,7 +13,7 @@ RUN useradd snsdata -G snswheel # put the developer configuration file in place RUN mkdir -p /etc/autoreduce/ RUN mkdir -p /opt/postprocessing/log/ -RUN curl https://raw.githubusercontent.com/neutrons/post_processing_agent/main/configuration/post_process_consumer.conf.development -o /etc/autoreduce/post_processing.conf +RUN curl https://raw.githubusercontent.com/neutrons/post_processing_agent/v2.7/configuration/post_process_consumer.conf.development -o /etc/autoreduce/post_processing.conf RUN yum install -y jq RUN contents="$(jq '.amq_queues[.amq_queues| length] |= . + "/queue/REDUCTION.CREATE_SCRIPT"' /etc/autoreduce/post_processing.conf)" && \