Track approved changes; ui; resolvers and storage#7960
Conversation
There was a problem hiding this comment.
Code Review
This pull request implements tracking for approved schema changes, enabling the association of proposed changes with their eventual implementation in schema versions. Key additions include a new proposal_approved_changes table, a DataLoader for efficient change matching, and UI updates to display proposal links in the schema history and check results. Feedback highlights a SQL syntax error in the storage provider, a runtime error in the proposal manager's batching logic, and a missing authorization check for proposal IDs. Furthermore, debug code in the registry checks should be removed, and generic errors in resolvers should be replaced with specific error classes.
|
🐋 This PR was built and pushed to the following Docker images: Targets: Platforms: Image Tag: |
| }), | ||
| }) | ||
| private async internalCheck(input: CheckInput) { | ||
| private async internalCheck(input: CheckInput): Promise<CheckResult> { |
There was a problem hiding this comment.
All the typing in this file is to clean up the response type. Before ts was getting confused about the exact format of the union of types
| "@date-fns/utc": "2.1.1", | ||
| "@graphql-hive/core": "workspace:*", | ||
| "@graphql-hive/signal": "1.0.0", | ||
| "@graphql-inspector/compare-changes": "0.1.0-alpha-20260328000712-2cf98744a012fa66614588ed89ba99719b0f461b", |
There was a problem hiding this comment.
requires graphql-hive/graphql-inspector#2949
| const parser = new MaxTokensParserWLexer(source, { | ||
| ...options, | ||
| n: 800, | ||
| n: 1_000, |
There was a problem hiding this comment.
The changes operation keeps bumping up against the limit and rather than fight it or implement a one-off condition, I don't see an issue with increasing this slightly.
33cb4c7 to
79537e2
Compare
Add proposal change approval tracking job
ba634bb to
b0baa8c
Compare
Background
Internal documentation:
https://guild-oss.slack.com/docs/TAYJ1FSUA/F0ALG3E94LD
https://linear.app/the-guild/issue/CONSOLE-1755/schema-proposals-for-all-proposal-states-show-which-changes-have-been
Description
Adds schema proposal change tracking. The initial plan was to have a check mark next to the change but during implementation this felt out of place, so the implementation is shown inside the change accordion for the time being.
The task to create the approved change records is not yet complete. Since the number of changes could be numerous, I want to do this in a background task.
Checklist