This repository has been archived by the owner on Apr 10, 2023. It is now read-only.
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Drop Python 2 and Python 3.5 support
- Loading branch information
1 parent
7166274
commit 453b7e6
Showing
18 changed files
with
34 additions
and
183 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,3 @@ | ||
[bdist_wheel] | ||
universal = 1 | ||
|
||
[flake8] | ||
ignore = C408,W503 | ||
max-line-length = 100 | ||
per-file-ignores = | ||
tests/test_model_py36.py: E999 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,40 +1,4 @@ | ||
import os | ||
import sys | ||
|
||
import mock | ||
import six | ||
|
||
from serde import fields | ||
|
||
|
||
REPO_DIR = os.path.abspath(os.path.join(os.path.dirname(__file__), '..')) | ||
|
||
|
||
def py2_patch_str_with_basestring(f): | ||
def decorated_function(*args, **kwargs): | ||
if six.PY2: | ||
with mock.patch.dict( | ||
'serde.fields._FIELD_CLASS_MAP', {str: fields.BaseString} | ||
): | ||
return f(*args, **kwargs) | ||
return f(*args, **kwargs) | ||
|
||
return decorated_function | ||
|
||
|
||
def py3(f): | ||
def decorated_function(*args, **kwargs): | ||
if six.PY2: | ||
return | ||
return f(*args, **kwargs) | ||
|
||
return decorated_function | ||
|
||
|
||
def py36(f): | ||
def decorated_function(*args, **kwargs): | ||
if sys.version_info[:2] < (3, 6): | ||
return | ||
return f(*args, **kwargs) | ||
|
||
return decorated_function |
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.