Sitelet https://github.com/NVIDIA/SkillEvaluator/pull/107
Skip to content

fix(hygiene): detect unpinned dependencies with environment markers - #107

Merged
chrisknvidia merged 7 commits into
NVIDIA:mainfrom
rioyu123:codex/fix-requirement-marker-pinning
Sep 8, 2026
Merged

chrisknvidia merged 7 commits into
NVIDIA:mainfrom
rioyu123:codex/fix-requirement-marker-pinning

Conversation

@rioyu123

Copy link
Copy Markdown
Contributor

Summary

  • Detect unpinned dependencies even when a PEP 508 environment marker contains comparison operators, such as requests; python_version < "3.13".
  • Inspect only the requirement portion before the marker when deciding whether a package has a version constraint.
  • Preserve the existing policy that any requirement comparator counts as constrained; this does not redefine ?pinned? to require ==.
  • Keep direct-reference behavior unchanged because direct-reference URLs may legally contain semicolons.
  • Document the newly emitted warning in the Unreleased changelog.

Before this change, the validator searched the entire physical line for [=<>!], so marker operators could hide an unversioned package:

Requirement Previous result New result
requests; python_version < "3.13" no warning unpinned warning
requests; sys_platform == "win32" no warning unpinned warning
requests>=2; python_version < "3.13" accepted accepted
requests @ https://example.invalid/a;v=1/requests.whl unchanged unchanged

Known adjacent behavior remains out of scope: direct references keep their existing constraint policy, inline comments are not parsed, and backslash continuations are still evaluated as physical lines.

Verification

  • I am familiar with the Contributing Guidelines
  • Added or updated focused tests
  • Updated documentation for user-visible changes
  • Ran make lint
  • Ran make test ? ran the complete affected validator domain instead
  • Ran make build
  • Did not add credentials, private datasets, or proprietary benchmark content

Results:

  • uv run pytest -q tests/validators/test_hygiene.py ? 26 passed, 1 skipped
  • uv run pytest -q tests/validators on Linux ? 847 passed
  • make PYTHON=.venv/bin/python lint ? passed
  • make PYTHON=.venv/bin/python build ? passed

Release Impact

  • No user-visible release note needed
  • Updated CHANGELOG.md

Signed-off-by: Rio Yu <52408936+rioyu123@users.noreply.github.com>

@rng1995 rng1995 left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

One blocking marker-parsing case remains.

Comment thread src/skillevaluator/validators/hygiene.py Outdated
Signed-off-by: Rio Yu <52408936+rioyu123@users.noreply.github.com>
Signed-off-by: Rio Yu <52408936+rioyu123@users.noreply.github.com>
@chrisknvidia

Copy link
Copy Markdown
Collaborator

@rioyu123 : Can you resolve the merge conflicts?

…nt-marker-pinning

# Conflicts:
#	CHANGELOG.md
@rioyu123

rioyu123 commented Sep 3, 2026 •

Copy link
Copy Markdown
Contributor Author

Resolved by merging the latest main and retaining both the upstream changelog entries and this PR's PEP 508 marker fix. The implementation and regression tests merged without conflicts; the focused hygiene suite passes (38 passed, 1 skipped). The updated head is ready for CI once GitHub Actions is approved.

@rioyu123
rioyu123 force-pushed the codex/fix-requirement-marker-pinning branch from 71caa17 to 0c2cb2e Compare September 4, 2026 00:23
@rioyu123

rioyu123 commented Sep 4, 2026

Copy link
Copy Markdown
Contributor Author

The previous head 71caa17 passed every CI and security check except DCO, which flagged one unsigned commit (docs(hygiene): clarify direct reference handling). I re-signed just that commit and recreated the merge on top of it — the tree at the new head 0c2cb2e is identical to the old one, so the PR diff is unchanged. The new runs are waiting on workflow approval; could you approve them when you get a chance?

Signed-off-by: Christopher Kevin <christopherk@nvidia.com>
@chrisknvidia
chrisknvidia dismissed rng1995’s stale review September 8, 2026 01:01

All requested changes and review threads are resolved on current head b93037e; dismissing this stale review after maintainer approval.

@chrisknvidia chrisknvidia left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@chrisknvidia
chrisknvidia merged commit f2d8f5d into NVIDIA:main Sep 8, 2026
17 checks passed
mimran-khan added a commit to mimran-khan/SkillEvaluator that referenced this pull request Sep 9, 2026
mimran-khan added a commit to mimran-khan/SkillEvaluator that referenced this pull request Sep 9, 2026
Resolve CHANGELOG.md after merging upstream NVIDIA#99, NVIDIA#107, and NVIDIA#112.
rng1995 pushed a commit to mimran-khan/SkillEvaluator that referenced this pull request Sep 14, 2026
Resolve CHANGELOG.md after merging upstream NVIDIA#99, NVIDIA#107, and NVIDIA#112.
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.

3 participants