Skip to content

Commit

Permalink
remove codecov (#392)
Browse files Browse the repository at this point in the history
* Remove dependency on codecov package

See for details:
* https://about.codecov.io/blog/message-regarding-the-pypi-package/
* https://community.codecov.com/t/codecov-yanked-from-pypi-all-versions/4259

* Bump pip version to 23.0

* Remove codecov usage

Code coverage is uploaded by a github action job. No need to call
`codecov`.

* Generate coverage report in xml format

As per https://docs.codecov.com/docs/supported-report-formats `.coverage` is not supported.
  • Loading branch information
akuzminsky authored Apr 14, 2023
1 parent 053deb4 commit ed72278
Show file tree
Hide file tree
Showing 6 changed files with 35 additions and 48 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/makefile.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ jobs:

- name: "Run tests"
run: |
pip install -U "pip ~= 22.0.0"
pip install -U "pip ~= 23.0.0"
python -m venv ~/.env
source ~/.env/bin/activate
make bootstrap lint test
Expand Down
8 changes: 4 additions & 4 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ virtualenv: ## create virtual environment typically used for development purpose

.PHONY: pip
pip:
pip install -U "pip ~= 22.2"
pip install -U "pip ~= 23.0"

.PHONY: pip-tools
pip-tools: pip
Expand Down Expand Up @@ -90,8 +90,9 @@ clean-pyc: ## remove Python file artifacts

clean-test: ## remove test and coverage artifacts
rm -fr .tox/
rm -f .coverage
rm -f .coverage coverage.xml
rm -fr htmlcov/
rm -rf .pytest_cache

clean-docker:
@sudo docker rm twindb-backup-build-${PLATFORM}
Expand All @@ -117,8 +118,7 @@ lint: ## check style with pylint


test: ## Run tests quickly with the default Python and generate code coverage report
pytest -xv --cov-report term-missing --cov=./twindb_backup tests/unit
codecov
pytest -xv --cov-report term-missing --cov-report xml --cov=./twindb_backup tests/unit

test-including-azure-blob: ## Like 'make test' but includes tests for azure blob destination
coverage run --source=twindb_backup -m pytest -xv tests/unit
Expand Down
6 changes: 1 addition & 5 deletions requirements.in
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,7 @@ boto3 ~= 1.7
psutil ~= 5.4
pyasn1 ~= 0.4
datadog ~= 0.22
# Paramiko version 2.4.2 is buggy. See
# https://github.com/paramiko/paramiko/issues/1386
# https://github.com/paramiko/paramiko/issues/1369
paramiko ~= 2.4
cryptography ~= 39.0
paramiko ~= 2.5
google ~= 3.0
google-cloud-storage ~= 2.3.0
statsd ~= 3.3
Expand Down
23 changes: 11 additions & 12 deletions requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,19 +4,19 @@
#
# pip-compile --output-file=requirements.txt requirements.in
#
azure-core==1.26.3
azure-core==1.26.4
# via
# -r requirements.in
# azure-storage-blob
azure-storage-blob==12.15.0
azure-storage-blob==12.16.0
# via -r requirements.in
bcrypt==4.0.1
# via paramiko
beautifulsoup4==4.11.2
beautifulsoup4==4.12.2
# via google
boto3==1.26.89
boto3==1.26.113
# via -r requirements.in
botocore==1.29.89
botocore==1.29.113
# via
# boto3
# s3transfer
Expand All @@ -32,20 +32,19 @@ charset-normalizer==3.1.0
# via requests
click==8.1.3
# via -r requirements.in
cryptography==39.0.2
cryptography==40.0.1
# via
# -r requirements.in
# azure-storage-blob
# paramiko
datadog==0.44.0
datadog==0.45.0
# via -r requirements.in
google==3.0.0
# via -r requirements.in
google-api-core==2.11.0
# via
# google-cloud-core
# google-cloud-storage
google-auth==2.16.2
google-auth==2.17.3
# via
# google-api-core
# google-cloud-core
Expand All @@ -58,7 +57,7 @@ google-crc32c==1.5.0
# via google-resumable-media
google-resumable-media==2.4.1
# via google-cloud-storage
googleapis-common-protos==1.58.0
googleapis-common-protos==1.59.0
# via google-api-core
idna==3.4
# via requests
Expand All @@ -70,7 +69,7 @@ jmespath==1.0.1
# botocore
paramiko==2.12.0
# via -r requirements.in
protobuf==4.22.1
protobuf==4.22.3
# via
# google-api-core
# google-cloud-storage
Expand All @@ -86,7 +85,7 @@ pyasn1-modules==0.2.8
# via google-auth
pycparser==2.21
# via cffi
pymysql==1.0.2
pymysql==1.0.3
# via -r requirements.in
pynacl==1.5.0
# via paramiko
Expand Down
1 change: 0 additions & 1 deletion requirements_dev.in
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@
black ~= 22.3
Sphinx ~= 4.5
bumpversion ~= 0.6
codecov ~= 2.0
docker ~= 5.0
isort ~= 5.10
mock ~= 4.0
Expand Down
43 changes: 18 additions & 25 deletions requirements_dev.txt
Original file line number Diff line number Diff line change
Expand Up @@ -6,17 +6,15 @@
#
alabaster==0.7.13
# via sphinx
astroid==2.15.0
astroid==2.15.2
# via pylint
attrs==22.2.0
# via pytest
babel==2.12.1
# via sphinx
black==22.12.0
# via -r requirements_dev.in
boto3==1.26.89
boto3==1.26.113
# via moto
botocore==1.29.89
botocore==1.29.113
# via
# boto3
# moto
Expand All @@ -35,27 +33,23 @@ click==8.1.3
# via
# black
# runlike
codecov==2.1.12
# via -r requirements_dev.in
coverage[toml]==7.2.1
# via
# codecov
# pytest-cov
cryptography==39.0.2
coverage[toml]==7.2.3
# via pytest-cov
cryptography==40.0.1
# via moto
dill==0.3.6
# via pylint
docker==5.0.3
# via -r requirements_dev.in
docutils==0.17.1
# via sphinx
exceptiongroup==1.1.0
exceptiongroup==1.1.1
# via pytest
idna==3.4
# via requests
imagesize==1.4.1
# via sphinx
importlib-metadata==6.0.0
importlib-metadata==6.3.0
# via sphinx
iniconfig==2.0.0
# via pytest
Expand All @@ -81,19 +75,19 @@ mccabe==0.7.0
# via pylint
mock==4.0.3
# via -r requirements_dev.in
moto==4.1.4
moto==4.1.7
# via -r requirements_dev.in
mypy-extensions==1.0.0
# via black
packaging==23.0
packaging==23.1
# via
# pytest
# sphinx
pathspec==0.11.0
pathspec==0.11.1
# via
# black
# yamllint
platformdirs==3.1.1
platformdirs==3.2.0
# via
# black
# pylint
Expand All @@ -103,11 +97,11 @@ pycodestyle==2.10.0
# via -r requirements_dev.in
pycparser==2.21
# via cffi
pygments==2.14.0
pygments==2.15.0
# via sphinx
pylint==2.17.0
pylint==2.17.2
# via -r requirements_dev.in
pytest==7.2.2
pytest==7.3.0
# via
# -r requirements_dev.in
# pytest-cov
Expand All @@ -128,7 +122,6 @@ pyyaml==6.0
# yamllint
requests==2.28.2
# via
# codecov
# docker
# moto
# responses
Expand Down Expand Up @@ -163,9 +156,9 @@ tomli==2.0.1
# coverage
# pylint
# pytest
tomlkit==0.11.6
tomlkit==0.11.7
# via pylint
types-pyyaml==6.0.12.8
types-pyyaml==6.0.12.9
# via responses
typing-extensions==4.5.0
# via
Expand All @@ -185,7 +178,7 @@ wrapt==1.15.0
# via astroid
xmltodict==0.13.0
# via moto
yamllint==1.29.0
yamllint==1.30.0
# via -r requirements_dev.in
zipp==3.15.0
# via importlib-metadata
Expand Down

0 comments on commit ed72278

Please sign in to comment.