Skip to content

DRIVERS-2743 skip Python 3.12#359

Merged
kevinAlbs merged 2 commits intomongodb-labs:masterfrom
kevinAlbs:pykmip_failure
Oct 4, 2023
Merged

DRIVERS-2743 skip Python 3.12#359
kevinAlbs merged 2 commits intomongodb-labs:masterfrom
kevinAlbs:pykmip_failure

Conversation

@kevinAlbs
Copy link
Copy Markdown
Contributor

@kevinAlbs kevinAlbs commented Oct 4, 2023

Summary

  • Skip Python version 3.12 when selecting Python

PR was tested by modifying the C driver config to test an Ubuntu 20.04 variant:

Many C driver tasks use Ubuntu 18.04, which does not appear affected (Ubuntu 18.04 reports Python 3.11.4)

Background & Motivation

Test failures are reported by multiple driver teams starting the mock KMIP server. Example failures in Node and Java include the tracebacks:

Traceback (most recent call last):
  File "/data/mci/874b423f0400c073b8557a88f0546518/drivers-evergreen-tools/.evergreen/csfle/kms_kmip_server.py", line 52, in <module>
    main()
  File "/data/mci/874b423f0400c073b8557a88f0546518/drivers-evergreen-tools/.evergreen/csfle/kms_kmip_server.py", line 46, in main
    with server:
  File "/data/mci/874b423f0400c073b8557a88f0546518/drivers-evergreen-tools/.evergreen/csfle/kmstlsvenv/lib/python3.12/site-packages/kmip/services/server/server.py", line 475, in __enter__
    self.start()
  File "/data/mci/874b423f0400c073b8557a88f0546518/drivers-evergreen-tools/.evergreen/csfle/kmstlsvenv/lib/python3.12/site-packages/kmip/services/server/server.py", line 290, in start
    self._socket = ssl.wrap_socket(
                   ^^^^^^^^^^^^^^^

Python 3.12 removed ssl.wrap_socket:

Remove the ssl.wrap_socket() function

PyKMIP uses ssl.wrap_socket(). kms_http_common.py uses ssl.wrap_socket()

This is intended as a short term fix to unblock driver testing.

@kevinAlbs kevinAlbs requested a review from blink1073 October 4, 2023 17:05
@kevinAlbs kevinAlbs marked this pull request as ready for review October 4, 2023 17:05
Copy link
Copy Markdown
Member

@blink1073 blink1073 left a comment

Choose a reason for hiding this comment

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

Thank you!

Not necessary. But consistent with function returns.
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

Successfully merging this pull request may close these issues.

2 participants