Skip to content

Validate explore column editor fields#118377

Draft
nsdeschenes wants to merge 2 commits into
masterfrom
nd/EXP-1030/feat-explore-validate-explore-column-fields
Draft

Validate explore column editor fields#118377
nsdeschenes wants to merge 2 commits into
masterfrom
nd/EXP-1030/feat-explore-validate-explore-column-fields

Conversation

@nsdeschenes

Copy link
Copy Markdown
Contributor

Summary

  • validate span sample table columns with the spans tab validator
  • add valid validator fields to the column editor typed attribute maps
  • remove invalid validated fields from the editor and query params so they stop rendering in the table
  • add focused coverage for validation sanitization and typed modal selections

Test plan

  • pnpm test-ci static/app/views/explore/tables/index.spec.tsx
  • pnpm test-ci static/app/views/explore/tables/columnEditorModal.spec.tsx
  • pnpm test-ci static/app/views/explore/spans/hooks/useValidateSpansTab.spec.tsx
  • pnpm run lint:js static/app/views/explore/tables/index.tsx static/app/views/explore/tables/index.spec.tsx static/app/views/explore/tables/columnEditorModal.spec.tsx
  • .venv/bin/prek run -q

@linear-code

linear-code Bot commented Jun 24, 2026

Copy link
Copy Markdown

EXP-1030

@github-actions github-actions Bot added the Scope: Frontend Automatically applied to PRs that change frontend components label Jun 24, 2026

@cursor cursor Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Cursor Bugbot has reviewed your changes and found 1 potential issue.

Fix All in Cursor

❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.

Want reviews to match your repository better? Bugbot Learning can learn team-specific rules from PR activity. A team admin can enable Learning in the Cursor dashboard.

Reviewed by Cursor Bugbot for commit 7bc6137. Configure here.

if (validatedFields.length < fields.length) {
setFields([...validatedFields]);
}
}, [fields, setFields, validatedFields]);

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Invalid columns persist when lengths match

Low Severity

The effect that syncs query fields with validation only runs when validatedFields is shorter than fields. If an invalid column is dropped but the remaining list has the same length (e.g. duplicate valid columns plus one invalid name), setFields never runs and the invalid column can stay in the URL and span samples table.

Fix in Cursor Fix in Web

Reviewed by Cursor Bugbot for commit 7bc6137. Configure here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Scope: Frontend Automatically applied to PRs that change frontend components

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant