Skip to content

Upgrade vulnerable dependencies and require Python 3.10+ - #671

Closed
Aasav Badera (aasavbadera) wants to merge 1 commit into
Azure:masterfrom
aasavbadera:aasavbadera/python-sdk-package-security-upgrades
Closed

Aasav Badera (aasavbadera) wants to merge 1 commit into
Azure:masterfrom
aasavbadera:aasavbadera/python-sdk-package-security-upgrades

Conversation

@aasavbadera

Copy link
Copy Markdown
Collaborator

Changed

  • Breaking: require Python 3.10 or newer. Patched aiohttp, requests, urllib3, OpenTelemetry, and pytest releases no longer support Python 3.9. Update workspace/package metadata, classifiers, CI, release automation, and documentation together.
  • Refresh the lockfile with patched dependencies, keeping the OpenTelemetry SDK and Azure Monitor exporter aligned:
Dependency Updated version
aiohttp 3.14.5
cryptography 50.0.2
opentelemetry-api / opentelemetry-sdk 1.45.2
pytest 9.2.0
requests 2.34.2
urllib3 2.8.0
azure-monitor-opentelemetry-exporter 1.0.0b59

Fixed

  • Raise the published requests and optional aiohttp minimums to patched releases.
  • Align standalone quick-start requirements with the workspace, replacing the vulnerable tqdm~=4.64.0 range with tqdm~=4.67.1 and updating the OpenTelemetry requirements.
  • Use aiohttp's ClientTimeout while preserving existing default and per-request timeout values.
  • Supply aiohttp's new stream-writer argument through a shared test-only response fixture because the released aioresponses version does not yet support it. Keep urllib3's existing socket-option behavior with narrowly scoped annotations for its nested ClassVar/Final typing issue.

Validation

  • Python 3.10 and 3.13: 292 passed, 26 skipped on each, excluding service-backed E2E suites.
  • Ruff formatting and lint checks passed.
  • basedpyright --level error passed.
  • uv build --all-packages produced both SDK wheels and source distributions; built package metadata requires Python 3.10.
  • uv pip check passed in both environments.
  • Verified updated locked versions against the affected advisory ranges and checked quick-start tracing initialization.

Service-backed E2E tests were not run locally.

Refresh targeted dependency versions, align quick-start requirements, and preserve HTTP client behavior with updated dependency APIs.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Copilot-Session: 6c5b6723-4f79-4478-872c-95f1d12e2653
@aasavbadera

Copy link
Copy Markdown
Collaborator Author

Superseded by #672 . The replacement uses branch aasavbadera/python-sdk-package-security-upgrades directly in Azure/azure-kusto-python, targeting master, with the same validated commit and unchanged implementation.

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.

1 participant