Skip to content

Conversation

@alhss
Copy link
Contributor

@alhss alhss commented Oct 17, 2025

Added support for a new existing pull request format while maintaining full backward compatibility. The ExistingPR struct now serves as a superset capable of representing both individual dependencies and the new format PRs with nested dependencies. Custom UnmarshalJSON and UnmarshalYAML methods handle automatic format detection and parsing for both the new format (PRs with pr-number + nested dependencies) and legacy format (nested [][]ExistingPR arrays).

@alhss alhss requested review from a team as code owners October 17, 2025 15:45
@jakecoffman
Copy link
Member

Looks like a smoke test is catching an issue. Otherwise looks good so far!

@alhss alhss force-pushed the alhss/support-for-new-pr-format branch from 42ec787 to 3118be9 Compare October 17, 2025 18:21
@alhss
Copy link
Contributor Author

alhss commented Oct 17, 2025

Added two marshal methods to preserve backward compatibility with the updater. When unmarshaling old format [[...]], we flatten it internally to [...] , but the updater still expects the old nested array format. These marshal methods detect the format and re-wrap flat entries as [[...]] when sending to the updater since this method cannot handle unflatten data of the old format.

Copy link
Member

@jakecoffman jakecoffman left a comment

Choose a reason for hiding this comment

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

cool cool, nice work preserving the formatting when marshaling

@alhss alhss added this pull request to the merge queue Oct 20, 2025
Merged via the queue into main with commit 0415abb Oct 20, 2025
88 checks passed
@alhss alhss deleted the alhss/support-for-new-pr-format branch October 20, 2025 18:41
alhss added a commit that referenced this pull request Oct 20, 2025
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