ConfigArgParse 1.7.2.dev0__tar.gz → 1.7.5__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- configargparse-1.7.5/.coveragerc +12 -0
- configargparse-1.7.5/.editorconfig +17 -0
- configargparse-1.7.5/.git-blame-ignore-revs +7 -0
- configargparse-1.7.5/.github/workflows/apidocs.yml +38 -0
- configargparse-1.7.5/.github/workflows/test.yml +181 -0
- configargparse-1.7.5/.github/zizmor.yml +7 -0
- configargparse-1.7.5/.gitignore +52 -0
- configargparse-1.7.5/CONTRIBUTING.rst +61 -0
- configargparse-1.7.5/ConfigArgParse.egg-info/PKG-INFO +616 -0
- {configargparse-1.7.2.dev0 → configargparse-1.7.5}/ConfigArgParse.egg-info/SOURCES.txt +10 -1
- {configargparse-1.7.2.dev0 → configargparse-1.7.5}/ConfigArgParse.egg-info/requires.txt +4 -0
- {configargparse-1.7.2.dev0 → configargparse-1.7.5}/MANIFEST.in +1 -1
- configargparse-1.7.5/PKG-INFO +616 -0
- configargparse-1.7.5/README.md +570 -0
- configargparse-1.7.5/apidocs.sh +46 -0
- {configargparse-1.7.2.dev0 → configargparse-1.7.5}/configargparse.py +233 -61
- {configargparse-1.7.2.dev0 → configargparse-1.7.5}/setup.py +8 -3
- {configargparse-1.7.2.dev0 → configargparse-1.7.5}/tests/test_configargparse.py +598 -65
- configargparse-1.7.2.dev0/ConfigArgParse.egg-info/PKG-INFO +0 -641
- configargparse-1.7.2.dev0/PKG-INFO +0 -641
- configargparse-1.7.2.dev0/README.rst +0 -601
- {configargparse-1.7.2.dev0 → configargparse-1.7.5}/ConfigArgParse.egg-info/dependency_links.txt +0 -0
- {configargparse-1.7.2.dev0 → configargparse-1.7.5}/ConfigArgParse.egg-info/top_level.txt +0 -0
- {configargparse-1.7.2.dev0 → configargparse-1.7.5}/LICENSE +0 -0
- {configargparse-1.7.2.dev0 → configargparse-1.7.5}/setup.cfg +0 -0
- {configargparse-1.7.2.dev0 → configargparse-1.7.5}/tests/__init__.py +0 -0
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
# https://editorconfig.org/
|
|
2
|
+
|
|
3
|
+
root = true
|
|
4
|
+
|
|
5
|
+
[*]
|
|
6
|
+
indent_style = space
|
|
7
|
+
indent_size = 4
|
|
8
|
+
insert_final_newline = true
|
|
9
|
+
trim_trailing_whitespace = true
|
|
10
|
+
end_of_line = lf
|
|
11
|
+
charset = utf-8
|
|
12
|
+
|
|
13
|
+
[*.py]
|
|
14
|
+
max_line_length = 88
|
|
15
|
+
|
|
16
|
+
[*.yml]
|
|
17
|
+
indent_size = 2
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
# .git-blame-ignore-revs used to ignore SHAs from git blame
|
|
2
|
+
# applied automatically in Github, use the command
|
|
3
|
+
# `git config blame.ignoreRevsFile .git-blame-ignore-revs` to config git to
|
|
4
|
+
# use it as well
|
|
5
|
+
|
|
6
|
+
# black format
|
|
7
|
+
0962f7378ceec1218e30489352df4c80533d4cb8
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
name: apidocs
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
push:
|
|
5
|
+
branches: [ master ]
|
|
6
|
+
tags:
|
|
7
|
+
- '*'
|
|
8
|
+
|
|
9
|
+
# Set minimal permissions by default
|
|
10
|
+
permissions: {}
|
|
11
|
+
|
|
12
|
+
jobs:
|
|
13
|
+
deploy:
|
|
14
|
+
runs-on: macos-latest
|
|
15
|
+
permissions:
|
|
16
|
+
contents: write
|
|
17
|
+
|
|
18
|
+
steps:
|
|
19
|
+
- uses: actions/checkout@v4
|
|
20
|
+
with:
|
|
21
|
+
persist-credentials: false
|
|
22
|
+
- name: Set up Python 3.8
|
|
23
|
+
uses: actions/setup-python@v2
|
|
24
|
+
with:
|
|
25
|
+
python-version: 3.8
|
|
26
|
+
|
|
27
|
+
- name: Install requirements for documentation generation
|
|
28
|
+
run: python -m pip install --upgrade pip pydoctor
|
|
29
|
+
|
|
30
|
+
- name: Generate API documentation with pydoctor
|
|
31
|
+
run: ./apidocs.sh
|
|
32
|
+
|
|
33
|
+
- name: Push API documentation to Github Pages
|
|
34
|
+
uses: peaceiris/actions-gh-pages@4f9cc6602d3f66b9c108549d475ec49e8ef4d45e # v4.0.0
|
|
35
|
+
with:
|
|
36
|
+
github_token: ${{ secrets.GITHUB_TOKEN }}
|
|
37
|
+
publish_dir: ./apidocs
|
|
38
|
+
commit_message: "Generate API documentation"
|
|
@@ -0,0 +1,181 @@
|
|
|
1
|
+
name: unit tests
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
push:
|
|
5
|
+
branches: [ master ]
|
|
6
|
+
tags:
|
|
7
|
+
- '*'
|
|
8
|
+
pull_request:
|
|
9
|
+
|
|
10
|
+
# Set minimal permissions by default
|
|
11
|
+
permissions: {}
|
|
12
|
+
|
|
13
|
+
concurrency:
|
|
14
|
+
group: ${{ github.workflow }}-${{ github.ref }}
|
|
15
|
+
cancel-in-progress: ${{ github.ref != 'refs/heads/master' }}
|
|
16
|
+
|
|
17
|
+
jobs:
|
|
18
|
+
lint:
|
|
19
|
+
runs-on: ubuntu-latest
|
|
20
|
+
steps:
|
|
21
|
+
- uses: actions/checkout@v4
|
|
22
|
+
with:
|
|
23
|
+
persist-credentials: false
|
|
24
|
+
|
|
25
|
+
- uses: actions/setup-python@v5
|
|
26
|
+
with:
|
|
27
|
+
python-version: 3.13
|
|
28
|
+
|
|
29
|
+
- name: Install linters
|
|
30
|
+
run: python -m pip install --upgrade pip black zizmor pydoctor
|
|
31
|
+
|
|
32
|
+
- name: Black
|
|
33
|
+
run: black . --check
|
|
34
|
+
|
|
35
|
+
- name: Zizmor
|
|
36
|
+
run: find .github/workflows -name '*.yml' | xargs zizmor --config .github/zizmor.yml
|
|
37
|
+
|
|
38
|
+
- name: Pydoctor
|
|
39
|
+
run: pydoctor ./configargparse.py --intersphinx=https://docs.python.org/3/objects.inv --docformat=google -W
|
|
40
|
+
|
|
41
|
+
test:
|
|
42
|
+
name: ${{ matrix.os }} py${{ matrix.python-version }} ${{ matrix.use-docker && '(docker)' || '' }}
|
|
43
|
+
runs-on: ${{ matrix.os }}
|
|
44
|
+
|
|
45
|
+
strategy:
|
|
46
|
+
matrix:
|
|
47
|
+
include:
|
|
48
|
+
- name: Legacy Python on Ubuntu
|
|
49
|
+
os: ubuntu-latest
|
|
50
|
+
python-version: '3.6'
|
|
51
|
+
use-docker: true
|
|
52
|
+
- name: Legacy Python on Ubuntu
|
|
53
|
+
os: ubuntu-latest
|
|
54
|
+
python-version: '3.7'
|
|
55
|
+
use-docker: true
|
|
56
|
+
- name: Legacy Python on Ubuntu
|
|
57
|
+
os: ubuntu-latest
|
|
58
|
+
python-version: '3.8'
|
|
59
|
+
use-docker: true
|
|
60
|
+
|
|
61
|
+
os: [ubuntu-latest, windows-latest, macos-latest]
|
|
62
|
+
python-version: ['3.9','3.10','3.11','3.12','3.13']
|
|
63
|
+
use-docker: [false]
|
|
64
|
+
fail-fast: false
|
|
65
|
+
|
|
66
|
+
steps:
|
|
67
|
+
- uses: actions/checkout@v4
|
|
68
|
+
with:
|
|
69
|
+
persist-credentials: false
|
|
70
|
+
|
|
71
|
+
- name: Set up Python ${{ matrix.python-version }}
|
|
72
|
+
if: ${{ !matrix.use-docker }}
|
|
73
|
+
uses: actions/setup-python@v5
|
|
74
|
+
with:
|
|
75
|
+
python-version: ${{ matrix.python-version }}
|
|
76
|
+
|
|
77
|
+
- name: Run tests with Docker
|
|
78
|
+
if: ${{ matrix.use-docker }}
|
|
79
|
+
run: |
|
|
80
|
+
docker run --rm -v ${{ github.workspace }}:/app -w /app python:${{ matrix.python-version }} bash -c "
|
|
81
|
+
python -m pip install --upgrade pip setuptools wheel tox
|
|
82
|
+
python -m pip install '.[test]'
|
|
83
|
+
pytest --cov-branch --cov-context=test --cov=.
|
|
84
|
+
"
|
|
85
|
+
|
|
86
|
+
- name: Run tests
|
|
87
|
+
if: ${{ !matrix.use-docker }}
|
|
88
|
+
run: |
|
|
89
|
+
python -m pip install --upgrade pip setuptools wheel tox
|
|
90
|
+
python -m pip install '.[test]'
|
|
91
|
+
pytest --cov-branch --cov-context=test --cov=.
|
|
92
|
+
|
|
93
|
+
- name: Set artifact name
|
|
94
|
+
shell: bash
|
|
95
|
+
run: |
|
|
96
|
+
ARTIFACT_NAME="coverage-${{ runner.os }}-py-${{ matrix.python-version }}"
|
|
97
|
+
ARTIFACT_NAME="${ARTIFACT_NAME//./}"
|
|
98
|
+
echo "ARTIFACT_NAME=$ARTIFACT_NAME" >> "$GITHUB_ENV"
|
|
99
|
+
|
|
100
|
+
- name: Upload coverage artifact
|
|
101
|
+
uses: actions/upload-artifact@v4
|
|
102
|
+
with:
|
|
103
|
+
include-hidden-files: true
|
|
104
|
+
if-no-files-found: error
|
|
105
|
+
name: ${{ env.ARTIFACT_NAME }}
|
|
106
|
+
path: .coverage
|
|
107
|
+
retention-days: 1
|
|
108
|
+
|
|
109
|
+
coverage:
|
|
110
|
+
runs-on: ubuntu-latest
|
|
111
|
+
needs: test
|
|
112
|
+
steps:
|
|
113
|
+
- uses: actions/checkout@v4
|
|
114
|
+
with:
|
|
115
|
+
persist-credentials: false
|
|
116
|
+
|
|
117
|
+
- uses: actions/setup-python@v5
|
|
118
|
+
with:
|
|
119
|
+
python-version: 3.13
|
|
120
|
+
|
|
121
|
+
- name: Download artifacts
|
|
122
|
+
uses: actions/download-artifact@v4
|
|
123
|
+
with:
|
|
124
|
+
path: downloaded_artifacts
|
|
125
|
+
|
|
126
|
+
- name: Clean up temporary artifacts
|
|
127
|
+
uses: geekyeggo/delete-artifact@f275313e70c08f6120db482d7a6b98377786765b # v5.1.0
|
|
128
|
+
with:
|
|
129
|
+
name: coverage-*
|
|
130
|
+
|
|
131
|
+
- name: Install dependencies
|
|
132
|
+
run: pip install coverage
|
|
133
|
+
|
|
134
|
+
- name: Combine coverage.py
|
|
135
|
+
run: |
|
|
136
|
+
coverage combine $(find downloaded_artifacts/ -type f | xargs)
|
|
137
|
+
coverage xml
|
|
138
|
+
coverage html
|
|
139
|
+
coverage report --format=markdown >> $GITHUB_STEP_SUMMARY
|
|
140
|
+
cp coverage.xml htmlcov/coverage.xml
|
|
141
|
+
cp .coverage htmlcov/.coverage
|
|
142
|
+
|
|
143
|
+
- name: Upload single coverage artifact
|
|
144
|
+
uses: actions/upload-artifact@v4
|
|
145
|
+
with:
|
|
146
|
+
include-hidden-files: true
|
|
147
|
+
if-no-files-found: error
|
|
148
|
+
name: htmlcov
|
|
149
|
+
path: htmlcov
|
|
150
|
+
# Retention days for main branch is 90 days, for other branches is 1 day
|
|
151
|
+
retention-days: ${{ github.ref == 'refs/heads/master' && 90 || 1 }}
|
|
152
|
+
|
|
153
|
+
release:
|
|
154
|
+
needs: [test, coverage]
|
|
155
|
+
name: PyPI
|
|
156
|
+
runs-on: ubuntu-latest
|
|
157
|
+
environment: pypi
|
|
158
|
+
permissions:
|
|
159
|
+
id-token: write
|
|
160
|
+
steps:
|
|
161
|
+
- uses: actions/checkout@v4
|
|
162
|
+
with:
|
|
163
|
+
persist-credentials: false
|
|
164
|
+
|
|
165
|
+
- name: Set up Python 3.12
|
|
166
|
+
uses: actions/setup-python@v5
|
|
167
|
+
with:
|
|
168
|
+
python-version: 3.12
|
|
169
|
+
|
|
170
|
+
- name: Install build dependencies
|
|
171
|
+
run: |
|
|
172
|
+
python -m pip install -U setuptools wheel setuptools-scm
|
|
173
|
+
|
|
174
|
+
- name: Build
|
|
175
|
+
run: |
|
|
176
|
+
python setup.py --quiet build check sdist bdist_wheel
|
|
177
|
+
ls -alh ./dist/
|
|
178
|
+
|
|
179
|
+
- name: Publish to PyPI - on tag
|
|
180
|
+
if: startsWith(github.ref, 'refs/tags/')
|
|
181
|
+
uses: pypa/gh-action-pypi-publish@release/v1
|
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
apidocs
|
|
2
|
+
|
|
3
|
+
*.py[cod]
|
|
4
|
+
|
|
5
|
+
# C extensions
|
|
6
|
+
*.so
|
|
7
|
+
|
|
8
|
+
# Packages
|
|
9
|
+
*.egg
|
|
10
|
+
*.egg-info
|
|
11
|
+
dist
|
|
12
|
+
build
|
|
13
|
+
eggs
|
|
14
|
+
parts
|
|
15
|
+
bin
|
|
16
|
+
var
|
|
17
|
+
sdist
|
|
18
|
+
develop-eggs
|
|
19
|
+
.installed.cfg
|
|
20
|
+
lib
|
|
21
|
+
lib64
|
|
22
|
+
|
|
23
|
+
# Installer logs
|
|
24
|
+
pip-log.txt
|
|
25
|
+
|
|
26
|
+
# Unit test / coverage reports
|
|
27
|
+
.coverage
|
|
28
|
+
.tox
|
|
29
|
+
htmlcov
|
|
30
|
+
#tox.ini
|
|
31
|
+
#nosetests.xml
|
|
32
|
+
|
|
33
|
+
# Translations
|
|
34
|
+
*.mo
|
|
35
|
+
|
|
36
|
+
# Mr Developer
|
|
37
|
+
.mr.developer.cfg
|
|
38
|
+
.project
|
|
39
|
+
.pydevproject
|
|
40
|
+
|
|
41
|
+
# Complexity
|
|
42
|
+
output/*.html
|
|
43
|
+
output/*/index.html
|
|
44
|
+
|
|
45
|
+
# Sphinx
|
|
46
|
+
docs/_build
|
|
47
|
+
|
|
48
|
+
# IDEs
|
|
49
|
+
.idea
|
|
50
|
+
.claude
|
|
51
|
+
|
|
52
|
+
.eggs/
|
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
Contributing to ConfigArgParse
|
|
2
|
+
------------------------------
|
|
3
|
+
|
|
4
|
+
What you can do
|
|
5
|
+
~~~~~~~~~~~~~~~
|
|
6
|
+
|
|
7
|
+
If you like the project and think you could help with making it better, there are many ways you can do it:
|
|
8
|
+
|
|
9
|
+
- Create an issue to report a bug or suggest a new feature
|
|
10
|
+
- Triage old issues that need a refresh
|
|
11
|
+
- Implement fixes for existing issues
|
|
12
|
+
- Help with improving the documentation
|
|
13
|
+
- Spread the word about the project to your colleagues, friends, blogs or any other channels
|
|
14
|
+
- Any other things you could imagine
|
|
15
|
+
|
|
16
|
+
Any contribution would be of great help and we'll highly appreciate it!
|
|
17
|
+
If you have any questions, please create a new issue.
|
|
18
|
+
|
|
19
|
+
Development process
|
|
20
|
+
~~~~~~~~~~~~~~~~~~~
|
|
21
|
+
|
|
22
|
+
Create a fork of the git repository and checkout a new branch from master branch.
|
|
23
|
+
The branch name may start with an associated issue number so that we can easily cross-reference them.
|
|
24
|
+
For example, use ``1234-some-brach-name`` as the name of the branch working to fix issue 1234.
|
|
25
|
+
Once your changes are ready and are passing the automated tests, open a pull request.
|
|
26
|
+
|
|
27
|
+
Don’t forget to sync your fork once in a while to work from the latest revision.
|
|
28
|
+
|
|
29
|
+
Pre-commit checks
|
|
30
|
+
~~~~~~~~~~~~~~~~~
|
|
31
|
+
|
|
32
|
+
- Run unit tests: ``pytest``.
|
|
33
|
+
|
|
34
|
+
Review process
|
|
35
|
+
~~~~~~~~~~~~~~
|
|
36
|
+
|
|
37
|
+
- Code changes and code added should have tests: untested code is buggy code and should
|
|
38
|
+
not be accepted by reviewers.
|
|
39
|
+
- All code changes must be reviewed by at least one maintainer who is not an author
|
|
40
|
+
of the code being added.
|
|
41
|
+
- When a reviewer completes a review, they should always say what the next step(s) should be:
|
|
42
|
+
- Ok we can merge the patch as is
|
|
43
|
+
- Some optional changes requested
|
|
44
|
+
- Some required changes are requested
|
|
45
|
+
- An issue should be opened to tackle another problem discovered during the coding process.
|
|
46
|
+
- If a substantial change is pushed after a review, a follow-up review should be done.
|
|
47
|
+
Small changes and nit-picks do not required follow-up reviews.
|
|
48
|
+
|
|
49
|
+
Release process
|
|
50
|
+
~~~~~~~~~~~~~~~
|
|
51
|
+
|
|
52
|
+
The following is a high level overview and might not match the current state of things.
|
|
53
|
+
|
|
54
|
+
- Edit setup.py to update the version number and create a PR with this change (suggested branch name format: ``release-1.5.1``)
|
|
55
|
+
- Once that PR is approved and merged, the *owner* should push a new tag with the same name as the version i.e. ``1.5.1`` by running `git pull; git tag 1.5.1; git push --tags`.
|
|
56
|
+
This will trigger the PyPi release process. Monitor the process in the GitHub action UI...
|
|
57
|
+
|
|
58
|
+
---
|
|
59
|
+
|
|
60
|
+
owner: people with administrative rights on the repo, only they are able to push a new tag.
|
|
61
|
+
maintainers: people with push rights, they can merge PR if the requirements are met.
|