-
-
Notifications
You must be signed in to change notification settings - Fork 52
/
Copy pathMakefile
39 lines (27 loc) · 959 Bytes
/
Makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
.PHONY: build test benchmark typecheck typecheck-strict clean
build:
poetry install
test:
python -m pytest tests -v --cov=aw_core --cov=aw_datastore --cov=aw_transform --cov=aw_query
.coverage:
make test
coverage_html: .coverage
python -m coverage html -d coverage_html
benchmark:
python -m aw_datastore.benchmark
typecheck:
export MYPYPATH=./stubs; python -m mypy aw_core aw_datastore aw_transform aw_query --show-traceback --ignore-missing-imports --follow-imports=skip
typecheck-strict:
export MYPYPATH=./stubs; python -m mypy aw_core aw_datastore aw_transform aw_query --strict-optional --check-untyped-defs; echo "Not a failing step"
PYFILES=$(shell find . -type f -name '*.py')
PYIFILES=$(shell find . -type f -name '*.pyi')
lint:
ruff check .
lint-fix:
pyupgrade --py37-plus ${PYFILES} && true
ruff check --fix .
format:
black ${PYFILES} ${PYIFILES}
clean:
rm -rf build dist
rm -rf aw_core/__pycache__ aw_datastore/__pycache__