Skip to content

fix(deps): Python-compatible CVE bumps for pyyaml and pytest (supersedes #48, #49) - #50

Merged
mitczach merged 1 commit into
mainfrom
fix/cve-bumps-py-compat
Jun 23, 2026
Merged

fix(deps): Python-compatible CVE bumps for pyyaml and pytest (supersedes #48, #49)#50
mitczach merged 1 commit into
mainfrom
fix/cve-bumps-py-compat

Conversation

@mitczach

Copy link
Copy Markdown
Collaborator

Summary

Supersedes Dependabot PRs #48 and #49, which bumped to versions that break this project's Python-version floors. This PR applies CVE-addressing bumps that respect those floors instead.

Background

Dependabot PR Problem This PR
#49 pyyaml 5.3.1 → 5.4 Fails to build on Python 3.10 (no cp310 wheel → sdist Cython error 'build_ext' object has no attribute 'cython_sources'). Re-run of #29, closed in 2023 for the same reason. Also rewrote poetry.lock to Poetry 2.x format. CVE-2020-14343 targets unsafe yaml.load(); this repo only uses yaml.safe_load. pyyaml ^6.0.1 — has cp310 wheels, supports the ^3.7 floor, addresses the alert.
#48 pytest 7.1.2 → 9.0.3 (pyspark template) pytest 9.x requires Python ≥ 3.10, but the template targets Python 3.7 (EMR 6.x / amazonlinux:2). Makes the scaffolded [tests] extra uninstallable. pytest ==7.4.4 — last line supporting Python 3.7.

Changes

  • pyproject.toml: pyyaml = "5.3.1""^6.0.1"
  • poetry.lock: regenerated with Poetry 1.5.1 (poetry lock --no-update); only pyyaml changed (5.3.1 → 6.0.1), lock-version 2.0 format preserved to match the pinned toolchain
  • src/emr_cli/templates/pyspark/pyproject.toml: pytest==7.1.27.4.4

Verification

  • pytest --cov emr_cli tests/17 passed on Python 3.9 and 3.10 (matching CI)
  • Empirically confirmed on fresh venvs: pyyaml 5.4/5.4.1 fail to build on 3.10, 6.0.1 installs; pytest 9.0.3 is unsatisfiable below 3.10, 7.4.4 declares Requires-Python >=3.7

Closes #48
Closes #49

Dependabot PRs #48 and #49 bumped to versions that break this project's
Python-version floors:

- #49 (pyyaml -> 5.4) fails to build on Python 3.10 (no cp310 wheel, sdist
  Cython error) and only addressed CVE-2020-14343, which targets unsafe
  yaml.load(); this repo only uses yaml.safe_load. Bump to pyyaml ^6.0.1
  instead (has cp310 wheels, fixes the CVE, supports the ^3.7 floor).
- #48 (pytest -> 9.0.3) requires Python >=3.10, but the pyspark template
  targets Python 3.7 (EMR 6.x / amazonlinux:2). Pin pytest==7.4.4, the last
  line supporting 3.7.

poetry.lock regenerated with Poetry 1.5.1 (lock-version 2.0 preserved).
Verified: pytest --cov emr_cli tests/ passes on Python 3.9 and 3.10.
@mitczach
mitczach force-pushed the fix/cve-bumps-py-compat branch from 9382ab4 to 0925c1e Compare June 23, 2026 17:41
@mitczach
mitczach merged commit e261183 into main Jun 23, 2026
9 checks passed
@mitczach
mitczach deleted the fix/cve-bumps-py-compat branch June 23, 2026 17:43
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