Skip to content

Add lower bounds to the remaining runtime dependencies#106

Merged
JE-Chen merged 1 commit into
mainfrom
dev
Jul 23, 2026
Merged

Add lower bounds to the remaining runtime dependencies#106
JE-Chen merged 1 commit into
mainfrom
dev

Conversation

@JE-Chen

@JE-Chen JE-Chen commented Jul 23, 2026

Copy link
Copy Markdown
Member

Follow-up to #105, which floored Pillow. The other runtime dependencies were
still declared unbounded, so an installer could resolve any version —
including ones predating known advisories — whenever another constraint in
the environment held them back.

Dependency Before After
requests unbounded >=2.33.0
python-dotenv unbounded >=1.0.0
webdriver-manager unbounded >=4.0.0
defusedxml unbounded >=0.7.1

Applied to pyproject.toml, dev.toml (both published packages) and the
defusedxml entries in requirements.txt / dev_requirements.txt.

Why these floors

  • requests 2.33.0 is the first release carrying the extract_zipped_paths
    fix (GHSA-gc5v-m9x4-r6x2, published March 2026). This is the one floor with
    a concrete security driver.
  • webdriver-manager 4.0.0 is the line this package is developed and tested
    against. Worth being explicit: this is a policy floor, not an API
    requirement — 3.9.1 does expose both DriverCacheManager and the
    cache_manager kwarg that webdriver_wrapper passes, so the code would run
    on it. 4.x is simply what is exercised.
  • python-dotenv 1.0.0 and defusedxml 0.7.1 are the current stable
    lines (defusedxml 0.7.1 has been latest since 2021).

All are minimums with no upper bounds, so the package stays co-installable.
The trade-off worth noting is requests>=2.33.0: it is a recent release, so
it will force an upgrade in environments pinning older requests. That is the
intent of a security floor, but it is the most likely of these to be felt.

Deliberately not bounded

faker and sqlalchemy are optional extras, imported lazily behind guards
(_require_faker(), function-local from sqlalchemy import ...) and absent
from the package metadata entirely. A floor there would add friction without
a security benefit.

Verification

Local venv was still on the vulnerable Pillow 12.2.0, below the floor #105
published. Upgraded it and re-ran everything on 12.3.0 — the version this
package now forces on every installer:

Pillow 12.3.0
4375 passed, 9 skipped, 22 subtests passed

Built the wheel and confirmed the floors reach the metadata installers read:

Requires-Python: >=3.10
Requires-Dist: selenium>=4.0.0
Requires-Dist: requests>=2.33.0
Requires-Dist: python-dotenv>=1.0.0
Requires-Dist: webdriver-manager>=4.0.0
Requires-Dist: defusedxml>=0.7.1
Requires-Dist: Pillow>=12.3.0

twine check PASSED. Every installed version satisfies its declared floor.

Should publish normally — this changes the package's install contract.

🤖 Generated with Claude Code

requests, python-dotenv, webdriver-manager and defusedxml were declared
unbounded, so an installer could resolve any version — including ones
predating known advisories — whenever another constraint in the environment
held them back.

Floors chosen from evidence rather than convenience:

- requests>=2.33.0 is the first release carrying the extract_zipped_paths
  fix (GHSA-gc5v-m9x4-r6x2).
- webdriver-manager>=4.0.0 is the line this package is developed against.
  3.9.1 does expose DriverCacheManager and the cache_manager kwarg the
  wrapper uses, so this is a policy floor, not an API requirement.
- python-dotenv>=1.0.0 and defusedxml>=0.7.1 are the stable current lines.

These are minimums only; no upper bounds, so the package stays
co-installable. faker and sqlalchemy are deliberately left alone — both are
optional extras imported lazily behind guards and are absent from the
package metadata, so a floor there would add friction without benefit.
@sonarqubecloud

Copy link
Copy Markdown

@codacy-production

Copy link
Copy Markdown

Up to standards ✅

🟢 Issues 0 issues

Results:
0 new issues

View in Codacy

🟢 Metrics 0 complexity · 0 duplication

Metric Results
Complexity 0
Duplication 0

View in Codacy

NEW Get contextual insights on your PRs based on Codacy's metrics, along with PR and Jira context, without leaving GitHub. Enable AI reviewer
TIP This summary will be updated as you push new changes.

@JE-Chen
JE-Chen merged commit 858c8b0 into main Jul 23, 2026
22 checks passed
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