... | ... |
@@ -1,9 +1,9 @@ |
1 | 1 |
repos: |
2 | 2 |
- repo: https://github.com/ambv/black |
3 |
- rev: 19.3b0 |
|
3 |
+ rev: 23.10.0 |
|
4 | 4 |
hooks: |
5 | 5 |
- id: black |
6 |
- language_version: python3.8 |
|
6 |
+ language_version: python3.11 |
|
7 | 7 |
- repo: https://github.com/pre-commit/pre-commit-hooks |
8 | 8 |
rev: v2.1.0 |
9 | 9 |
hooks: |
... | ... |
@@ -11,7 +11,12 @@ repos: |
11 | 11 |
exclude: '.bumpversion.cfg' |
12 | 12 |
- id: trailing-whitespace |
13 | 13 |
exclude: '.bumpversion.cfg' |
14 |
-- repo: https://gitlab.com/pycqa/flake8 |
|
15 |
- rev: 3.7.9 |
|
14 |
+- repo: https://github.com/astral-sh/ruff-pre-commit |
|
15 |
+ rev: "v0.1.1" |
|
16 | 16 |
hooks: |
17 |
- - id: flake8 |
|
17 |
+ - id: ruff |
|
18 |
+ args: ["--fix"] |
|
19 |
+- repo: https://github.com/pre-commit/mirrors-mypy |
|
20 |
+ rev: "v1.6.1" |
|
21 |
+ hooks: |
|
22 |
+ - id: mypy |
... | ... |
@@ -7,7 +7,7 @@ module = "qsim" |
7 | 7 |
author = "Joseph Weston" |
8 | 8 |
author-email = "joseph@weston.cloud" |
9 | 9 |
home-page = "https://github.com/jbweston/qsim" |
10 |
-requires-python=">=3.6" |
|
10 |
+requires-python=">=3.11" |
|
11 | 11 |
description-file="README.md" |
12 | 12 |
keywords = "quantum simulator" |
13 | 13 |
classifiers = [ |
... | ... |
@@ -17,8 +17,7 @@ classifiers = [ |
17 | 17 |
"Intended Audience :: Science/Research", |
18 | 18 |
"Topic :: Scientific/Engineering", |
19 | 19 |
"Topic :: Scientific/Engineering :: Physics", |
20 |
- "Programming Language :: Python :: 3.8", |
|
21 |
- "Programming Language :: Python :: 3.9", |
|
20 |
+ "Programming Language :: Python :: 3.11", |
|
22 | 21 |
] |
23 | 22 |
requires = [ |
24 | 23 |
"numpy", |
... | ... |
@@ -28,13 +27,12 @@ requires = [ |
28 | 27 |
test = [ |
29 | 28 |
"pytest", |
30 | 29 |
"pytest-cov", |
31 |
- "pytest-flake8", |
|
30 |
+ "pytest-ruff", |
|
32 | 31 |
"pytest-mypy", |
33 | 32 |
"pytest-black", |
34 | 33 |
"hypothesis[numpy]", |
35 | 34 |
"tox", |
36 |
- "flake8-per-file-ignores", |
|
37 |
- "flake8>=3.7.2", # https://github.com/pycqa/flake8/issues/668 |
|
35 |
+ "ruff", |
|
38 | 36 |
] |
39 | 37 |
docs = [ |
40 | 38 |
"sphinx", |
... | ... |
@@ -1,19 +1,17 @@ |
1 | 1 |
[tox] |
2 | 2 |
isolated_build = True |
3 |
-envlist = clean,py{38,39},report |
|
3 |
+envlist = clean,py{311},report |
|
4 | 4 |
|
5 | 5 |
[gh-actions] |
6 | 6 |
python = |
7 |
- 3.8: clean,py38,report |
|
8 |
- 3.9: clean,py39,report |
|
7 |
+ 3.11: clean,py311,report |
|
9 | 8 |
|
10 | 9 |
[pytest] |
11 | 10 |
addopts = |
12 | 11 |
--durations=5 |
13 |
- --cov --cov-append --cov-fail-under=100 --cov-report= |
|
12 |
+ --cov --cov-append --cov-fail-under=90 --cov-report= |
|
14 | 13 |
--black |
15 | 14 |
--mypy |
16 |
- --flake8 |
|
17 | 15 |
norecursedirs = |
18 | 16 |
docs |
19 | 17 |
|
... | ... |
@@ -38,8 +36,8 @@ output = .coverage.xml |
38 | 36 |
deps = .[test] |
39 | 37 |
commands = pytest |
40 | 38 |
depends = |
41 |
- {py38,py39}: clean |
|
42 |
- report: {py38,py39} |
|
39 |
+ {py311}: clean |
|
40 |
+ report: {py311} |
|
43 | 41 |
|
44 | 42 |
[testenv:report] |
45 | 43 |
deps = coverage |