ref(settings): Migrate project issue grouping form to scraps form#116465
Draft
priscilawebdev wants to merge 2 commits into
Draft
ref(settings): Migrate project issue grouping form to scraps form#116465priscilawebdev wants to merge 2 commits into
priscilawebdev wants to merge 2 commits into
Conversation
Replace the legacy JsonForm/FormModel implementation of the project Issue Grouping settings (Fingerprint Rules, Stack Trace Rules, and the read-only Derived Grouping Enhancements) with the TanStack-based scraps form system. Each rule was a saveOnBlur:false field, so the migration uses useScrapsForm with an explicit Save/Cancel button and the 'applies to future events' info notice, instead of AutoSaveForm. The derived enhancements field stays read-only. Wrap each form in FormSearch and regenerate generatedFieldRegistry.ts so the rules remain searchable in SettingsSearch, and drop the now-unused projectIssueGrouping data file. Add the fingerprintingRules, groupingEnhancements, and derivedGroupingEnhancements fields (returned by the project detail API) to the DetailedProject type. Co-Authored-By: Claude <noreply@anthropic.com>
Contributor
📊 Type Coverage Diff✅ No new type safety issues introduced. Coverage: 93.59% |
The legacy Form displayed server-side validation errors inline. The initial scraps migration only showed a generic error toast, hiding the specific message returned for invalid fingerprint or stack trace rule syntax. Use setFieldErrors in the mutation catch to map API field errors back onto the form field, falling back to the generic toast when the response has no field-specific errors. Add interaction tests covering a successful save and inline error display. Co-Authored-By: Claude <noreply@anthropic.com>
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.
Migrates the project Issue Grouping settings page (
static/app/views/settings/projectIssueGrouping/) from the legacyJsonForm/FormModelsystem to the new TanStack-based scraps form system.What changed
saveOnBlur: falsefields, so they migrate touseScrapsFormwith an explicit Save/Cancel button and the inline "applies to future events only" info notice — rather thanAutoSaveForm.FormSearchandgeneratedFieldRegistry.tsis regenerated so all three rules remain searchable in SettingsSearch. The now-unusedprojectIssueGroupingdata file is removed.fingerprintingRules,groupingEnhancements, andderivedGroupingEnhancementsfields (returned by the project detail API, previously read untyped byJsonForm) to theDetailedProjecttype.Why
Part of the ongoing migration off the legacy form system.
allowUndois intentionally dropped per the migration guide (replaced by standard error toasts).Both existing component tests pass unchanged; full typecheck and lint are clean.