Skip to content

Deprecation updates for v1.3.1 #121

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
jwp opened this issue Feb 3, 2023 · 4 comments
Closed

Deprecation updates for v1.3.1 #121

jwp opened this issue Feb 3, 2023 · 4 comments

Comments

@jwp
Copy link
Contributor

jwp commented Feb 3, 2023

Looks like a SSLContext can just be initialized on the SocketFactory.

fe/postgresql/python/socket.py:59: DeprecationWarning: ssl.wrap_socket() is deprecated, use SSLContext.wrap_socket()
return ssl.wrap_socket(socket)
/Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/ssl.py:1438: DeprecationWarning: ssl.PROTOCOL_TLS is deprecated
context = SSLContext(ssl_version)

Also, pip is complaining:

DEPRECATION: py-postgresql is being installed using the legacy 'setup.py install' method, because it does not have a 'pyproject.toml' and the 'wheel' package is not installed. pip 23.1 will enforce this behaviour change. A possible replacement is to enable the '--use-pep517' option. Discussion can be found at pypa/pip#8559

@jwp
Copy link
Contributor Author

jwp commented Feb 5, 2023

Added pyproject.toml in dc07e2d

@jwp
Copy link
Contributor Author

jwp commented Feb 5, 2023

The SSL issue remind me of the poor parameter names. In v1.4, provide a better means for securing sockets: #122

@jwp
Copy link
Contributor Author

jwp commented Feb 10, 2023

Implemented extremely basic Context initialization: fb1ed35

@jwp
Copy link
Contributor Author

jwp commented Feb 10, 2023

While heeding these warnings, fix test_ssl_connect and test_connect by updating the test certificates, providing an updated trusted certificate file to SSLContext, and forcing password_encryption to md5:

@jwp jwp closed this as completed Feb 10, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant