Skip to content

Commit

Permalink
Consolidated dependencies (#1606)
Browse files Browse the repository at this point in the history
`requirements_dev.txt` and `requirements_test.txt` occasionally have version conflicts with `requirements.txt` that breaks test and dev environments. These are now produced as consolidated files.
  • Loading branch information
jace authored Jan 27, 2023
1 parent 77f1c06 commit 992f6b7
Show file tree
Hide file tree
Showing 6 changed files with 1,125 additions and 35 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/pytest.yml
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@ jobs:
- name: Install Python dependencies
run: |
python -m pip install --upgrade pip
pip install -r requirements.txt -r requirements_test.txt
pip install -r requirements_test.txt
- name: Install pytest-github-actions-annotate-failures
run: pip install pytest-github-actions-annotate-failures
- name: Install Node modules
Expand Down
27 changes: 20 additions & 7 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,16 +16,29 @@ repos:
hooks:
- id: pip-compile
name: pip-compile requirements.in
args: ['requirements.in']
args: ['--output-file', 'requirements.txt', 'requirements.in']
files: ^requirements\.(in|txt)$
- id: pip-compile
name: pip-compile requirements_dev.in
args: ['requirements_dev.in']
files: ^requirements_dev\.(in|txt)$
- id: pip-compile
name: pip-compile requirements_test.in
args: ['requirements_test.in']
files: ^requirements_test\.(in|txt)$
args:
[
'--output-file',
'requirements_test.txt',
'requirements.in',
'requirements_test.in',
]
files: ^requirements(_test)?\.(in|txt)$
- id: pip-compile
name: pip-compile requirements_dev.in
args:
[
'--output-file',
'requirements_dev.txt',
'requirements.in',
'requirements_test.in',
'requirements_dev.in',
]
files: ^requirements(_test|_dev)?\.(in|txt)$
- repo: https://github.com/lucasmbrown/mirrors-autoflake
rev: v1.3
hooks:
Expand Down
12 changes: 6 additions & 6 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -25,16 +25,16 @@ babeljs:
ls $(baseframe_dir) | grep -E '[[:lower:]]{2}_[[:upper:]]{2}' | xargs -I % sh -c './node_modules/.bin/po2json --format=jed --pretty $(baseframe_dir)/%/LC_MESSAGES/baseframe.po $(target_dir)/%/baseframe.json'
./node_modules/.bin/prettier --write $(target_dir)/**/**.json

deps: deps-main deps-dev deps-test
deps: deps-main deps-test deps-dev

deps-main:
pip-compile --upgrade requirements.in

deps-dev:
pip-compile --upgrade requirements_dev.in
pip-compile --upgrade --output-file requirements.txt requirements.in

deps-test:
pip-compile --upgrade requirements_test.in
pip-compile --upgrade --output-file requirements_test.txt requirements.in requirements_test.in

deps-dev:
pip-compile --upgrade --output-file requirements_dev.txt requirements.in requirements_test.in requirements_dev.in

tests-data: tests-data-markdown

Expand Down
2 changes: 1 addition & 1 deletion requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
# This file is autogenerated by pip-compile with Python 3.9
# by the following command:
#
# pip-compile requirements.in
# pip-compile --output-file=requirements.txt requirements.in
#
aiohttp==3.8.3
# via
Expand Down
Loading

0 comments on commit 992f6b7

Please sign in to comment.