From 054cf5f95523fb4f0492057f598cf8f23a368c93 Mon Sep 17 00:00:00 2001 From: Xylar Asay-Davis Date: Thu, 2 Feb 2023 16:45:45 -0700 Subject: [PATCH] Make `setup.py` consistent with conda recipe (#250) * Bump `isort` version to fix poetry error * Update GH Actions actions versions * Make `conda/meta.yaml` and `setup.py` consistent Inconsistencies in `setup.py` are causing `pip check` to fail on the conda package. --- .github/workflows/build_workflow.yml | 16 ++++++++-------- .github/workflows/release_workflow.yml | 10 +++++----- .pre-commit-config.yaml | 4 ++-- conda/meta.yaml | 4 ++-- setup.py | 7 ++++--- 5 files changed, 21 insertions(+), 20 deletions(-) diff --git a/.github/workflows/build_workflow.yml b/.github/workflows/build_workflow.yml index e65d7840..46c59805 100644 --- a/.github/workflows/build_workflow.yml +++ b/.github/workflows/build_workflow.yml @@ -13,10 +13,10 @@ jobs: timeout-minutes: 2 steps: - name: Checkout Code Repository - uses: actions/checkout@v2 + uses: actions/checkout@v3 - name: Set up Python 3.9 - uses: actions/setup-python@v2 + uses: actions/setup-python@v4 with: python-version: 3.9 @@ -24,7 +24,7 @@ jobs: # Getting only staged files can be tricky in case a new PR is opened # since the action is run on a branch in detached head state - name: Install and Run Pre-commit - uses: pre-commit/action@v2.0.0 + uses: pre-commit/action@v3.0.0 build: runs-on: ubuntu-latest @@ -33,10 +33,10 @@ jobs: shell: bash -l {0} timeout-minutes: 20 steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v3 - name: Set up Python - uses: actions/setup-python@v2 + uses: actions/setup-python@v4 with: python-version: 3.9 @@ -58,18 +58,18 @@ jobs: shell: bash -l {0} timeout-minutes: 5 steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v3 with: persist-credentials: false fetch-depth: 0 - name: Set up Python - uses: actions/setup-python@v2 + uses: actions/setup-python@v4 with: python-version: 3.9 - name: Cache pip - uses: actions/cache@v2 + uses: actions/cache@v3 with: # This path is specific to Ubuntu path: ~/.cache/pip diff --git a/.github/workflows/release_workflow.yml b/.github/workflows/release_workflow.yml index eed1409a..caa97694 100644 --- a/.github/workflows/release_workflow.yml +++ b/.github/workflows/release_workflow.yml @@ -12,18 +12,18 @@ jobs: shell: bash -l {0} timeout-minutes: 5 steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v3 with: persist-credentials: false fetch-depth: 0 - name: Set up Python - uses: actions/setup-python@v2 + uses: actions/setup-python@v4 with: python-version: 3.9 - name: Cache pip - uses: actions/cache@v2 + uses: actions/cache@v3 with: # This path is specific to Ubuntu path: ~/.cache/pip @@ -86,10 +86,10 @@ jobs: run: shell: bash -l {0} steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v3 - name: Cache Conda - uses: actions/cache@v2 + uses: actions/cache@v3 env: # Increase this value to reset cache if conda/zstash_dev.yml has not changed in the workflow CACHE_NUMBER: 0 diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 9eff9939..e3f1c022 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -16,8 +16,8 @@ repos: hooks: - id: black - - repo: https://github.com/timothycrosley/isort - rev: 5.7.0 + - repo: https://github.com/PyCQA/isort + rev: 5.12.0 hooks: - id: isort diff --git a/conda/meta.yaml b/conda/meta.yaml index a0dc3b05..358f0d47 100644 --- a/conda/meta.yaml +++ b/conda/meta.yaml @@ -21,9 +21,9 @@ requirements: run: - python >=3.6 + - fair-research-login >=0.2.6,<0.3.0 + - globus-sdk >=3.0.0,<4.0.0 - six - - globus-sdk >=2 - - fair-research-login test: imports: diff --git a/setup.py b/setup.py index 0b945411..00e4c539 100644 --- a/setup.py +++ b/setup.py @@ -7,10 +7,11 @@ author_email="forsyth2@llnl.gov, golaz1@llnl.gov, shaheen2@llnl.gov", description="Long term HPSS archiving software for E3SM", packages=find_packages(include=["zstash", "zstash.*"]), + python_requires=">=3.6", install_requires=[ - "six==1.16.0", - "globus-sdk<4.0.0>=3.0.0", - "fair-research-login==0.2.6", + "fair-research-login>=0.2.6,<0.3.0", + "globus-sdk>=3.0.0,<4.0.0", + "six", ], entry_points={"console_scripts": ["zstash=zstash.main:main"]}, )