Skip to content
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

CI: Add support for Python 3.12 and 3.13 #545

Merged
merged 3 commits into from
Nov 12, 2024
Merged

CI: Add support for Python 3.12 and 3.13 #545

merged 3 commits into from
Nov 12, 2024

Conversation

amotl
Copy link
Member

@amotl amotl commented Nov 6, 2024

About

In tests.util.fake_cloud.FakeCrateDBCloudServer, ssl.wrap_socket() is no longer supported.

Stacking

That other PR needs to be merged first.

@cla-bot cla-bot bot added the cla-signed label Nov 6, 2024
@amotl amotl force-pushed the python312 branch 4 times, most recently from 03da8c5 to 068ddac Compare November 6, 2024 21:47
Comment on lines 51 to 63
here = pathlib.Path(__file__)
self.ssl_cert = here.parent / "server.crt"
ssl_key = here.parent / "server.key"
self.socket = ssl.wrap_socket( # type: ignore[attr-defined]

# Instances of SSLSocket must be created using the
# `SSLContext.wrap_socket()` method.
# https://docs.python.org/3.12/library/ssl.html#socket-creation
context = ssl.create_default_context()
context.check_hostname = False
context.load_cert_chain(certfile=str(self.ssl_cert), keyfile=str(ssl_key))

self.socket = context.wrap_socket( # type: ignore[attr-defined]
self.socket,
keyfile=str(ssl_key),
certfile=str(self.ssl_cert),
server_side=True,
)
Copy link
Member Author

@amotl amotl Nov 6, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The canonical rewrite of that spot failed.

More information:

Apparently, it doesn't work any longer without additional modifiations to the test suite, to make the FakeCrateDBCloudServer work well again. See CI outcome.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed per 28d838c.

@amotl amotl changed the title CI: Add support for Python 3.12 CI: Add support for Python 3.12 and 3.13 Nov 6, 2024
@amotl amotl marked this pull request as ready for review November 6, 2024 22:18
Copy link
Contributor

@plaharanne plaharanne left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍

Base automatically changed from modernize-2024 to master November 12, 2024 16:22
@amotl amotl merged commit 401f5ab into master Nov 12, 2024
13 checks passed
@amotl amotl deleted the python312 branch November 12, 2024 16:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants