Dependabot Snapshots has basic metadata about "status" and "reason"#13843
Merged
Ahmed3lmallah merged 4 commits intomainfrom Jan 12, 2026
Merged
Dependabot Snapshots has basic metadata about "status" and "reason"#13843Ahmed3lmallah merged 4 commits intomainfrom
Ahmed3lmallah merged 4 commits intomainfrom
Conversation
This was referenced Dec 20, 2025
yeikel
reviewed
Dec 31, 2025
Contributor
There was a problem hiding this comment.
Pull request overview
This PR adds metadata fields (status and reason) to dependency snapshots submitted to the GitHub Dependency Submission API. This enables downstream consumers to understand why a snapshot is empty without examining job logs. The implementation handles three distinct scenarios: successful snapshots with dependencies (status: "ok"), failed snapshots due to errors (status: "failed" with error type), and skipped snapshots for deleted manifests (status: "skipped" with reason "missing-manifest-files").
Key Changes
- Added status and reason metadata to all dependency snapshots with appropriate values based on submission context
- Introduced new constants for status values ("ok", "failed", "skipped") and the missing manifests reason
- Updated submission creation logic to populate metadata in error and missing file scenarios
Reviewed changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated 1 comment.
| File | Description |
|---|---|
updater/lib/github_api/dependency_submission.rb |
Added status/reason attributes with defaults, defined constants for status values, and included metadata in payload with .compact to omit nil reasons |
updater/lib/dependabot/update_graph_processor.rb |
Updated empty_submission signature to accept status/reason parameters, passed appropriate metadata for skipped (missing files) and failed (error) scenarios |
updater/spec/dependabot/update_graph_processor_spec.rb |
Added test assertions to verify metadata in all three scenarios: successful snapshots, failed snapshots, and skipped snapshots for non-existent files |
jakecoffman
previously approved these changes
Jan 6, 2026
jakecoffman
approved these changes
Jan 7, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What are you trying to accomplish?
A snapshot is submitted from update-graph jobs, even if fail scenarios, such as:
When those snapshots are consumed, it is hard to determine the reason behind having an empty snapshot without any supporting metadata! This PR adds those needed metadata:
Prerequisites:
How will you know you've accomplished your goal?
Start received dependency submissions with metadata
Checklist