Skip to content

feat: use uv depgraph generation in monitor#6529

Open
snyk-will wants to merge 3 commits intomainfrom
feat/use-uv-depgrpah
Open

feat: use uv depgraph generation in monitor#6529
snyk-will wants to merge 3 commits intomainfrom
feat/use-uv-depgrpah

Conversation

@snyk-will
Copy link
Contributor

@snyk-will snyk-will commented Feb 11, 2026

Pull Request Submission Checklist

  • Follows CONTRIBUTING guidelines
  • Commit messages
    are release-note ready, emphasizing
    what was changed, not how.
  • Includes detailed description of changes
  • Contains risk assessment (Low | Medium | High)
  • Highlights breaking API changes (if applicable)
  • Links to automated tests covering new functionality
  • Includes manual testing instructions (if necessary)
  • Updates relevant GitBook documentation (PR link: ___)
  • Includes product update to be announced in the next stable release notes

What does this PR do?

For uv monitor Instead of returning a fixed depgraph we now use the go binary calling the depgraph endpoint to generate correct depgraphs for uv projects.

Where should the reviewer start?

How should this be manually tested?

run snyk monitor on a uv project

@snyk-will snyk-will force-pushed the feat/use-uv-depgrpah branch from 2a0906e to 404f010 Compare February 11, 2026 14:42
@thomasschafer thomasschafer force-pushed the feat/add-hidden-uv-support branch from 72336bc to f4ce8b5 Compare February 13, 2026 15:50
@snyk-will snyk-will force-pushed the feat/use-uv-depgrpah branch from 34d455c to 8e9142d Compare February 13, 2026 16:01
@thomasschafer thomasschafer force-pushed the feat/add-hidden-uv-support branch 7 times, most recently from 79869bb to 8e07531 Compare February 16, 2026 09:29
@snyk-will snyk-will force-pushed the feat/use-uv-depgrpah branch from 401faf6 to f9e10ca Compare February 16, 2026 13:52
@snyk-will snyk-will requested a review from snyk-tim February 16, 2026 15:19
@snyk-will snyk-will marked this pull request as ready for review February 16, 2026 15:19
@snyk-will snyk-will requested review from a team as code owners February 16, 2026 15:19
@thomasschafer thomasschafer force-pushed the feat/add-hidden-uv-support branch from 8e07531 to df0d731 Compare February 16, 2026 16:32
@snyk-will snyk-will force-pushed the feat/use-uv-depgrpah branch from c8828c2 to eb32f78 Compare February 16, 2026 16:38
@thomasschafer thomasschafer force-pushed the feat/add-hidden-uv-support branch 5 times, most recently from a466bec to 7d1781a Compare February 17, 2026 09:54
@snyk-will snyk-will force-pushed the feat/use-uv-depgrpah branch from eb32f78 to 042d830 Compare February 17, 2026 10:31
@thomasschafer thomasschafer force-pushed the feat/add-hidden-uv-support branch from 7d1781a to 09a1979 Compare February 17, 2026 14:03
@snyk-pr-review-bot

This comment has been minimized.

@snyk-will snyk-will force-pushed the feat/use-uv-depgrpah branch from 1ec4efa to 765709e Compare February 18, 2026 09:24
@snyk-pr-review-bot

This comment has been minimized.

@snyk-will snyk-will force-pushed the feat/use-uv-depgrpah branch from 765709e to 81aa36a Compare February 18, 2026 10:03
@snyk-pr-review-bot

This comment has been minimized.

@snyk-pr-review-bot

This comment has been minimized.

@thomasschafer thomasschafer force-pushed the feat/add-hidden-uv-support branch 3 times, most recently from 32333c2 to d26bc72 Compare February 19, 2026 08:59
const result = await execGoCommand(args, { cwd: root });

if (result.exitCode !== 0) {
throw new CLI.GeneralCLIFailureError(extractErrorDetail(result));
Copy link
Contributor

Choose a reason for hiding this comment

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

Suggestion: This will hide the root error and report it as general failure. It would be better to return the correct error-catalog error. You might need something like this though.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

yes this is something we've been thinking about, but out of scope for this particular ticket. We actually have a ticket here to start a discussion with you about how we get the errors back from the go binary properly.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

@snyk-pr-review-bot

This comment has been minimized.

@snyk-pr-review-bot

This comment has been minimized.

let depGraphData: DepGraphData;
try {
depGraphData = JSON.parse(result.stdout);
} catch {
Copy link
Contributor

Choose a reason for hiding this comment

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

Is it worth also adding a debug log for the exact error here, and maybe include stdout too? Then we can see what exactly was returned from the Go binary and why we couldn't parse the JSON

@snyk-will snyk-will force-pushed the feat/use-uv-depgrpah branch from cb801e4 to d03dc2d Compare February 19, 2026 11:30
@snyk-pr-review-bot

This comment has been minimized.

@snyk-will snyk-will force-pushed the feat/use-uv-depgrpah branch from d03dc2d to 90c9981 Compare February 19, 2026 13:20
@snyk-pr-review-bot

This comment has been minimized.

@thomasschafer thomasschafer force-pushed the feat/add-hidden-uv-support branch from d26bc72 to 1109d0c Compare February 19, 2026 14:39
@snyk-will snyk-will force-pushed the feat/use-uv-depgrpah branch from 90c9981 to 8a6f292 Compare February 19, 2026 15:28
@snyk-pr-review-bot

This comment has been minimized.

@snyk-pr-review-bot

This comment has been minimized.

@snyk-pr-review-bot
Copy link

PR Reviewer Guide 🔍

🧪 PR contains tests
🔒 No security concerns identified
⚡ No major issues detected
📚 Repository Context Analyzed

This review considered 11 relevant code sections from 10 files (average relevance: 1.04)

Base automatically changed from feat/add-hidden-uv-support to main February 19, 2026 16:56
@github-actions
Copy link
Contributor

Warnings
⚠️ There are multiple commits on your branch, please squash them locally before merging!

Generated by 🚫 dangerJS against 8112882

} catch (error) {
const parseError = error instanceof Error ? error.message : String(error);
debug(
'Failed to parse dependency information JSON: %s (stdout preview: %s, stderr preview: %s)',
Copy link
Contributor

Choose a reason for hiding this comment

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

Stdout/stderr might be multiline, maybe want to add some newlines e.g.

Suggested change
'Failed to parse dependency information JSON: %s (stdout preview: %s, stderr preview: %s)',
'Failed to parse dependency information JSON: %s\nstdout preview:\n%s\nstderr preview:\n%s',

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.

4 participants

Comments