Skip to content

Replays Self-Serve Bulk Delete System#6

Open
ShashankFC wants to merge 32 commits into
replays-delete-vulnerablefrom
replays-delete-stable
Open

Replays Self-Serve Bulk Delete System#6
ShashankFC wants to merge 32 commits into
replays-delete-vulnerablefrom
replays-delete-stable

Conversation

@ShashankFC

@ShashankFC ShashankFC commented Feb 13, 2026

Copy link
Copy Markdown

User description

Test 5

Summary by CodeRabbit

Release Notes

  • New Features

    • Added AI-powered feedback summaries in the feedback list.
    • Introduced table widget visualization for dashboards with customizable columns.
    • Added owner assignment support for workflow detectors.
    • Enhanced replay summaries with error context integration.
  • Bug Fixes

    • Improved PR comment formatting with better issue title and environment display.
    • Refined feedback summary generation with stricter length and format constraints.
    • Disabled autofix automation tuning by default for improved stability.

Replicated from ai-code-review-evaluation/sentry-coderabbit#5


CodeAnt-AI Description

Replays Self-Serve Bulk Delete System

What Changed

  • Browser reporting collector now accepts and validates both the Working Draft and Editor's Draft report formats, rejects malformed reports with a 422 response including validation error details, and records metrics per valid report.
  • Replay breadcrumbs summary now includes related error context (merged with breadcrumbs in chronological order) when available; callers can disable error-context inclusion via the enable_error_context=false query parameter.
  • Pull request / merge request suspect-issues comments now show each issue as a linked item and include the issue's environment (e.g., in 'prod') when available.
  • Detector API and UI now accept an owner field (user or team); owners can be set, changed, or cleared and are returned in API responses. Tests added for owner handling.
  • Explore visualizations simplified: charts now use a single yAxis value instead of arrays; toolbar and chart UI updated accordingly and tests adjusted.
  • Default project autofix automation tuning changed from "low" to "off" (default option updated and tests adjusted).
  • Several tests and migrations updated: migrations that were faulty were made no-ops and multiple test suites adjusted to reflect behavior changes above.

Impact

✅ Clearer browser report validation errors
✅ Replay summaries include relevant error context (unless disabled)
✅ Detector owners can be assigned in the API

💡 Usage Guide

Checking Your Pull Request

Every time you make a pull request, our system automatically looks through it. We check for security issues, mistakes in how you're setting up your infrastructure, and common code problems. We do this to make sure your changes are solid and won't cause any trouble later.

Talking to CodeAnt AI

Got a question or need a hand with something in your pull request? You can easily get in touch with CodeAnt AI right here. Just type the following in a comment on your pull request, and replace "Your question here" with whatever you want to ask:

@codeant-ai ask: Your question here

This lets you have a chat with CodeAnt AI about your pull request, making it easier to understand and improve your code.

Example

@codeant-ai ask: Can you suggest a safer alternative to storing this secret?

Preserve Org Learnings with CodeAnt

You can record team preferences so CodeAnt AI applies them in future reviews. Reply directly to the specific CodeAnt AI suggestion (in the same thread) and replace "Your feedback here" with your input:

@codeant-ai: Your feedback here

This helps CodeAnt AI learn and adapt to your team's coding style and standards.

Example

@codeant-ai: Do not flag unused imports.

Retrigger review

Ask CodeAnt AI to review the PR again, by typing:

@codeant-ai: review

Check Your Repository Health

To analyze the health of your code repository, visit our dashboard at https://app.codeant.ai. This tool helps you identify potential issues and areas for improvement in your codebase, ensuring your repository maintains high standards of code health.

armenzg and others added 30 commits June 20, 2025 12:49
…o 'low' (#93927)"

This reverts commit 8d04522.

Co-authored-by: roaga <47861399+roaga@users.noreply.github.com>
Missed in the initial commit, leading to some relevant logs being
unannotated.
We have had a few tasks get killed at 10% rollout.
Also add a test, so that this doesn't happen again
Fixes DE-129 and DE-156

---------

Co-authored-by: Cursor Agent <cursoragent@cursor.com>
These transitions should be matching
…` (#93946)

Use `project_id` on the replay record instead of the URL (where it does
not always exist).

---------

Co-authored-by: Cursor Agent <cursoragent@cursor.com>
Co-authored-by: getsantry[bot] <66042841+getsantry[bot]@users.noreply.github.com>
Also fixed `replay.view_html` -> `replay.view-html`

---------

Co-authored-by: Michelle Zhang <56095982+michellewzhang@users.noreply.github.com>
…948)

gets `npx @typescript/native-preview` passing again
The conditions associated with a DCG can change over time, and it's good
if we can be completely confident that they're consistent within a given
task execution.
This is unused and most regex experiments have required broader changes
to ensure that regexes are evaluated in a specific order (ex:
traceparent). Removing this for now to simplify the code and very
slightly improve runtime performance.
From some testing (on feedback lists of all different lengths), this
prompt seems to work better. It doesn't write overly long sentences and
also does a better job at "summarizing" versus just mentioning a few
specific topics and leaving out others.
Just remove a couple custom Flex* classes in favor of the Flex primitive
This has been killed a few times.

Refs SENTRY-42M7
…n table (#93892)

<!-- Describe your PR here. -->

[ticket](https://linear.app/getsentry/issue/ID-156/grouping-info-remove-type-field-from-ui)
The Type field in the Grouping Info section of the issue details page
was redundant.
This removes the Type row from all variant types while keeping the
underlying data structure intact.

before
![Screenshot 2025-06-20 at 12 00
54 PM](https://github.com/user-attachments/assets/97ca72da-0a52-4446-9825-cd4fcb505adf)

after
![Screenshot 2025-06-20 at 11 59
29 AM](https://github.com/user-attachments/assets/a4284d2b-c9f5-442f-b010-7fe72a598e39)
### Changes
Related to this PR: getsentry/sentry#93810. This
is part 1 of the change, which is pulling out the new component and just
adding it to the repo. Also includes some simplification of the logic in
the base component.

Part 2 will be replacing tables in widgets.

### Before/After

There is no UI change as the table is not being used yet. There is a new
story page for the component.
…93943)

to prevent this issue from becoming too noisy, add a noise config
Unfortunately, 'event_data' went from being the variable for current
event context to being the complete parsed data from Redis, and we
continued logging it per group.
That's more data than we should be logging even arguably once, let alone
per group.
Co-authored-by: Abdullah Khan <abdullahkhan@PG9Y57YDXQ.local>
Adds some simple analytics to our endpoint so we can begin building a
dashboard in Amplitude.
Previously, explore supported multiple y axis per chart, so each
visualize supported multiple y axis. That functionality has since been
removed for simplicity so update the types here to match. Keep in mind
that saved queries still store them as an array so when
serializing/deserializing, we still need to treat it as an array.
We'll need the `useGetTraceItemAttributeKeys` hook in other places so
refactoring it so that it can exported.
mrduncan and others added 2 commits June 20, 2025 13:20
When the max segment ID is null the process fails. We should exit early
since if there aren't any segments to delete there's nothing to do.
@ShashankFC

Copy link
Copy Markdown
Author

@CodeAnt-AI: review

@codeant-ai

codeant-ai Bot commented Feb 13, 2026

Copy link
Copy Markdown

CodeAnt AI is running the review.

@codeant-ai

codeant-ai Bot commented Feb 13, 2026

Copy link
Copy Markdown

Sequence Diagram

This PR enriches the replay summarize breadcrumbs endpoint by fetching error IDs from the replay record (Snuba), loading error events from nodestore, merging error context with recording breadcrumbs, and sending the combined logs to Seer. The diagram shows the main success path introduced by the changes.

sequenceDiagram
    participant Client
    participant ReplayAPI as ProjectReplaySummarizeBreadcrumbsEndpoint
    participant Snuba
    participant Nodestore
    participant Storage as RecordingStorage
    participant Seer

    Client->>ReplayAPI: GET /projects/{org}/{proj}/replays/{id}/summarize
    ReplayAPI->>Snuba: query_replay_instance(replay_id, time range)
    Snuba-->>ReplayAPI: replay record (includes error_ids)
    ReplayAPI->>Nodestore: fetch_error_details(error_ids)
    Nodestore-->>ReplayAPI: error events (timestamped)
    ReplayAPI->>Storage: paginate -> fetch_segments_metadata -> iter_segment_data
    Storage-->>ReplayAPI: recording segments (breadcrumbs)
    ReplayAPI->>Seer: combine logs + error events -> make_seer_request(signed payload)
    Seer-->>ReplayAPI: analysis result
    ReplayAPI-->>Client: 200 OK (Seer response)
Loading

Generated by CodeAnt AI

@codeant-ai codeant-ai Bot added the size:XXL This PR changes 1000+ lines, ignoring generated files label Feb 13, 2026
@codeant-ai

codeant-ai Bot commented Feb 13, 2026

Copy link
Copy Markdown

Nitpicks 🔍

🔒 No security issues identified
⚡ Recommended areas for review

  • Possible null/undefined access
    The fallback column order reads from tableData?.meta.fields without guaranteeing tableData.meta and meta.fields are present or objects. If tableData or meta are undefined or not shaped as expected this can produce runtime issues or unexpected column orders. Consider defensive checks or defaults.

  • Possible Bug
    The hook returns values that dereference data (e.g. data.summary, data.numFeedbacksUsed) without guarding that data is defined. If the query is not enabled or returns undefined, this will produce runtime errors. Ensure data is validated or use safe defaults before accessing its properties.

  • Sensitive Analytics
    trackAnalytics is being called with the entire organization object as payload. This can include more information than needed (potentially sensitive or large), and may also make analytics events unstable if the object shape changes. Prefer sending minimal identifiers (e.g. organization.slug or organization.id) and stable primitives only.

  • Empty Table Rendering
    Under the use-table-widget-visualization feature flag, TableWidgetVisualization is rendered with hardcoded empty columns and empty tableData. This will produce an empty/incorrect table even when tableResults contains data. The visualization should receive actual result data/metadata and derived columns.

  • Removed client-side filtering
    The previous implementation filtered out "known" attributes and keys with illegal characters and also set the kind (FieldKind). The new code delegates to useGetTraceItemAttributeKeys/API and no longer performs those filters or sets kind. Verify the server hook returns the same sanitized shape and kind, otherwise invalid keys or unexpected attribute shapes may reach callers.

  • Possible data mismatch
    computeVisualizeSampleTotals now uses a single visualize.yAxis wrapped in an array instead of deduping visualize.yAxes. If Visualize sometimes provides multiple y axes (e.g. yAxes) or the property shape changed, this may cause missing series lookups (undefined keys) or incorrect totals. Validate the Visualize shape and ensure all y axes are considered and deduped.

  • Nullable parsedFunction
    parsedFunction is used without guarding for undefined in setChartField and setChartAggregate. If parseFunction(yAxis) ever returns undefined, these callbacks will produce strings like undefined(...) or pass undefined arguments into updateVisualizeAggregate, which can lead to unexpected visualize values or logic errors.

  • Ref forwarding risk
    The callback setRef is passed to the Flex component as a ref. If Flex does not forward refs to a DOM element, setRef may receive null or a component instance and the ResizeObserver won't be attached to an actual DOM node. This will break container width measurement and resize handling.

  • use of Array.toSpliced
    The code uses Array.prototype.toSpliced to compute new visualizes. This is an ES2023 API and may not be available across all runtimes/environments or polyfill expectations. If unsupported, this could break in older test runners or environments.

  • Layout / DOM semantics
    The row rendering uses a Fragment with six sibling Flex elements to populate the PanelTable grid. Confirm PanelTable expects direct children as grid cells in this order and that replacing the previous FlexCenter components with multiple Flex wrappers doesn't break keyboard navigation, row semantics, or cause unexpected layout regressions (e.g. vertical alignment differences). Validate behavior in narrow/responsive widths.

@codeant-ai

codeant-ai Bot commented Feb 13, 2026

Copy link
Copy Markdown

CodeAnt AI finished running the review.

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

Labels

size:XXL This PR changes 1000+ lines, ignoring generated files

Projects

None yet

Development

Successfully merging this pull request may close these issues.