Browse Source

Consolidate configuration, get rid of asaman

master
/dev/null 1 month ago
parent
commit
cb5ce749c9
  1. 12
      .editorconfig
  2. 5
      .flake8
  3. 7
      Makefile
  4. 5
      Pipfile
  5. 53
      Pipfile.lock
  6. 12
      mypy.ini
  7. 25
      pyproject.toml

12
.editorconfig

@ -0,0 +1,12 @@
# https://editorconfig.org
root = true
[*]
end_of_line = lf
charset = utf-8
trim_trailing_whitespace = true
insert_final_newline = true
[Makefile]
indent_style=tab

5
.flake8

@ -1,5 +0,0 @@
[flake8]
max-line-length = 88
noqa-require-code = True
exclude = .git,__pycache__,build,dist
max-complexity = 15

7
Makefile

@ -5,7 +5,7 @@ format:
test:
python -m black --check .
python -m isort --check .
python -m flake8 .
python -m pflake8 .
python -m mypy --strict .
$(MAKE) test-pytest
@ -13,10 +13,9 @@ test-pytest:
python -m pytest --cov=sporestack --cov-fail-under=49 --cov-report=term --durations=3 --cache-clear
build-dist:
# This should result in a reproducible wheel.
rm dist/* || true
python -m build --sdist --no-isolation
asaman -o dist -d dist
# This should result in a reproducible wheel.
SOURCE_DATE_EPOCH=1309379017 python -m build --no-isolation
python -m twine check --strict dist/*
servedocs:

5
Pipfile

@ -10,9 +10,10 @@ sporestack = {editable = true, path = "."}
# Have to do == because it's a pre-release.
black = "==21.12b0"
flake8 = "~=4.0"
pyproject-flake8 = "==0.0.1a2"
flake8-noqa = "~=1.2"
pep8-naming = "~=0.12.1"
mypy = "~=0.910"
mypy = "==0.910" # The pydantic mypy plugin has an issue with 0.920
pytest = "~=6.2"
pytest-cov = "~=3.0"
isort = "~=5.8"
@ -20,8 +21,8 @@ isort = "~=5.8"
types-requests = "~=2.25"
# Building
asaman = "~=0.1.6"
wheel = "~=0.37.0"
build = "~=0.7.0"
# Publishing
twine = "~=3.4"

53
Pipfile.lock

@ -1,7 +1,7 @@
{
"_meta": {
"hash": {
"sha256": "5af69dd05fd6d46761a82dd28393552dc43447b503be2c4997e5b586869c896e"
"sha256": "2408f9b28c682606985e57e547fb40c8e04ce708a7184df371379e410df7a57d"
},
"pipfile-spec": 6,
"requires": {},
@ -138,14 +138,6 @@
"index": "pypi",
"version": "==0.5.1"
},
"asaman": {
"hashes": [
"sha256:66df5adac811841f3128b06913b31a01c3e751886b7126ef392569172debeaca",
"sha256:f81274da9d677b83dd0150dc3a08785b8008fc4694259facc8809ae200a09453"
],
"index": "pypi",
"version": "==0.1.6"
},
"astunparse": {
"hashes": [
"sha256:5ad93a8456f0d084c3456d059fd9a92cce667963232cbf763eac3bc5b7940872",
@ -183,7 +175,7 @@
"sha256:1aaadcd69338252ade4f7ec1265e1a19184bf916d84c9b7df095f423948cb89f",
"sha256:21b7ebbd1b22499c4dac536abc7606696ea4d909fd755e00f09f3c0f2c05e3c8"
],
"markers": "python_version >= '3.6'",
"index": "pypi",
"version": "==0.7.0"
},
"certifi": {
@ -313,11 +305,11 @@
},
"importlib-metadata": {
"hashes": [
"sha256:53ccfd5c134223e497627b9815d5030edf77d2ed573922f7a0b8f8bb81a1c100",
"sha256:75bdec14c397f528724c1bfd9709d660b33a4d2e77387a3358f20b848bb5e5fb"
"sha256:65a9576a5b2d58ca44d133c42a241905cc45e34d2c06fd5ba2bafa221e5d7b5e",
"sha256:766abffff765960fcc18003801f7044eb6755ffae4521c8e8ce8e83b9c9b0668"
],
"markers": "python_version >= '3.6'",
"version": "==4.8.2"
"version": "==4.8.3"
},
"iniconfig": {
"hashes": [
@ -568,6 +560,14 @@
"markers": "python_version >= '3.6'",
"version": "==3.0.6"
},
"pyproject-flake8": {
"hashes": [
"sha256:bdeca37f78ecd34bd64a49d3657d53d099f5445831071a31c46e1fe20cd61461",
"sha256:e61ed1dc088e9f9f8a7170967ac4ec135acfef3a59ab9738c7b58cc11f294a7e"
],
"index": "pypi",
"version": "==0.0.1a2"
},
"pytest": {
"hashes": [
"sha256:131b36680866a76e6781d13f101efb86cf674ebb9762eb70d3082b6f29889e89",
@ -586,10 +586,11 @@
},
"readme-renderer": {
"hashes": [
"sha256:3286806450d9961d6e3b5f8a59f77e61503799aca5155c8d8d40359b4e1e1adc",
"sha256:8299700d7a910c304072a7601eafada6712a5b011a20139417e1b1e9f04645d8"
"sha256:a50a0f2123a4c1145ac6f420e1a348aafefcc9211c846e3d51df05fe3d865b7d",
"sha256:b512beafa6798260c7d5af3e1b1f097e58bfcd9a575da7c4ddd5e037490a5b85"
],
"version": "==30.0"
"markers": "python_version >= '3.6'",
"version": "==32.0"
},
"requests": {
"extras": [
@ -616,14 +617,6 @@
],
"version": "==1.5.0"
},
"setuptools": {
"hashes": [
"sha256:6d10741ff20b89cd8c6a536ee9dc90d3002dec0226c78fb98605bfb9ef8a7adf",
"sha256:d144f85102f999444d06f9c0e8c737fd0194f10f2f7e5fdb77573f6e2fa4fad0"
],
"markers": "python_version >= '3.6'",
"version": "==59.5.0"
},
"six": {
"hashes": [
"sha256:1e61c37477a1626458e36f7b1d82aa5c9b094fa4802892072e49de9c60c4c926",
@ -642,11 +635,11 @@
},
"tomli": {
"hashes": [
"sha256:c6ce0015eb38820eaf32b5db832dbc26deb3dd427bd5f6556cf0acac2c214fee",
"sha256:f04066f68f5554911363063a30b108d2b5a5b1a010aa8b6132af78489fe3aade"
"sha256:05b6166bff487dc068d322585c7ea4ef78deed501cc124060e0f238e89a9231f",
"sha256:e3069e4be3ead9668e21cb9b074cd948f7b3113fd9c8bba083f48247aab8b11c"
],
"markers": "python_version >= '3.6'",
"version": "==1.2.2"
"version": "==1.2.3"
},
"tqdm": {
"hashes": [
@ -658,11 +651,11 @@
},
"twine": {
"hashes": [
"sha256:5a3e3fb52b926827c99e050f0c1e5d8ae599848f3eb27764f19b886c09134590",
"sha256:8d6a0ad895576c97e9ad4a5da2d6adea37fd5434ecabace0054013d537ddbc6c"
"sha256:28460a3db6b4532bde6a5db6755cf2dce6c5020bada8a641bb2c5c7a9b1f35b8",
"sha256:8c120845fc05270f9ee3e9d7ebbed29ea840e41f48cd059e04733f7e1d401345"
],
"index": "pypi",
"version": "==3.7.0"
"version": "==3.7.1"
},
"types-requests": {
"hashes": [

12
mypy.ini

@ -1,12 +0,0 @@
[mypy]
exclude = build
plugins = pydantic.mypy
[pydantic-mypy]
init_forbid_extra = True
init_typed = True
warn_required_dynamic_aliases = True
warn_untyped_fields = True
[mypy-sshpubkeys.*]
ignore_missing_imports = True

25
pyproject.toml

@ -1,8 +1,29 @@
[tool.coverage.report]
show_missing = true
[tool.coverage.run]
omit = ["tests/*", "build/*"]
# Have to use `pflake8` instead of `flake8`
[tool.flake8]
max-line-length = 88
noqa-require-code = "true"
exclude = ".git,__pycache__,build,dist"
max-complexity = 15
[tool.isort]
profile = "black"
[tool.coverage.report]
show_missing = true
[tool.mypy]
files = "."
plugins = ["pydantic.mypy"]
exclude = "(build|site-packages|__pycache__)"
[tool.pydantic-mypy]
init_forbid_extra = true
init_typed = true
warn_required_dynamic_aliases = true
warn_untyped_fields = true
[build-system]
requires = ["setuptools", "wheel"]

Loading…
Cancel
Save