Skip to content

Commit 69ee2fd

Browse files
authored
chore: pin linter dependencies (#198)
1 parent e323c96 commit 69ee2fd

File tree

12 files changed

+53
-30
lines changed

12 files changed

+53
-30
lines changed

.github/workflows/ci_tests.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ jobs:
3838
# - examples
3939
steps:
4040
- uses: actions/checkout@v2
41-
- uses: actions/setup-python@v1
41+
- uses: actions/setup-python@v2
4242
with:
4343
python-version: 2.7
4444
architecture: ${{ matrix.platform.architecture }}
@@ -79,7 +79,7 @@ jobs:
7979
# - examples
8080
steps:
8181
- uses: actions/checkout@v2
82-
- uses: actions/setup-python@v1
82+
- uses: actions/setup-python@v2
8383
with:
8484
python-version: ${{ matrix.python }}
8585
architecture: ${{ matrix.platform.architecture }}

codebuild/python2.7.yml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,5 +14,7 @@ phases:
1414
python: latest
1515
build:
1616
commands:
17-
- pip install tox
17+
- pyenv install 2.7.17
18+
- pyenv local 2.7.17
19+
- pip install tox tox-pyenv
1820
- tox

codebuild/python3.6.yml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,5 +14,7 @@ phases:
1414
python: latest
1515
build:
1616
commands:
17-
- pip install tox
17+
- pyenv install 3.6.15
18+
- pyenv local 3.6.15
19+
- pip install tox tox-pyenv
1820
- tox

codebuild/python3.8.yml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,5 +14,7 @@ phases:
1414
python: latest
1515
build:
1616
commands:
17-
- pip install tox
17+
- pyenv install 3.8.12
18+
- pyenv local 3.8.12
19+
- pip install tox tox-pyenv
1820
- tox
Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
bandit==1.7.0
2+
black==21.12b0
3+
doc8==0.10.1
4+
flake8==4.0.1
5+
flake8-bugbear==21.11.29
6+
flake8-docstrings==1.6.0
7+
flake8-isort==4.1.1
8+
flake8-print==4.0.0
9+
isort==5.10.1
10+
pydocstyle==3.0.0
11+
pyflakes==2.4.0
12+
pylint==2.12.2
13+
readme_renderer==32.0
14+
seed-isort-config==2.2.0
15+
vulture==2.3
16+
sphinx==4.4.0

doc/conf.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ def get_version():
2929
return _release
3030

3131

32-
project = u"dynamodb-encryption-sdk-python"
32+
project = u"dynamodb-encryption-sdk-python" # pylint: disable=redundant-u-string-prefix
3333
version = get_version()
3434
release = get_release()
3535

@@ -53,7 +53,7 @@ def get_version():
5353
source_suffix = ".rst" # The suffix of source filenames.
5454
master_doc = "index" # The master toctree document.
5555

56-
copyright = u"%s, Amazon" % datetime.now().year # pylint: disable=redefined-builtin
56+
copyright = u"%s, Amazon" % datetime.now().year # pylint: disable=redefined-builtin,redundant-u-string-prefix
5757

5858
# List of directories, relative to source directory, that shouldn't be searched
5959
# for source files.

examples/test/pylintrc

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@ disable =
1010
# pylint does not recognize this
1111
duplicate-code, # tests for similar things tend to be similar
1212
redefined-outer-name, # raises false positives with fixtures
13+
consider-using-f-string,
1314

1415
[DESIGN]
1516
max-args = 10

src/pylintrc

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ disable =
88
useless-object-inheritance,
99
raise-missing-from,
1010
super-with-arguments,
11+
consider-using-f-string
1112

1213
[BASIC]
1314
# Allow function names up to 50 characters

test/pylintrc

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,10 +10,13 @@ disable =
1010
protected-access, # raised when calling _ methods
1111
redefined-outer-name, # raised when using pytest-mock
1212
unused-argument, # raised when patches and fixtures are needed but not called
13+
unspecified-encoding,
1314
# All below are disabled because we need to support Python 2
1415
useless-object-inheritance,
1516
raise-missing-from,
1617
super-with-arguments,
18+
consider-using-f-string,
19+
redundant-u-string-prefix,
1720

1821
[DESIGN]
1922
max-args = 10

test/requirements.txt

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,10 @@
11
hypothesis>=5.0.0,<6.0.0;python_version>='3'
22
hypothesis==4.57.1;python_version=='2.7'
33
mock
4-
moto>=1.3.8
4+
moto>=1.3.8;python_version>='3'
5+
# must be less than 2.2.x as Moto removed support for python2 as of moto 2.2.x.
6+
# https://github.com/spulec/moto/issues/3612
7+
moto>=1.3.8,<2.2.0;python_version=='2.7'
58
pytest>=3.4.0
69
pytest-cov
710
pytest-mock

0 commit comments

Comments
 (0)