Repository navigation
Replies: 1 comment
|
Hi, thanks for the report. Regards, Dmitriy |
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Description
Opening this at the request of the reviewer on #11058. @nicoloangileri supplied the pandas/NumPy example in the PR; I reproduced the omission with a newly generated lockfile.
Poetry records pandas' NumPy dependency as an array of marker-specific constraints. The parser drops that edge, then the Poetry analyzer classifies NumPy as a development dependency. Default filesystem SBOM output consequently omits NumPy.
Desired Behavior
NumPy is included as a production dependency, with a pandas-to-NumPy edge.
Actual Behavior
With the base parser from
780e90e, the default CycloneDX output contains pandas, python-dateutil, six and tzdata. Adding--include-dev-depsincludes NumPy but the pandas-to-NumPy edge is still missing. With #11058's parser, both NumPy and the edge appear in the default output.Reproduction Steps
Use Poetry 2.2.1 with this
pyproject.toml:Run
poetry lock, then comparetrivy fs --format cyclonedx .withtrivy fs --format cyclonedx --include-dev-deps ..The run resolved pandas 3.0.6 and NumPy 2.5.3. The relevant lockfile entry is:
A reduced fixture is included in the follow-up test. It preserves the generated package and dependency fields; file hashes, descriptions and extras were removed.
This reproduction has one locked NumPy version. With
requires-python = ">=3.11", a separate run locked NumPy 2.4.6 and 2.5.3; the patched parser still selected only 2.4.6. The existing first-matching-version behavior remains a limitation of #11058.Target
Filesystem
Scanner
None (SBOM generation)
Output Format
CycloneDX
Mode
Standalone
Debug Output
Relevant lines from the base-parser run with
--debug:Operating System
macOS 27.0, arm64
Version
Source builds from PR #11058 at
39c2197, with and without itsparse.gochange (base780e90e); Go 1.26.3 withGOEXPERIMENT=jsonv2. The before build uses the base parser through a Go source overlay. The before and after builds used separate temporary cache directories.Checklist
trivy clean --all(used dedicated temporary cache directories)All reactions