Skip to content

Commit

Permalink
I. natcap#1797 moving restriction to GHA workflows
Browse files Browse the repository at this point in the history
  • Loading branch information
dcdenu4 committed Feb 28, 2025
1 parent 953e024 commit fc7cc86
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 8 deletions.
6 changes: 3 additions & 3 deletions .github/workflows/build-and-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ env:
# build: dependency of make install
# nomkl: make sure numpy w/out mkl
# setuptools_scm: needed for versioning to work
CONDA_DEFAULT_DEPENDENCIES: python-build nomkl setuptools_scm
CONDA_DEFAULT_DEPENDENCIES: python-build nomkl setuptools_scm sqlite<3.49.1 # https://github.com/natcap/invest/issues/1797
LATEST_SUPPORTED_PYTHON_VERSION: "3.13"

jobs:
Expand Down Expand Up @@ -94,7 +94,7 @@ jobs:
with:
python-version: ${{ matrix.python-version }}
requirements-files: requirements.txt requirements-dev.txt constraints_tests.txt
requirements: ${{ env.CONDA_DEFAULT_DEPENDENCIES }} sqlite<3.49.1 # https://github.com/natcap/invest/issues/1797
requirements: ${{ env.CONDA_DEFAULT_DEPENDENCIES }}

- name: Download previous conda environment.yml
continue-on-error: true
Expand Down Expand Up @@ -328,7 +328,7 @@ jobs:
requirements-dev.txt
requirements-docs.txt
constraints_tests.txt
requirements: ${{ env.CONDA_DEFAULT_DEPENDENCIES }} pandoc
requirements: ${{ env.CONDA_DEFAULT_DEPENDENCIES }} pandoc

- name: Make install
run: make install
Expand Down
6 changes: 1 addition & 5 deletions scripts/convert-requirements-to-conda-yml.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,10 +13,6 @@
{pip_dependencies}
"""

# For restricting conda-forge only packages
# https://github.com/conda-forge/sqlite-feedstock/issues/130
CONDA_DEPS = ['sqlite<3.49']


def build_environment_from_requirements(cli_args):
"""Build a conda environment.yml from requirements.txt files.
Expand Down Expand Up @@ -51,7 +47,7 @@ def build_environment_from_requirements(cli_args):
requirements_files = args.req

pip_requirements = set()
conda_requirements = set(CONDA_DEPS)
conda_requirements = set()
for requirement_file in requirements_files:
with open(requirement_file) as file:
for line in file:
Expand Down

0 comments on commit fc7cc86

Please sign in to comment.