Skip to content

Commit d07301e

Browse files
committed
Merge branch 'master' of github.com:mongodb/mongo-python-driver
2 parents d406616 + c77c15e commit d07301e

File tree

11 files changed

+50
-4
lines changed

11 files changed

+50
-4
lines changed

.evergreen/generated_configs/tasks.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -128,6 +128,10 @@ tasks:
128128
- mongo-python-driver
129129
- ${github_commit}
130130
working_dir: src
131+
include_expansions_in_env:
132+
- AWS_ACCESS_KEY_ID
133+
- AWS_SECRET_ACCESS_KEY
134+
- AWS_SESSION_TOKEN
131135
type: test
132136

133137
# Coverage report tests

.evergreen/scripts/generate_config.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -896,7 +896,8 @@ def create_backport_pr_tasks():
896896
"mongo-python-driver",
897897
"${github_commit}",
898898
]
899-
cmd = get_subprocess_exec(args=args)
899+
include_expansions = ["AWS_ACCESS_KEY_ID", "AWS_SECRET_ACCESS_KEY", "AWS_SESSION_TOKEN"]
900+
cmd = get_subprocess_exec(args=args, include_expansions_in_env=include_expansions)
900901
assume_func = FunctionCall(func="assume ec2 role")
901902
return [EvgTask(name=name, commands=[assume_func, cmd], allowed_requesters=["commit"])]
902903

.evergreen/scripts/setup-system.sh

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,4 +38,14 @@ if [ "$(uname -s)" = "Darwin" ]; then
3838
fi
3939
fi
4040

41+
if [ -w /etc/hosts ]; then
42+
SUDO=""
43+
else
44+
SUDO="sudo"
45+
fi
46+
47+
# Add 'server' and 'hostname_not_in_cert' as a hostnames
48+
echo "127.0.0.1 server" | $SUDO tee -a /etc/hosts
49+
echo "127.0.0.1 hostname_not_in_cert" | $SUDO tee -a /etc/hosts
50+
4151
echo "Setting up system... done."

.github/workflows/codeql.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ jobs:
4646

4747
# Initializes the CodeQL tools for scanning.
4848
- name: Initialize CodeQL
49-
uses: github/codeql-action/init@39edc492dbe16b1465b0cafca41432d857bdb31a # v3
49+
uses: github/codeql-action/init@181d5eefc20863364f96762470ba6f862bdef56b # v3
5050
with:
5151
languages: ${{ matrix.language }}
5252
build-mode: ${{ matrix.build-mode }}
@@ -63,6 +63,6 @@ jobs:
6363
pip install -e .
6464
6565
- name: Perform CodeQL Analysis
66-
uses: github/codeql-action/analyze@39edc492dbe16b1465b0cafca41432d857bdb31a # v3
66+
uses: github/codeql-action/analyze@181d5eefc20863364f96762470ba6f862bdef56b # v3
6767
with:
6868
category: "/language:${{matrix.language}}"

.github/workflows/zizmor.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,4 +18,4 @@ jobs:
1818
with:
1919
persist-credentials: false
2020
- name: Run zizmor 🌈
21-
uses: zizmorcore/zizmor-action@1c7106082dbc1753372e3924b7da1b9417011a21
21+
uses: zizmorcore/zizmor-action@0f0557ab4a0b31211d42435e42df31cbd63fdd59

doc/changelog.rst

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@ PyMongo 4.14 brings a number of changes including:
1313

1414
- Introduces a minor breaking change. When encoding :class:`bson.binary.BinaryVector`, a ``ValueError`` will be raised
1515
if the 'padding' metadata field is < 0 or > 7, or non-zero for any type other than PACKED_BIT.
16+
- Changed :meth:`~pymongo.uri_parser.parse_uri`'s ``options`` parameter to be type ``dict`` instead of ``_CaseInsensitiveDictionary``.
1617

1718
Changes in Version 4.13.2 (2025/06/17)
1819
--------------------------------------

pymongo/asynchronous/uri_parser.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -80,6 +80,9 @@ async def parse_uri(
8080
wait for a response from the DNS server.
8181
:param srv_service_name: A custom SRV service name
8282
83+
.. versionchanged:: 4.14
84+
``options`` is now type ``dict`` as opposed to a ``_CaseInsensitiveDictionary``.
85+
8386
.. versionchanged:: 4.6
8487
The delimiting slash (``/``) between hosts and connection options is now optional.
8588
For example, "mongodb://example.com?tls=true" is now a valid URI.

pymongo/synchronous/uri_parser.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -80,6 +80,9 @@ def parse_uri(
8080
wait for a response from the DNS server.
8181
:param srv_service_name: A custom SRV service name
8282
83+
.. versionchanged:: 4.14
84+
``options`` is now type ``dict`` as opposed to a ``_CaseInsensitiveDictionary``.
85+
8386
.. versionchanged:: 4.6
8487
The delimiting slash (``/``) between hosts and connection options is now optional.
8588
For example, "mongodb://example.com?tls=true" is now a valid URI.

test/asynchronous/test_ssl.py

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -304,8 +304,13 @@ async def test_cert_ssl_uri_support(self):
304304
client = self.simple_client(uri_fmt % (CLIENT_PEM, "true", CA_PEM))
305305
await self.assertClientWorks(client)
306306

307+
@unittest.skipIf(
308+
"PyPy" in sys.version and not _IS_SYNC,
309+
"https://github.com/pypy/pypy/issues/5131 flaky on async PyPy due to SSL EOF",
310+
)
307311
@async_client_context.require_tlsCertificateKeyFile
308312
@async_client_context.require_server_resolvable
313+
@async_client_context.require_no_api_version
309314
@ignore_deprecations
310315
async def test_cert_ssl_validation_hostname_matching(self):
311316
# Expects the server to be running with server.pem and ca.pem
@@ -430,8 +435,13 @@ async def test_tlsCRLFile_support(self):
430435
self.simple_client(uri_fmt % (CRL_PEM, CA_PEM), **self.credentials) # type: ignore[arg-type]
431436
)
432437

438+
@unittest.skipIf(
439+
"PyPy" in sys.version and not _IS_SYNC,
440+
"https://github.com/pypy/pypy/issues/5131 flaky on async PyPy due to SSL EOF",
441+
)
433442
@async_client_context.require_tlsCertificateKeyFile
434443
@async_client_context.require_server_resolvable
444+
@async_client_context.require_no_api_version
435445
@ignore_deprecations
436446
async def test_validation_with_system_ca_certs(self):
437447
# Expects the server to be running with server.pem and ca.pem.

test/test_ssl.py

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -304,8 +304,13 @@ def test_cert_ssl_uri_support(self):
304304
client = self.simple_client(uri_fmt % (CLIENT_PEM, "true", CA_PEM))
305305
self.assertClientWorks(client)
306306

307+
@unittest.skipIf(
308+
"PyPy" in sys.version and not _IS_SYNC,
309+
"https://github.com/pypy/pypy/issues/5131 flaky on async PyPy due to SSL EOF",
310+
)
307311
@client_context.require_tlsCertificateKeyFile
308312
@client_context.require_server_resolvable
313+
@client_context.require_no_api_version
309314
@ignore_deprecations
310315
def test_cert_ssl_validation_hostname_matching(self):
311316
# Expects the server to be running with server.pem and ca.pem
@@ -430,8 +435,13 @@ def test_tlsCRLFile_support(self):
430435
self.simple_client(uri_fmt % (CRL_PEM, CA_PEM), **self.credentials) # type: ignore[arg-type]
431436
)
432437

438+
@unittest.skipIf(
439+
"PyPy" in sys.version and not _IS_SYNC,
440+
"https://github.com/pypy/pypy/issues/5131 flaky on async PyPy due to SSL EOF",
441+
)
433442
@client_context.require_tlsCertificateKeyFile
434443
@client_context.require_server_resolvable
444+
@client_context.require_no_api_version
435445
@ignore_deprecations
436446
def test_validation_with_system_ca_certs(self):
437447
# Expects the server to be running with server.pem and ca.pem.

0 commit comments

Comments
 (0)