Skip to content

Commit e251ddd

Browse files
authored
DE-1038: PEP 484 enabled (#109)
* Add .editorconfig for teamwork * Add type hints * Fix version, add tests * Fix __all__ in the mailjet_rest module * Add, fix, and improve type hints; add py.typed; add packaging stuff to pyproject.toml, enhance & improve .gitignore * Fix import * Fix package-data * Add type hints to tests * Remove unused type ignore, add mypy configs, improve type hints with checking by mypy --strict * Fix the sample module's import * Ignore type errors * Set allow_redefinition to false * Exclude samples * Add bandit to pre-commit hooks * Formatting * Add toml for bandit * Add pyright type checker with initial settings, and with the pre-comit hook * Add typos spelling checker with the pre-commit hook * Update pre-commit hooks
1 parent 5872369 commit e251ddd

27 files changed

+725
-211
lines changed

.editorconfig

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
# http://editorconfig.org
2+
3+
root = true
4+
5+
[*]
6+
indent_style = space
7+
indent_size = 4
8+
trim_trailing_whitespace = true
9+
insert_final_newline = true
10+
charset = utf-8
11+
end_of_line = lf
12+
13+
[*.md]
14+
trim_trailing_whitespace = false
15+
16+
[*.bat]
17+
indent_style = tab
18+
end_of_line = crlf
19+
20+
[LICENSE]
21+
insert_final_newline = false
22+
23+
[Makefile]
24+
indent_style = tab
25+
trim_trailing_whitespace = false
26+
27+
[*.{yaml,yml}]
28+
indent_size = 2

.github/dependabot.yml

Lines changed: 9 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,11 @@
1+
---
12
version: 2
23
updates:
3-
- package-ecosystem: pip
4-
directory: "/"
5-
schedule:
6-
interval: "weekly"
7-
groups:
8-
python-packages:
9-
patterns:
10-
- "*"
4+
- package-ecosystem: pip
5+
directory: "/"
6+
schedule:
7+
interval: "weekly"
8+
groups:
9+
python-packages:
10+
patterns:
11+
- "*"

.github/workflows/commit_checks.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
---
12
name: CI
23

34
on:

.gitignore

Lines changed: 220 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,158 @@
1+
# Generic
2+
__pycache__
3+
__pycache__/
4+
__pypackages__/
5+
!.elasticbeanstalk/*.cfg.yml
6+
!.elasticbeanstalk/*.global.yml
7+
../../../mentor/kupriienko/airtable-notify/.env
8+
.anvil/*
9+
.cache
10+
.eggs/
11+
.elasticbeanstalk/*
12+
.env
13+
.env-mysql
14+
.history
15+
.hypothesis/
16+
.installed.cfg
17+
.ipynb_checkpoints
18+
.mr.developer.cfg
19+
.nox/
20+
.pdm.toml
21+
.prof
22+
.project
23+
.pybuilder/
24+
.pydevproject
25+
.pyre/
26+
.Python
27+
.python-version
28+
.pytype/
29+
.ropeproject
30+
.scrapy
31+
.spyderproject
32+
.spyproject
33+
.tox
34+
.tox/
35+
.vagrant/
36+
.venv
37+
.webassets-cache
38+
*.code-workspace
39+
*.cover
40+
*.egg
41+
*.egg-info/
42+
*.gz
43+
*.iml
44+
*.iws
45+
*.lock
46+
*.log
47+
*.manifest
48+
*.mo
49+
*.pot
50+
*.py,cover
51+
*.py[cod]
52+
*.pyc
53+
*.rar
54+
*.sage.py
55+
*.so
56+
*.spec
57+
*.sqlite
58+
*.zip
59+
**/__pycache__/*.pyc
60+
**/.idea/dataSources.ids
61+
**/.idea/dataSources.local.xml
62+
**/.idea/dataSources.xml
63+
**/.idea/dictionaries
64+
**/.idea/dynamic.xml
65+
**/.idea/jsLibraryMappings.xml
66+
**/.idea/sqlDataSources.xml
67+
**/.idea/tasks.xml
68+
**/.idea/uiDesigner.xml
69+
**/.idea/vcs.xml
70+
**/.idea/workspace.xml
71+
**/staticfiles/
72+
*/__pycache__/
73+
*/__pycache__/*.pyc
74+
*/*/__pycache__/
75+
*/*/*/__pycache__/
76+
*/staticfiles/
77+
*$py.class
78+
/bin
79+
/include
80+
/lib
81+
/out/
82+
/site
83+
/src
84+
85+
atlassian-ide-plugin.xml
86+
bin
87+
build
88+
build/
89+
celerybeat-schedule
90+
celerybeat.pid
91+
cmake-build-*/
92+
com_crashlytics_export_strings.xml
93+
crashlytics-build.properties
94+
crashlytics.properties
95+
cython_debug/
96+
db.sqlite3
97+
db.sqlite3-journal
98+
develop-eggs
99+
develop-eggs/
100+
dist
101+
dist/
102+
docs/_build/
103+
downloads/
104+
eggs
105+
eggs/
106+
env.bak/
107+
env/
108+
ENV/
109+
fabric.properties
110+
htmlcov/
111+
instance/
112+
ipython_config.py
113+
lib
114+
lib/
115+
lib64
116+
lib64/
117+
local_settings.py
118+
MANIFEST
119+
media
120+
myvenv
121+
node_modules
122+
node_modules/
123+
nosetests.xml
124+
parts
125+
parts/
126+
pip-delete-this-directory.txt
127+
pip-log.txt
128+
pip-wheel-metadata/
129+
poetry.toml
130+
profile_default/
131+
projects/static/
132+
pyrightconfig.json
133+
pythonenv*
134+
sdist
135+
sdist/
136+
secret_key.txt
137+
share/python-wheels/
138+
static/build/
139+
static/local/
140+
static/media
141+
static/rev-manifest.json
142+
staticfiles/
143+
target/
144+
tdd
145+
temp/
146+
Thumbs.db
147+
tmp/
148+
uploads/
149+
var
150+
var/
151+
venv
152+
venv.bak/
153+
venv/
154+
wheels/
155+
1156
*~
2157
\#*\#
3158
/.emacs.desktop
@@ -8,27 +163,74 @@ tramp
8163
.\#*
9164

10165
.projectile
11-
.ropeproject
12-
.env
13166
.overcommit.yml
14167

15-
__pycache__/
16-
*.py[cod]
17-
*.so
18-
*.egg-info/
19-
.installed.cfg
20-
*.egg
21-
22-
pip-log.txt
23-
pip-delete-this-directory.txt
168+
junit*
24169

25-
.tox/
170+
# Coverage Files
171+
htmlcov
172+
cover/
173+
.coverage.*
26174
.coverage
27-
.cache
28-
nosetests.xml
175+
.coverage*
29176
coverage.xml
30-
junit*
31-
build/
32-
dist/
33-
venv/
177+
178+
# IDEs
34179
.idea/
180+
.idea_modules/
181+
.idea/*
182+
.idea/*.iml
183+
.idea/**/contentModel.xml
184+
.idea/**/dataSources.ids
185+
.idea/**/dataSources.local.xml
186+
.idea/**/dataSources/
187+
.idea/**/dbnavigator.xml
188+
.idea/**/dictionaries
189+
.idea/**/dynamic.xml
190+
.idea/**/gradle.xml
191+
.idea/**/libraries
192+
.idea/**/mongoSettings.xml
193+
.idea/**/shelf
194+
.idea/**/sqlDataSources.xml
195+
.idea/**/tasks.xml
196+
.idea/**/uiDesigner.xml
197+
.idea/**/usage.statistics.xml
198+
.idea/**/workspace.xml
199+
.idea/caches/build_file_checksums.ser
200+
.idea/dataSources.ids
201+
.idea/dataSources.local.xml
202+
.idea/dataSources.xml
203+
.idea/dictionaries
204+
.idea/dynamic.xml
205+
.idea/gradle.xml
206+
.idea/httpRequests
207+
.idea/jsLibraryMappings.xml
208+
.idea/libraries
209+
.idea/modules
210+
.idea/modules.xml
211+
.idea/mongoSettings.xml
212+
.idea/replstate.xml
213+
.idea/sqlDataSources.xml
214+
.idea/tasks.xml
215+
.idea/uiDesigner.xml
216+
.idea/vcs.xml
217+
.idea/workspace.xml
218+
# VS Code
219+
.vscode/
220+
# pycharm
221+
queue.json
222+
dev/
223+
224+
# Operating Systems
225+
.DS_Store
226+
227+
# ruff cache
228+
.ruff_cache/
229+
230+
# mypy cache
231+
.dmypy.json
232+
.mypy_cache/
233+
234+
# pytest cache
235+
.pytest_cache/
236+
pytestdebug.log

0 commit comments

Comments
 (0)