Skip to content

Commit

Permalink
Small modernizations
Browse files Browse the repository at this point in the history
- Bump python versions for tests and requirements.
- Fix use of dtype np.int_ in tests.
- Use concurrency in github actions rather than
  cancel-workflow action.
  • Loading branch information
tskisner committed Jan 30, 2024
1 parent 4d05453 commit d88cc51
Show file tree
Hide file tree
Showing 4 changed files with 16 additions and 23 deletions.
13 changes: 6 additions & 7 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,10 @@ on:
# pull_request:
# branches: [ master ]

concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true

env:
TWINE_USERNAME: __token__
TWINE_PASSWORD: ${{ secrets.TWINE_TOKEN }}
Expand All @@ -22,18 +26,13 @@ jobs:
wheels:
runs-on: ubuntu-latest
steps:
- name: Cancel Previous Runs
uses: styfle/[email protected]
with:
access_token: ${{ github.token }}

- name: Checkout
uses: actions/checkout@v4

- name: Set up Python 3.9
- name: Set up Python 3.10
uses: actions/setup-python@v5
with:
python-version: 3.9
python-version: 3.10

- name: Install Dependencies
run: ./test_scripts/install_deps_github_ubuntu.sh && pip install twine
Expand Down
18 changes: 6 additions & 12 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,18 +8,17 @@ on:
pull_request:
branches: [ master ]

concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true

jobs:
linux:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.7", "3.9", "3.10"]
python-version: ["3.8", "3.10", "3.11", "3.12"]
steps:
- name: Cancel Previous Runs
uses: styfle/[email protected]
with:
access_token: ${{ github.token }}

- name: Checkout
uses: actions/checkout@v4

Expand Down Expand Up @@ -47,13 +46,8 @@ jobs:
runs-on: macos-latest
strategy:
matrix:
python-version: ["3.7", "3.9", "3.10"]
python-version: ["3.10", "3.11", "3.12"]
steps:
- name: Cancel Previous Runs
uses: styfle/[email protected]
with:
access_token: ${{ github.token }}

- name: Checkout
uses: actions/checkout@v4

Expand Down
2 changes: 1 addition & 1 deletion pshmem/test.py
Original file line number Diff line number Diff line change
Expand Up @@ -353,7 +353,7 @@ def test_shape(self):
(2, 5, 10),
np.array([10, 2], dtype=np.int32),
np.array([5, 2], dtype=np.int64),
np.array([10, 2], dtype=np.int),
np.array([10, 2], dtype=np.int_),
]
bad_dims = [
(-1,),
Expand Down
6 changes: 3 additions & 3 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ def readme():
packages=["pshmem"],
scripts=None,
license="BSD",
python_requires=">=3.6.0",
python_requires=">=3.8.0",
install_requires=["numpy", "posix_ipc"],
extras_require={"mpi": ["mpi4py>=3.0"]},
cmdclass=versioneer.get_cmdclass(),
Expand All @@ -34,11 +34,11 @@ def readme():
"Intended Audience :: Science/Research",
"License :: OSI Approved :: BSD License",
"Operating System :: POSIX",
"Programming Language :: Python :: 3.6",
"Programming Language :: Python :: 3.7",
"Programming Language :: Python :: 3.8",
"Programming Language :: Python :: 3.9",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.11",
"Programming Language :: Python :: 3.12",
"Topic :: Utilities",
],
)

0 comments on commit d88cc51

Please sign in to comment.