Skip to content

Commit 0ead344

Browse files
sanathkrjfuss
authored andcommitted
Allow minor version upgrades for package requirements (#422)
* Allow minor version upgrades for package requirements According to [PEP440](https://www.python.org/dev/peps/pep-0440/#compatible-release), `~=` operator will do setup a prefix matching of the last version number. So `pkg~=1.1.0` will allow only patch version upgrades, while `pkg~=1.1` will allow all minor version upgrades while preventing major version changes ie. 2.x This was my intention with an earlier commit but unfortunately I missed the fine print in PEP440. This is especially important for boto3 because of how often they release. Users that have any version of v1.5<=boto3<v2.0 should be compatible with SAM Translator. SAM Translator uses boto3 only to query the default region configured in their shell. Being compatible with patch and minor versions allows SAM Translator to be installable in computers that have any relatively recent (> Dec 2017) version of AWS CLI. Without this change, SAM Translator cannot be run on computers with a more recent version of AWS CLI installation that bundles a recent version of boto3. This is a good practice in general to allow for easy deployment of security changes as recommended by [PEP404](https://www.python.org/dev/peps/pep-0440/#version-matching) * Bumping to v1.5.4 to prep for release
1 parent b193ec1 commit 0ead344

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

requirements/base.txt

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
boto3~=1.5.0
2-
enum34~=1.1.6
3-
jsonschema~=2.6.0
4-
six~=1.11.0
1+
boto3~=1.5
2+
enum34~=1.1
3+
jsonschema~=2.6
4+
six~=1.11
55

samtranslator/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
__version__ = '1.5.3'
1+
__version__ = '1.5.4'

0 commit comments

Comments
 (0)