-
-
Notifications
You must be signed in to change notification settings - Fork 4.5k
feat(issues): Allow disabling of filters in top group demo, add tags #104037
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
| <Text size="sm" variant="muted"> | ||
| {t('Disable filters and sorting')} | ||
| </Text> | ||
| </Flex> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Bug: Disable filters checkbox inaccessible after loading data
The disableFilters checkbox is only visible when showJsonInput is true, but clicking "Parse and Load" hides the JSON input section while keeping disableFilters in its current state. Users who enable this option before loading data cannot re-enable filters without clearing all custom data or reopening the JSON input section, creating a hidden state that affects functionality without visible controls.
| setCustomClusterData(null); | ||
| setJsonInputValue(''); | ||
| setJsonError(null); | ||
| setDisableFilters(false); | ||
| }, []); | ||
|
|
||
| const clusterData = customClusterData ?? topIssuesResponse?.data ?? []; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Bug: removedClusterIds state is not reset when custom data is cleared.
Severity: CRITICAL | Confidence: High
🔍 Detailed Analysis
When handleClearCustomData is called, the removedClusterIds state is not reset. This allows previously 'resolved' cluster IDs to persist, causing clusters with those IDs to be unexpectedly hidden if they appear in newly loaded custom JSON data, leading to incorrect filtering.
💡 Suggested Fix
Add setRemovedClusterIds(new Set()) to the handleClearCustomData function to ensure removedClusterIds is cleared upon custom data removal.
🤖 Prompt for AI Agent
Review the code at the location below. A potential bug has been identified by an AI
agent.
Verify if this is a real issue. If it is, propose a fix; if not, explain why it's not
valid.
Location: static/app/views/issueList/pages/dynamicGrouping.tsx#L386-L392
Potential issue: When `handleClearCustomData` is called, the `removedClusterIds` state
is not reset. This allows previously 'resolved' cluster IDs to persist, causing clusters
with those IDs to be unexpectedly hidden if they appear in newly loaded custom JSON
data, leading to incorrect filtering.
Did we get this right? 👍 / 👎 to inform future reviews.
Reference ID: 3642060
| size="sm" | ||
| /> | ||
| </Flex> | ||
| )} | ||
|
|
||
| <Flex gap="sm" align="center"> | ||
| <Text size="sm" variant="muted"> | ||
| {t('Minimum fixability score (%)')} | ||
| </Text> | ||
| <NumberInput | ||
| min={0} | ||
| max={100} | ||
| value={minFixabilityScore} | ||
| onChange={value => setMinFixabilityScore(value ?? 0)} | ||
| aria-label={t('Minimum fixability score')} | ||
| size="sm" | ||
| /> | ||
| </Flex> | ||
| </Flex> | ||
| </Disclosure.Content> | ||
| </Disclosure> | ||
| </Container> | ||
| </Disclosure.Content> | ||
| </Disclosure> | ||
| </Container> | ||
| )} | ||
| </Fragment> | ||
| )} | ||
| </HeaderSection> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Bug: teamsInData is not derived from clusterData, preventing custom data team filtering.
Severity: HIGH | Confidence: High
🔍 Detailed Analysis
The teamsInData state, which populates the team filter UI, is derived solely from topIssuesResponse?.data (API data) and not from clusterData (which can be custom JSON). This prevents teams present only in custom JSON data from appearing as filter options in the UI, limiting filtering capabilities for custom datasets.
💡 Suggested Fix
Modify the teamsInData useMemo hook to derive its data from clusterData instead of topIssuesResponse?.data to include teams from custom JSON.
🤖 Prompt for AI Agent
Review the code at the location below. A potential bug has been identified by an AI
agent.
Verify if this is a real issue. If it is, propose a fix; if not, explain why it's not
valid.
Location: static/app/views/issueList/pages/dynamicGrouping.tsx#L557-L636
Potential issue: The `teamsInData` state, which populates the team filter UI, is derived
solely from `topIssuesResponse?.data` (API data) and not from `clusterData` (which can
be custom JSON). This prevents teams present only in custom JSON data from appearing as
filter options in the UI, limiting filtering capabilities for custom datasets.
Did we get this right? 👍 / 👎 to inform future reviews.
Reference ID: 3642060
allows disabling sorting / filters
brings back tags