Merge branch 'master' of github.com:mongodb/mongo-python-driver
This commit is contained in:
commit
9f40142e7d
1
.github/workflows/codeql.yml
vendored
1
.github/workflows/codeql.yml
vendored
@ -39,6 +39,7 @@ jobs:
|
||||
uses: actions/checkout@v4
|
||||
with:
|
||||
ref: ${{ inputs.ref }}
|
||||
persist-credentials: false
|
||||
- uses: actions/setup-python@v5
|
||||
|
||||
# Initializes the CodeQL tools for scanning.
|
||||
|
||||
2
.github/workflows/dist.yml
vendored
2
.github/workflows/dist.yml
vendored
@ -48,6 +48,7 @@ jobs:
|
||||
uses: actions/checkout@v4
|
||||
with:
|
||||
fetch-depth: 0
|
||||
persist-credentials: false
|
||||
ref: ${{ inputs.ref }}
|
||||
|
||||
- uses: actions/setup-python@v5
|
||||
@ -106,6 +107,7 @@ jobs:
|
||||
- uses: actions/checkout@v4
|
||||
with:
|
||||
fetch-depth: 0
|
||||
persist-credentials: false
|
||||
ref: ${{ inputs.ref }}
|
||||
|
||||
- uses: actions/setup-python@v5
|
||||
|
||||
14
.github/workflows/test-python.yml
vendored
14
.github/workflows/test-python.yml
vendored
@ -20,6 +20,8 @@ jobs:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
with:
|
||||
persist-credentials: false
|
||||
- uses: actions/setup-python@v5
|
||||
with:
|
||||
python-version: "3.9"
|
||||
@ -55,6 +57,8 @@ jobs:
|
||||
name: CPython ${{ matrix.python-version }}-${{ matrix.os }}
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
with:
|
||||
persist-credentials: false
|
||||
- if: ${{ matrix.python-version == '3.13t' }}
|
||||
name: Setup free-threaded Python
|
||||
uses: deadsnakes/action@v3.2.0
|
||||
@ -99,6 +103,8 @@ jobs:
|
||||
name: DocTest
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
with:
|
||||
persist-credentials: false
|
||||
- name: Setup Python
|
||||
uses: actions/setup-python@v5
|
||||
with:
|
||||
@ -121,6 +127,8 @@ jobs:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
with:
|
||||
persist-credentials: false
|
||||
- uses: actions/setup-python@v5
|
||||
with:
|
||||
cache: 'pip'
|
||||
@ -139,6 +147,8 @@ jobs:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
with:
|
||||
persist-credentials: false
|
||||
- uses: actions/setup-python@v5
|
||||
with:
|
||||
cache: 'pip'
|
||||
@ -160,6 +170,8 @@ jobs:
|
||||
python: ["3.9", "3.11"]
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
with:
|
||||
persist-credentials: false
|
||||
- uses: actions/setup-python@v5
|
||||
with:
|
||||
python-version: "${{matrix.python}}"
|
||||
@ -177,6 +189,8 @@ jobs:
|
||||
name: "Make an sdist"
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
with:
|
||||
persist-credentials: false
|
||||
- uses: actions/setup-python@v5
|
||||
with:
|
||||
cache: 'pip'
|
||||
|
||||
32
.github/workflows/zizmor.yml
vendored
Normal file
32
.github/workflows/zizmor.yml
vendored
Normal file
@ -0,0 +1,32 @@
|
||||
name: GitHub Actions Security Analysis with zizmor 🌈
|
||||
|
||||
on:
|
||||
push:
|
||||
branches: ["master"]
|
||||
pull_request:
|
||||
branches: ["**"]
|
||||
|
||||
jobs:
|
||||
zizmor:
|
||||
name: zizmor latest via Cargo
|
||||
runs-on: ubuntu-latest
|
||||
permissions:
|
||||
security-events: write
|
||||
steps:
|
||||
- name: Checkout repository
|
||||
uses: actions/checkout@v4
|
||||
with:
|
||||
persist-credentials: false
|
||||
- name: Setup Rust
|
||||
uses: actions-rust-lang/setup-rust-toolchain@v1
|
||||
- name: Get zizmor
|
||||
run: cargo install zizmor
|
||||
- name: Run zizmor 🌈
|
||||
run: zizmor --format sarif . > results.sarif
|
||||
env:
|
||||
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
- name: Upload SARIF file
|
||||
uses: github/codeql-action/upload-sarif@v3
|
||||
with:
|
||||
sarif_file: results.sarif
|
||||
category: zizmor
|
||||
@ -88,6 +88,7 @@ TEXT = "text"
|
||||
|
||||
from pymongo import _csot
|
||||
from pymongo._version import __version__, get_version_string, version_tuple
|
||||
from pymongo.asynchronous.mongo_client import AsyncMongoClient
|
||||
from pymongo.common import MAX_SUPPORTED_WIRE_VERSION, MIN_SUPPORTED_WIRE_VERSION, has_c
|
||||
from pymongo.cursor import CursorType
|
||||
from pymongo.operations import (
|
||||
@ -104,14 +105,6 @@ from pymongo.synchronous.collection import ReturnDocument
|
||||
from pymongo.synchronous.mongo_client import MongoClient
|
||||
from pymongo.write_concern import WriteConcern
|
||||
|
||||
try:
|
||||
from pymongo.asynchronous.mongo_client import AsyncMongoClient
|
||||
except Exception as e:
|
||||
# PYTHON-4781: Importing asyncio can fail on Windows.
|
||||
import warnings as _warnings
|
||||
|
||||
_warnings.warn(f"Failed to import Async PyMongo: {e!r}", ImportWarning, stacklevel=2)
|
||||
|
||||
version = __version__
|
||||
"""Current version of PyMongo."""
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user