Skip to content

Commit

Permalink
Unify requirements files (#264)
Browse files Browse the repository at this point in the history
  • Loading branch information
cristianonicolai authored Feb 5, 2024
1 parent 7ea7a7b commit 9ffdebb
Show file tree
Hide file tree
Showing 11 changed files with 122 additions and 101 deletions.
104 changes: 104 additions & 0 deletions .config/constraints.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,104 @@
#
# This file is autogenerated by pip-compile with Python 3.10
# by the following command:
#
# pip-compile --all-extras --no-annotate --output-file=.config/constraints.txt --strip-extras pyproject.toml
#
ansible-compat==4.1.11
ansible-core==2.16.2
attrs==23.2.0
babel==2.14.0
beautifulsoup4==4.12.3
black==24.1.1
cachetools==5.3.2
cairocffi==1.6.1
cairosvg==2.7.1
certifi==2023.11.17
cffi==1.16.0
cfgv==3.4.0
chardet==5.2.0
charset-normalizer==3.3.2
click==8.1.7
colorama==0.4.6
coverage==7.4.1
cryptography==42.0.1
csscompressor==0.9.5
cssselect2==0.7.0
defusedxml==0.7.1
distlib==0.3.8
dnspython==2.5.0
exceptiongroup==1.2.0
execnet==2.0.2
filelock==3.13.1
ghp-import==2.1.0
griffe==0.39.1
htmlmin2==0.1.13
identify==2.5.33
idna==3.6
iniconfig==2.0.0
jinja2==3.1.3
jsmin==3.0.1
jsonschema==4.21.1
jsonschema-specifications==2023.12.1
linkchecker==10.4.0
markdown==3.5.2
markdown-exec==1.8.0
markdown-include==0.8.1
markupsafe==2.1.4
mergedeep==1.3.4
mkdocs==1.5.3
mkdocs-ansible==0.2.1
mkdocs-autorefs==0.5.0
mkdocs-gen-files==0.5.0
mkdocs-htmlproofer-plugin==1.0.0
mkdocs-material==9.5.6
mkdocs-material-extensions==1.3.1
mkdocs-minify-plugin==0.7.2
mkdocs-monorepo-plugin==1.1.0
mkdocstrings==0.24.0
mkdocstrings-python==1.8.0
mypy==1.8.0
mypy-extensions==1.0.0
nodeenv==1.8.0
packaging==23.2
paginate==0.5.6
pathspec==0.12.1
pillow==10.2.0
pipdeptree==2.13.2
platformdirs==4.1.0
pluggy==1.4.0
pre-commit==3.6.0
pycparser==2.21
pygments==2.17.2
pymdown-extensions==10.7
pyproject-api==1.6.1
pytest==8.0.0
pytest-ansible==24.1.2
pytest-mock==3.12.0
pytest-xdist==3.5.0
python-dateutil==2.8.2
python-slugify==8.0.2
pyyaml==6.0.1
pyyaml-env-tag==0.1
referencing==0.33.0
regex==2023.12.25
requests==2.31.0
resolvelib==1.0.1
rpds-py==0.17.1
ruff==0.1.14
six==1.16.0
soupsieve==2.5
subprocess-tee==0.4.1
text-unidecode==1.3
tinycss2==1.2.1
tomli==2.0.1
tox==4.12.1
types-pyyaml==6.0.12.12
typing-extensions==4.9.0
urllib3==2.1.0
virtualenv==20.25.0
watchdog==3.0.0
webencodings==0.5.1

# The following packages are considered to be unsafe in a requirements file:
# setuptools
File renamed without changes.
2 changes: 2 additions & 0 deletions .config/requirements-docs.in
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
mkdocs-ansible>=0.2.0
pipdeptree>=2.7.1
2 changes: 0 additions & 2 deletions .config/requirements-docs.txt

This file was deleted.

File renamed without changes.
5 changes: 4 additions & 1 deletion .github/dependabot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,10 @@ updates:
labels:
- dependabot-deps-updates
- skip-changelog
versioning-strategy: lockfile-only
groups:
dependencies:
patterns:
- "*"
- package-ecosystem: "github-actions"
directory: "/"
schedule:
Expand Down
12 changes: 6 additions & 6 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ repos:

- repo: https://github.com/pre-commit/mirrors-prettier
# keep it before yamllint
rev: v3.0.3
rev: v4.0.0-alpha.8
hooks:
- id: prettier
always_run: true
Expand All @@ -46,7 +46,7 @@ repos:
- prettier-plugin-sort-json

- repo: https://github.com/psf/black
rev: 23.12.1
rev: 24.1.1
hooks:
- id: black

Expand All @@ -60,7 +60,7 @@ repos:
hooks:
- id: tox-ini-fmt
- repo: https://github.com/astral-sh/ruff-pre-commit
rev: "v0.1.11"
rev: "v0.1.14"
hooks:
- id: ruff
args:
Expand All @@ -73,15 +73,15 @@ repos:
name: Spell check with cspell

- repo: https://github.com/PyCQA/flake8.git
rev: 6.1.0
rev: 7.0.0
hooks:
- id: flake8
language_version: python3
additional_dependencies:
- flake8-docstrings

- repo: https://github.com/jsh9/pydoclint
rev: 0.3.8
rev: 0.3.9
hooks:
- id: pydoclint
args:
Expand Down Expand Up @@ -119,7 +119,7 @@ repos:
name: lock
alias: lock
always_run: true
entry: pip-compile --upgrade -q --strip-extras --extra=docs --extra=test --no-annotate --output-file=requirements.txt pyproject.toml
entry: pip-compile --upgrade -q --strip-extras --all-extras --no-annotate --output-file=.config/constraints.txt pyproject.toml
files: ^.config\/.*requirements.*$
language: python
language_version: "3.10" # minimal we support officially
Expand Down
6 changes: 3 additions & 3 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -126,9 +126,9 @@ convention = "pep257"

[tool.setuptools.dynamic]
dependencies = {file = [".config/requirements.in"]}
optional-dependencies.docs = {file = [".config/requirements-docs.txt"]}
optional-dependencies.dev = {file = [".config/requirements-dev.txt"]}
optional-dependencies.test = {file = [".config/requirements-test.txt"]}
optional-dependencies.docs = {file = [".config/requirements-docs.in"]}
optional-dependencies.dev = {file = [".config/requirements-dev.in"]}
optional-dependencies.test = {file = [".config/requirements-test.in"]}

[tool.setuptools_scm]
local_scheme = "no-local-version"
Expand Down
88 changes: 0 additions & 88 deletions requirements.txt

This file was deleted.

1 change: 1 addition & 0 deletions tests/integration/test_user_provided.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
"""User provided configuration."""

import subprocess

from configparser import ConfigParser
Expand Down
3 changes: 2 additions & 1 deletion tox.ini
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ pass_env =
set_env =
COVERAGE_PROCESS_START = {toxinidir}/pyproject.toml
FORCE_COLOR = 1
PIP_CONSTRAINT = {toxinidir}/requirements.txt
PIP_CONSTRAINT = {toxinidir}/.config/constraints.txt
PRE_COMMIT_COLOR = always
TERM = xterm-256color
lint, py39: PIP_CONSTRAINT = /dev/null
Expand All @@ -44,6 +44,7 @@ commands =
coverage report
coverage xml
allowlist_externals =
git
rm
sh
editable = true
Expand Down

0 comments on commit 9ffdebb

Please sign in to comment.