Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add python 3.11 support #697

Merged
merged 8 commits into from
Dec 4, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
60 changes: 21 additions & 39 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,9 @@ references:
key: python-env-v1-{{ arch }}-{{ .Environment.CIRCLE_JOB }}-{{ checksum "setup.py" }}-{{ checksum "requirements/requirements-test.txt" }}-{{ checksum ".circleci/ci-oldest-reqs.txt" }}

jobs:
linux-python-310: &test-template
linux-python-311: &test-template
docker:
- image: cimg/python:3.10
- image: cimg/python:3.11

environment:
DEPENDENCIES: "NEWEST"
Expand Down Expand Up @@ -57,12 +57,16 @@ jobs:
path: test-reports
destination: test-reports

linux-python-310-signac-latest:
linux-python-311-signac-latest:
<<: *test-template
environment:
DEPENDENCIES: "NEWEST"
SIGNAC_VERSION: "git+ssh://git@github.com/glotzerlab/signac.git"
PYTHON: python
linux-python-310:
<<: *test-template
docker:
- image: cimg/python:3.10
linux-python-39:
<<: *test-template
docker:
Expand All @@ -80,9 +84,9 @@ jobs:
SIGNAC_VERSION: "signac==1.8.0"
PYTHON: python

test-install-pip-python-310: &test-install-pip
test-install-pip-python-311:
docker:
- image: cimg/python:3.10
- image: cimg/python:3.11

environment:
PYTHON: python
Expand All @@ -102,16 +106,6 @@ jobs:
${PYTHON} -m flow --version
${PYTHON} -c 'import flow'

test-install-pip-python-39:
<<: *test-install-pip
docker:
- image: cimg/python:3.9

test-install-pip-python-38:
<<: *test-install-pip
docker:
- image: cimg/python:3.8

test-install-conda: &test-install-conda
environment:
# The default job does not specify the version, just like the
Expand All @@ -131,27 +125,15 @@ jobs:
- run:
<<: *smoke-test

test-install-conda-python-310:
<<: *test-install-conda
environment:
PYTHON_DEP: "python=3.10"
PYTHON: python

test-install-conda-python-39:
<<: *test-install-conda
environment:
PYTHON_DEP: "python=3.9"
PYTHON: python

test-install-conda-python-38:
test-install-conda-python-311:
<<: *test-install-conda
environment:
PYTHON_DEP: "python=3.8"
PYTHON_DEP: "python=3.11"
PYTHON: python

check-metadata:
docker:
- image: cimg/python:3.10
- image: cimg/python:3.11

working_directory: ~/repo

Expand All @@ -170,7 +152,7 @@ jobs:

test-deploy-pypi:
docker:
- image: cimg/python:3.10
- image: cimg/python:3.11
working_directory: ~/repo
steps:
- checkout
Expand All @@ -181,7 +163,7 @@ jobs:

deploy-pypi:
docker:
- image: cimg/python:3.10
- image: cimg/python:3.11
working_directory: ~/repo
steps:
- checkout
Expand All @@ -195,6 +177,9 @@ workflows:
version: 2
test:
jobs:
- linux-python-311:
post-steps:
- codecov/upload
- linux-python-310:
post-steps:
- codecov/upload
Expand All @@ -216,6 +201,7 @@ workflows:
branches:
only: /release\/.*/
requires:
- linux-python-311
- linux-python-310
- linux-python-39
- linux-python-38
Expand All @@ -229,14 +215,10 @@ workflows:
only:
- master
jobs:
- linux-python-310-signac-latest
- test-install-pip-python-310
- test-install-pip-python-39
- test-install-pip-python-38
- linux-python-311-signac-latest
- test-install-pip-python-311
- test-install-conda
- test-install-conda-python-310
- test-install-conda-python-39
- test-install-conda-python-38
- test-install-conda-python-311
deploy:
jobs:
- deploy-pypi:
Expand Down
4 changes: 4 additions & 0 deletions flow/scheduling/base.py
Original file line number Diff line number Diff line change
Expand Up @@ -101,6 +101,10 @@ def _to_group(cls, status):
except KeyError:
raise ValueError(f"No equivalent group status for {status}.")

def __str__(self):
"""Get the status name as a string."""
return self.name


class ClusterJob:
"""Class representing a cluster job."""
Expand Down
1 change: 1 addition & 0 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,7 @@
"Programming Language :: Python :: 3.8",
"Programming Language :: Python :: 3.9",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.11",
],
entry_points={
"console_scripts": [
Expand Down