Skip to content

Fix BOM ref values in dependency graph warning log#5909

Open
Zureno wants to merge 2 commits intoDependencyTrack:masterfrom
Zureno:fix-dependency-graph-warning-bomref-order
Open

Fix BOM ref values in dependency graph warning log#5909
Zureno wants to merge 2 commits intoDependencyTrack:masterfrom
Zureno:fix-dependency-graph-warning-bomref-order

Conversation

@Zureno
Copy link
Copy Markdown
Contributor

@Zureno Zureno commented Mar 15, 2026

Description

Fixes the warning log emitted when a direct dependency BOM ref cannot be resolved during dependency graph processing.

The warning message in resolveDirectDependenciesJson(...) currently formats the parent BOM ref and the direct dependency BOM ref in reverse order. This makes troubleshooting more difficult because the unresolved reference appears in the wrong position in the log output.

This change corrects the formatting order so the unresolved direct dependency BOM ref is reported first, followed by the BOM ref whose dependencies are being processed.

Addressed Issue

N/A – Logging clarity improvement.

Additional Details

In resolveDirectDependenciesJson(...), the warning currently uses:
.formatted(dependencyBomRef, directDependencyBomRef)

Checklist

  • I have read and understand the contributing guidelines
  • This PR fixes a defect, and I have provided tests to verify that the fix is effective
  • This PR implements an enhancement, and I have provided tests to verify that it works as intended
  • This PR introduces changes to the database model, and I have added corresponding update logic
  • This PR introduces new or alters existing behavior, and I have updated the documentation accordingly

Zureno added 2 commits March 14, 2026 20:54
Signed-off-by: Zureno <pranshu21freak@gmail.com>
Signed-off-by: Zureno <pranshu21freak@gmail.com>
@owasp-dt-bot
Copy link
Copy Markdown

Snyk checks have passed. No issues have been found so far.

Status Scan Engine Critical High Medium Low Total (0)
Open Source Security 0 0 0 0 0 issues

💻 Catch issues earlier using the plugins for VS Code, JetBrains IDEs, Visual Studio, and Eclipse.

@Zureno
Copy link
Copy Markdown
Contributor Author

Zureno commented Mar 15, 2026

Happy to split the changes into separate PRs if preferred.

@Zureno Zureno requested a review from nscuro March 15, 2026 17:53
@codacy-production
Copy link
Copy Markdown

Coverage summary from Codacy

See diff coverage on Codacy

Coverage variation Diff coverage
-0.01% (target: -1.00%) 40.00% (target: 70.00%)
Coverage variation details
Coverable lines Covered lines Coverage
Common ancestor commit (ca0524b) 24785 20189 81.46%
Head commit (c272412) 24788 (+3) 20190 (+1) 81.45% (-0.01%)

Coverage variation is the difference between the coverage for the head and common ancestor commits of the pull request branch: <coverage of head commit> - <coverage of common ancestor commit>

Diff coverage details
Coverable lines Covered lines Diff coverage
Pull request (#5909) 5 2 40.00%

Diff coverage is the percentage of lines that are covered by tests out of the coverable lines that the pull request added or modified: <covered lines added or modified>/<coverable lines added or modified> * 100%

See your quality gate settings    Change summary preferences

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