From fab6301fbbfebcfa63e361755d2a4682b3a7d58a Mon Sep 17 00:00:00 2001 From: Adrienne Stilp Date: Wed, 22 May 2024 11:05:38 -0700 Subject: [PATCH 1/7] Change python version in future CI to 3.12 This broke last time in pip-sync, but I think we have a fix. --- .github/workflows/ci.yml | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index f0d7d38a..5576381e 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -28,12 +28,11 @@ jobs: backend: ["sqlite", "mariadb"] mariadb-version: ["10.4"] include: - # Not sure yet how best to include CI for a newer python version with the pip-tools workflow. - - python-version: 3.11 # Possible future version. + - python-version: 3.12 # Possible future version. backend: "mariadb" mariadb-version: "10.5" pip-recompile: true - - python-version: 3.11 # Possible future version. + - python-version: 3.12 # Possible future version. backend: "mariadb" mariadb-version: "10.11" pip-recompile: true From 319d453d45bdff676f80ff86a3a7bbc43ebc6a8b Mon Sep 17 00:00:00 2001 From: Adrienne Stilp Date: Wed, 22 May 2024 12:04:09 -0700 Subject: [PATCH 2/7] Install a temporary version of ACM to get python3.12 building This commit specifies a different version of numpy for python3.12. --- requirements/requirements.in | 2 +- requirements/requirements.txt | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/requirements/requirements.in b/requirements/requirements.in index b977ac59..cc561375 100644 --- a/requirements/requirements.in +++ b/requirements/requirements.in @@ -33,7 +33,7 @@ django-dbbackup # https://github.com/jazzband/django-dbbackup django-extensions # https://github.com/django-extensions/django-extensions # anvil_consortium_manager -django-anvil-consortium-manager @ git+https://github.com/UW-GAC/django-anvil-consortium-manager.git@v0.22 +django-anvil-consortium-manager @ git+https://github.com/UW-GAC/django-anvil-consortium-manager.git@a6f69539a5f01b45d68ee8a44b275d38b97ea8ae # Simple history - model history tracking django-simple-history diff --git a/requirements/requirements.txt b/requirements/requirements.txt index 08be852e..9171ed3d 100644 --- a/requirements/requirements.txt +++ b/requirements/requirements.txt @@ -62,7 +62,7 @@ django==4.2.13 # django-tables2 django-allauth==0.54.0 # via -r requirements/requirements.in -django-anvil-consortium-manager @ git+https://github.com/UW-GAC/django-anvil-consortium-manager.git@v0.22 +django-anvil-consortium-manager @ git+https://github.com/UW-GAC/django-anvil-consortium-manager.git@va6f69539a5f01b45d68ee8a44b275d38b97ea8ae # via -r requirements/requirements.in django-autocomplete-light==3.11.0 # via django-anvil-consortium-manager From e2cbd303ce55dab19c395b60768b4af7d2f29830 Mon Sep 17 00:00:00 2001 From: Adrienne Stilp Date: Wed, 22 May 2024 12:07:53 -0700 Subject: [PATCH 3/7] Fix commit SHA in requirements file I had an extra v at the beginning. --- requirements/requirements.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/requirements/requirements.txt b/requirements/requirements.txt index 9171ed3d..f3ce202e 100644 --- a/requirements/requirements.txt +++ b/requirements/requirements.txt @@ -62,7 +62,7 @@ django==4.2.13 # django-tables2 django-allauth==0.54.0 # via -r requirements/requirements.in -django-anvil-consortium-manager @ git+https://github.com/UW-GAC/django-anvil-consortium-manager.git@va6f69539a5f01b45d68ee8a44b275d38b97ea8ae +django-anvil-consortium-manager @ git+https://github.com/UW-GAC/django-anvil-consortium-manager.git@a6f69539a5f01b45d68ee8a44b275d38b97ea8ae # via -r requirements/requirements.in django-autocomplete-light==3.11.0 # via django-anvil-consortium-manager From 7474a01cd4d6ff373210a06def6185ddd647f5e0 Mon Sep 17 00:00:00 2001 From: Adrienne Stilp Date: Wed, 22 May 2024 12:56:48 -0700 Subject: [PATCH 4/7] Ignore deprecation warning from pkg_resources This is an warning that we can't do anything about. It's being used by django-environ, which is currently pinned to an older version until they fix the bug with hash signs in secret keys. --- pytest.ini | 1 + 1 file changed, 1 insertion(+) diff --git a/pytest.ini b/pytest.ini index 3dd36109..671ce45e 100644 --- a/pytest.ini +++ b/pytest.ini @@ -8,3 +8,4 @@ filterwarnings = ignore:pkg_resources is deprecated as an API.:DeprecationWarning:model_utils # Warning raised by pkg_resources via model_utils. ?? ignore:Deprecated call to `pkg_resources.declare_namespace:DeprecationWarning:pkg_resources + ignore:'pkgutil.find_loader' is deprecated and slated for removal in Python 3.14:DeprecationWarning:pkg_resources From afa46cee3154c0513d6d39991f241fc04d2dd276 Mon Sep 17 00:00:00 2001 From: Adrienne Stilp Date: Wed, 22 May 2024 13:19:32 -0700 Subject: [PATCH 5/7] Try fixing new ignore statement for pkgutil deprecation warning --- pytest.ini | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pytest.ini b/pytest.ini index 671ce45e..86a71d26 100644 --- a/pytest.ini +++ b/pytest.ini @@ -8,4 +8,4 @@ filterwarnings = ignore:pkg_resources is deprecated as an API.:DeprecationWarning:model_utils # Warning raised by pkg_resources via model_utils. ?? ignore:Deprecated call to `pkg_resources.declare_namespace:DeprecationWarning:pkg_resources - ignore:'pkgutil.find_loader' is deprecated and slated for removal in Python 3.14:DeprecationWarning:pkg_resources + ignore:'pkgutil.find_loader' is deprecated and slated for removal in Python 3.14:DeprecationWarning From 3cfbeeb910b6ca9922c971fea1a07ba226be8b8a Mon Sep 17 00:00:00 2001 From: Adrienne Stilp Date: Wed, 22 May 2024 13:57:38 -0700 Subject: [PATCH 6/7] Resolve deprecation warning with datetime.utcnow --- primed/drupal_oauth_provider/tests.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/primed/drupal_oauth_provider/tests.py b/primed/drupal_oauth_provider/tests.py index 2145bca2..5ccfffbc 100644 --- a/primed/drupal_oauth_provider/tests.py +++ b/primed/drupal_oauth_provider/tests.py @@ -104,7 +104,7 @@ def get_mocked_response(self): # This login response mimics drupals in that it contains a set of scopes # and the uid which has the name sub def get_login_response_json(self, with_refresh_token=True): - now = datetime.datetime.utcnow() + now = datetime.datetime.now(datetime.timezone.utc) app = get_adapter().get_app(request=None, provider=self.provider_id) allowed_audience = app.client_id id_token = sign_id_token( From a3a865c658bb7ef25e4816df97a3c3d7ab2f2125 Mon Sep 17 00:00:00 2001 From: Adrienne Stilp Date: Wed, 22 May 2024 15:20:14 -0700 Subject: [PATCH 7/7] Update to new ACM version in requirements This version specifies the correct numpy version to install based on the python version being used. --- requirements/requirements.in | 2 +- requirements/requirements.txt | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/requirements/requirements.in b/requirements/requirements.in index cc561375..e7f70630 100644 --- a/requirements/requirements.in +++ b/requirements/requirements.in @@ -33,7 +33,7 @@ django-dbbackup # https://github.com/jazzband/django-dbbackup django-extensions # https://github.com/django-extensions/django-extensions # anvil_consortium_manager -django-anvil-consortium-manager @ git+https://github.com/UW-GAC/django-anvil-consortium-manager.git@a6f69539a5f01b45d68ee8a44b275d38b97ea8ae +django-anvil-consortium-manager @ git+https://github.com/UW-GAC/django-anvil-consortium-manager.git@v0.22.1 # Simple history - model history tracking django-simple-history diff --git a/requirements/requirements.txt b/requirements/requirements.txt index f3ce202e..ea9ced12 100644 --- a/requirements/requirements.txt +++ b/requirements/requirements.txt @@ -62,7 +62,7 @@ django==4.2.13 # django-tables2 django-allauth==0.54.0 # via -r requirements/requirements.in -django-anvil-consortium-manager @ git+https://github.com/UW-GAC/django-anvil-consortium-manager.git@a6f69539a5f01b45d68ee8a44b275d38b97ea8ae +django-anvil-consortium-manager @ git+https://github.com/UW-GAC/django-anvil-consortium-manager.git@v0.22.1 # via -r requirements/requirements.in django-autocomplete-light==3.11.0 # via django-anvil-consortium-manager