Update the cryptography python package for Python 3.5 and above. Fixes #6033

This commit is contained in:
Aditya Toshniwal 2020-11-26 11:43:08 +05:30 committed by Akshay Joshi
parent a2f4628590
commit 55e50144f3
3 changed files with 17 additions and 5 deletions

View File

@ -14,6 +14,7 @@ Housekeeping
************
| `Issue #5337 <https://redmine.postgresql.org/issues/5337>`_ - Improve code coverage and API test cases for Views and Materialized Views.
| `Issue #6033 <https://redmine.postgresql.org/issues/6033>`_ - Update the cryptography python package for Python 3.5 and above.
Bug fixes
*********

View File

@ -32,18 +32,26 @@ builtins.SERVER_MODE = None
req_file = '../requirements.txt'
with open(req_file, 'r') as req_lines:
requires = req_lines.read().splitlines()
all_requires = req_lines.read().splitlines()
requires = []
extras_require = {}
# Remove any requirements with environment specifiers. These
# must be explicitly listed in extras_require below.
for index, req in enumerate(requires):
for index, req in enumerate(all_requires):
if ";" in req or req.startswith("#") or req == "":
requires.remove(req)
# Add the pkgs to extras_require
if ";" in req:
pkg, env_spec = req.split(";")
extras_require[env_spec] = extras_require.get(env_spec, [])
extras_require[env_spec].append(pkg)
continue
# Ensure the Wheel will use psycopg2-binary, not the source distro
if 'psycopg2' in req:
requires[index] = req.replace('psycopg2', 'psycopg2-binary')
req = req.replace('psycopg2', 'psycopg2-binary')
requires.append(req)
# Get the version
config = load_source('APP_VERSION', '../web/config.py')
@ -84,6 +92,8 @@ setup(
install_requires=requires,
extras_require=extras_require,
entry_points={
'console_scripts': ['pgadmin4=pgadmin4.pgAdmin4:main'],
},

View File

@ -39,6 +39,7 @@ python-dateutil>=2.8.0
SQLAlchemy>=1.3.13
Flask-Security-Too>=3.0.0
bcrypt<=3.1.7
cryptography<=3.0
cryptography<=3.0;python_version<="3.4"
cryptography>=3.2;python_version>"3.4"
sshtunnel>=0.1.5
ldap3>=2.5.1