Skip to content

perf(frontend): load event details when a table row expands - #110356

Merged
trunk-io[bot] merged 2 commits into
masterfrom
posthog/lazy-event-details
Oct 2, 2026
Merged

trunk-io[bot] merged 2 commits into
masterfrom
posthog/lazy-event-details

Conversation

@pauldambra

@pauldambra pauldambra commented Oct 1, 2026 •

Copy link
Copy Markdown
Member

🤖 A robot (Claude Code) wrote this PR. The assignee directed the work.

Problem

  • Every events table downloads the AI conversation display and its message normalizer, including yaml, because DataTable imports EventDetails for its expanded row.

Refs #104853

Related: #110351, #110352, #110353, #110354, #110355

Changes

  • The expanded row loads EventDetails when it opens and shows a spinner meanwhile.
  • A ChunkLoadErrorBoundary sits inside the row, because the query's ErrorBoundary is nearer than the scene's. A stale chunk reloads the page once. If the reload already ran, the row shows a warning banner with a "Reload page" action and the table stays.

Together the six PRs cut the dashboard scene from 11.66 to 9.62 MiB (−2.04 MiB), events from 10.89 to 9.23 MiB, replay detail from 13.77 to 12.06 MiB, and project home from 14.43 to 13.89 MiB (minified, linked stylesheet included, same master build). Several modules have more than one importer, so part of the saving appears only once all six land.

On its own this PR removes about 165 KB from the dashboard and events scenes, and about 420 KB in combination with the others.

How did you test this code?

  • Typecheck passes, and the DataTable and activity suites pass.
  • Not checked: expanding a row in a browser.

Test rationale: No new test. EventDetails keeps its props, EventDetails.stories.tsx covers how it renders, and ChunkLoadErrorBoundary.test.tsx covers the fallback.

Release status

  • No feature flag controls this change
  • This change is behind a feature flag and is not available to users
  • This change makes a previously flagged feature available to everyone

Automatic notifications

  • Publish to changelog?

Docs update

None.

🤖 Agent context

Autonomy: Human-driven (agent-assisted)

Agent: Claude Code, Opus 5.5 (claude-opus-5-5)


Created with PostHog Desktop

🤖 Generated with Claude Code

DataTable imported EventDetails statically for its expanded row, which put the
AI conversation display and its message normalizer (yaml included) on the
static graph of every scene that renders an events table. The row now loads
EventDetails when it expands. A ChunkLoadErrorBoundary sits inside the row
because the query's ErrorBoundary is nearer than the scene's; if the reload
guard already ran, the row shows a warning banner and the table stays.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

Generated-By: PostHog Desktop
Task-Id: acec8cb2-f000-4747-a659-05b72b42513e
@pauldambra pauldambra self-assigned this Oct 1, 2026
@trunk-io

trunk-io Bot commented Oct 1, 2026 •

Copy link
Copy Markdown

😎 Merged successfully - details.

@posthog

posthog Bot commented Oct 1, 2026 •

Copy link
Copy Markdown
Contributor

FLASH MODE - Faster, but stupid, use regular ReviewHog for a heavy review

🦔 PostHog Review reviewed this pull request

Nothing worth raising this time. Enjoy the moment:

The dancing man in the red room from Twin Peaks

@github-actions

github-actions Bot commented Oct 1, 2026 •

Copy link
Copy Markdown
Contributor

🤖 CI report

✅ Trunk lane — non-backend lane

This PR is assigned to the non-backend lane. It does not run backend Python tests and may merge in parallel with PRs in other lanes.

⚠️ Complexity (TypeScript) — 3 functions above the limit (max 135)

Cyclomatic complexity above the limit in changed typescript files (10 for production files, 15 for test files). Warn only: worth simplifying when you next touch these functions.

Function Location Complexity Limit
DataTable frontend/src/queries/nodes/DataTable/DataTable.tsx:156 135 10
<anonymous> frontend/src/queries/nodes/DataTable/DataTable.tsx:336 21 10
<anonymous> frontend/src/queries/nodes/DataTable/DataTable.tsx:415 11 10
✅ Duplication (Python) — clean

New Python code duplication introduced by this branch. Fails at 70+ tokens in app code, or 150+ tokens when both copies live in test files. Advisory while the gate proves itself: extract a shared helper instead of copying.

✅ Duplication (TypeScript) — clean

New TypeScript code duplication introduced by this branch. Fails at 70+ tokens in app code, or 150+ tokens when both copies live in test files. Advisory while the gate proves itself: extract a shared helper instead of copying.

🚨 Comment density — 7% of added code lines are comments (6 of 84)

This section warns when comments are more than 3% of the code lines a PR adds, and alerts above 6%. Before agent-assisted PRs, the typical share was about 2%. Only full-line comments count. Docstrings, generated files, snapshots, migrations, and workflow files are left out.

Comments that restate the code, record how the change came about, or narrate the next line add noise for the next reader. Keep the comments that explain a reason the code cannot show, and remove the rest. See .agents/skills/writing-code-comments/SKILL.md for the house rules.

Files with the most added comment lines:

File Comment lines Added lines
frontend/src/queries/nodes/DataTable/ExpandedEventRow.test.tsx 3 44
frontend/src/queries/nodes/DataTable/ExpandedEventRow.tsx 3 30

This check does not block merging. It updates on every push and clears when the share drops.

✅ Bundle size — 🟢 -5.9 KiB (-0.0%)

Uncompressed size of every built .js bundle, compared against the base branch.

Total: 70.68 MiB · 🟢 -5.9 KiB (-0.0%)

File Size Δ vs base
posthog-app/src/scenes/activity/explore/EventDetails.js 7.1 KiB 🔺 +7.1 KiB (new)
exporter/src/scenes/activity/explore/EventDetails.js 3.5 KiB 🔺 +3.5 KiB (new)

Posted automatically by build-bundle-size-report · uncompressed bytes from dist-report

✅ Eager graph — within budget

How much code each root ships on the eager path — downloaded and parsed before the surface is interactive. Measured from the esbuild output chunks (post-tree-shake, static imports only); lazy import() / React.lazy chunks are not counted.

Root Eager (shipped) Δ vs base Budget
entry (logged-out pages, app bootstrap)
src/index.tsx
1.62 MiB · 22 files no change █████████░ 87.9% of 1.84 MiB
logged-out boot: index + App + bootApp (preloaded by every page, including /login)
src/index.tsx + src/scenes/App.tsx + src/scenes/bootApp.ts
3.57 MiB · 630 files no change █████████░ 88.7% of 4.03 MiB
authenticated shell (every logged-in page)
src/scenes/AuthenticatedShell.tsx
7.75 MiB · 2,486 files no change █████████░ 93.0% of 8.34 MiB
dashboard scene
src/scenes/dashboard/Dashboard.tsx
11.49 MiB · 4,425 files 🟢 -176.4 KiB (-1.5%) █████████░ 85.3% of 13.48 MiB
project home scene
src/scenes/project-homepage/ProjectHomepage.tsx
14.29 MiB · 5,322 files 🟢 -137.0 KiB (-0.9%) █████████░ 86.9% of 16.44 MiB
events scene
src/scenes/activity/explore/EventsScene.tsx
10.72 MiB · 4,084 files 🟢 -176.4 KiB (-1.6%) ████████░░ 84.8% of 12.64 MiB
replay detail scene
src/scenes/session-recordings/detail/SessionRecordingDetail.tsx
13.64 MiB · 5,013 files 🟢 -137.0 KiB (-1.0%) █████████░ 86.8% of 15.72 MiB

🟢 node_modules/monaco-editor/ stays out of src/index.tsx
🟢 src/lib/components/ActivityLog/describers stays out of src/index.tsx
🟢 [object Object] stays out of src/index.tsx
🟢 [object Object] stays out of src/index.tsx
🟢 node_modules/monaco-editor/ stays out of src/index.tsx + src/scenes/App.tsx + src/scenes/bootApp.ts
🟢 src/layout/navigation-3000/navigationLogic.tsx stays out of src/index.tsx + src/scenes/App.tsx + src/scenes/bootApp.ts
🟢 src/scenes/dashboard/dashboardLogic.tsx stays out of src/index.tsx + src/scenes/App.tsx + src/scenes/bootApp.ts
🟢 src/lib/lemon-ui/LemonMarkdown/ stays out of src/index.tsx + src/scenes/App.tsx + src/scenes/bootApp.ts
🟢 src/lib/components/RichContentEditor/ stays out of src/index.tsx + src/scenes/App.tsx + src/scenes/bootApp.ts
🟢 src/lib/components/CodeSnippet/ stays out of src/index.tsx + src/scenes/App.tsx + src/scenes/bootApp.ts
🟢 src/taxonomy/core-filter-definitions-by-group.json stays out of src/index.tsx + src/scenes/App.tsx + src/scenes/bootApp.ts
🟢 node_modules/monaco-editor/ stays out of src/scenes/AuthenticatedShell.tsx
🟢 src/lib/components/ActivityLog/describers stays out of src/scenes/AuthenticatedShell.tsx
🟢 [object Object] stays out of src/scenes/AuthenticatedShell.tsx
🟢 src/scenes/session-recordings/player/sessionRecordingPlayerLogic.ts stays out of src/scenes/AuthenticatedShell.tsx
🟢 [object Object] stays out of src/scenes/AuthenticatedShell.tsx
🟢 [object Object] stays out of src/scenes/AuthenticatedShell.tsx
🟢 [object Object] stays out of src/scenes/AuthenticatedShell.tsx

Largest files eagerly shipped from src/index.tsx
Size File
126.8 KiB ../node_modules/.pnpm/react-dom@18.3.1_react@18.3.1/node_modules/react-dom/cjs/react-dom.production.min.js
24.6 KiB ../node_modules/.pnpm/buffer@6.0.3/node_modules/buffer/index.js
6.3 KiB ../node_modules/.pnpm/react@18.3.1/node_modules/react/cjs/react.production.min.js
4.5 KiB ../node_modules/.pnpm/@jspm+core@2.1.0/node_modules/@jspm/core/nodelibs/browser/process.js
3.9 KiB ../node_modules/.pnpm/scheduler@0.23.2/node_modules/scheduler/cjs/scheduler.production.min.js
1.4 KiB ../node_modules/.pnpm/base64-js@1.5.1/node_modules/base64-js/index.js
1.3 KiB src/index.tsx
1.3 KiB src/RootErrorBoundary.tsx
912 B ../node_modules/.pnpm/ieee754@1.2.1/node_modules/ieee754/index.js
854 B src/scenes/ChunkLoadErrorBoundary.tsx
Largest files eagerly shipped from src/index.tsx + src/scenes/App.tsx + src/scenes/bootApp.ts
Size File
306.2 KiB ../node_modules/.pnpm/posthog-js@1.435.5_@types+react@18.3.27_react@18.3.1/node_modules/posthog-js/dist/module.mjs
219.9 KiB ../node_modules/.pnpm/@posthog+icons@0.38.0_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@posthog/icons/dist/posthog-icons.es.js
126.8 KiB ../node_modules/.pnpm/react-dom@18.3.1_react@18.3.1/node_modules/react-dom/cjs/react-dom.production.min.js
100.5 KiB src/lib/api.ts
91.9 KiB src/products.tsx
69.4 KiB src/lib/lemon-ui/icons/icons.tsx
40.1 KiB src/lib/utils/eventUsageLogic.ts
38.7 KiB ../node_modules/.pnpm/@dnd-kit+core@6.0.8_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@dnd-kit/core/dist/core.esm.js
33.9 KiB ../node_modules/.pnpm/kea@4.0.0-pre.6_patch_hash=139b8d1f1304f9d9da452a9a1244c94ea679dbcb85687d8999563146879fb6f5_react@18.3.1/node_modules/kea/lib/index.cjs.js
28.7 KiB src/scenes/scenes.ts
Largest files eagerly shipped from src/scenes/AuthenticatedShell.tsx
Size File
306.2 KiB ../node_modules/.pnpm/posthog-js@1.435.5_@types+react@18.3.27_react@18.3.1/node_modules/posthog-js/dist/module.mjs
279.9 KiB src/taxonomy/core-filter-definitions-by-group.json
219.9 KiB ../node_modules/.pnpm/@posthog+icons@0.38.0_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@posthog/icons/dist/posthog-icons.es.js
153.7 KiB ../node_modules/.pnpm/re2js@0.4.1/node_modules/re2js/build/index.esm.js
126.8 KiB ../node_modules/.pnpm/react-dom@18.3.1_react@18.3.1/node_modules/react-dom/cjs/react-dom.production.min.js
109.9 KiB ../packages/quill/packages/quill/dist/index.js
100.5 KiB src/lib/api.ts
93.3 KiB ../node_modules/.pnpm/prosemirror-view@1.40.1/node_modules/prosemirror-view/dist/index.js
91.9 KiB src/products.tsx
90.6 KiB ../node_modules/.pnpm/@tiptap+core@3.20.6_@tiptap+pm@3.20.6/node_modules/@tiptap/core/dist/index.js
Largest files eagerly shipped from src/scenes/dashboard/Dashboard.tsx
Size File
315.5 KiB ../node_modules/.pnpm/posthog-js@1.435.5_@types+react@18.3.27_react@18.3.1/node_modules/posthog-js/dist/rrweb.js
306.2 KiB ../node_modules/.pnpm/posthog-js@1.435.5_@types+react@18.3.27_react@18.3.1/node_modules/posthog-js/dist/module.mjs
279.9 KiB src/taxonomy/core-filter-definitions-by-group.json
219.9 KiB ../node_modules/.pnpm/@posthog+icons@0.38.0_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@posthog/icons/dist/posthog-icons.es.js
181.8 KiB src/queries/validators.js
153.7 KiB ../node_modules/.pnpm/re2js@0.4.1/node_modules/re2js/build/index.esm.js
126.8 KiB ../node_modules/.pnpm/react-dom@18.3.1_react@18.3.1/node_modules/react-dom/cjs/react-dom.production.min.js
109.9 KiB ../packages/quill/packages/quill/dist/index.js
100.5 KiB src/lib/api.ts
93.3 KiB ../node_modules/.pnpm/prosemirror-view@1.40.1/node_modules/prosemirror-view/dist/index.js
Largest files eagerly shipped from src/scenes/project-homepage/ProjectHomepage.tsx
Size File
315.5 KiB ../node_modules/.pnpm/posthog-js@1.435.5_@types+react@18.3.27_react@18.3.1/node_modules/posthog-js/dist/rrweb.js
306.2 KiB ../node_modules/.pnpm/posthog-js@1.435.5_@types+react@18.3.27_react@18.3.1/node_modules/posthog-js/dist/module.mjs
279.9 KiB src/taxonomy/core-filter-definitions-by-group.json
219.9 KiB ../node_modules/.pnpm/@posthog+icons@0.38.0_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@posthog/icons/dist/posthog-icons.es.js
181.8 KiB src/queries/validators.js
153.7 KiB ../node_modules/.pnpm/re2js@0.4.1/node_modules/re2js/build/index.esm.js
126.8 KiB ../node_modules/.pnpm/react-dom@18.3.1_react@18.3.1/node_modules/react-dom/cjs/react-dom.production.min.js
109.9 KiB ../packages/quill/packages/quill/dist/index.js
100.5 KiB src/lib/api.ts
93.3 KiB ../node_modules/.pnpm/prosemirror-view@1.40.1/node_modules/prosemirror-view/dist/index.js
Largest files eagerly shipped from src/scenes/activity/explore/EventsScene.tsx
Size File
315.5 KiB ../node_modules/.pnpm/posthog-js@1.435.5_@types+react@18.3.27_react@18.3.1/node_modules/posthog-js/dist/rrweb.js
306.2 KiB ../node_modules/.pnpm/posthog-js@1.435.5_@types+react@18.3.27_react@18.3.1/node_modules/posthog-js/dist/module.mjs
279.9 KiB src/taxonomy/core-filter-definitions-by-group.json
219.9 KiB ../node_modules/.pnpm/@posthog+icons@0.38.0_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@posthog/icons/dist/posthog-icons.es.js
181.8 KiB src/queries/validators.js
153.7 KiB ../node_modules/.pnpm/re2js@0.4.1/node_modules/re2js/build/index.esm.js
126.8 KiB ../node_modules/.pnpm/react-dom@18.3.1_react@18.3.1/node_modules/react-dom/cjs/react-dom.production.min.js
109.9 KiB ../packages/quill/packages/quill/dist/index.js
100.5 KiB src/lib/api.ts
93.3 KiB ../node_modules/.pnpm/prosemirror-view@1.40.1/node_modules/prosemirror-view/dist/index.js
Largest files eagerly shipped from src/scenes/session-recordings/detail/SessionRecordingDetail.tsx
Size File
315.5 KiB ../node_modules/.pnpm/posthog-js@1.435.5_@types+react@18.3.27_react@18.3.1/node_modules/posthog-js/dist/rrweb.js
306.2 KiB ../node_modules/.pnpm/posthog-js@1.435.5_@types+react@18.3.27_react@18.3.1/node_modules/posthog-js/dist/module.mjs
279.9 KiB src/taxonomy/core-filter-definitions-by-group.json
219.9 KiB ../node_modules/.pnpm/@posthog+icons@0.38.0_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@posthog/icons/dist/posthog-icons.es.js
181.8 KiB src/queries/validators.js
153.7 KiB ../node_modules/.pnpm/re2js@0.4.1/node_modules/re2js/build/index.esm.js
126.8 KiB ../node_modules/.pnpm/react-dom@18.3.1_react@18.3.1/node_modules/react-dom/cjs/react-dom.production.min.js
109.9 KiB ../packages/quill/packages/quill/dist/index.js
100.5 KiB src/lib/api.ts
93.3 KiB ../node_modules/.pnpm/prosemirror-view@1.40.1/node_modules/prosemirror-view/dist/index.js

Posted automatically by check-eager-graph · sizes are eager output bytes (shipped, post-tree-shake) from the esbuild metafile · part of #32479

✅ Toolbar bundle — eager 2.19 MiB within budget

What the toolbar ships to customer pages, measured from the esbuild output (minified, post-tree-shake). The eager set is the entry plus everything statically imported from it — fetched before any feature runs; deferred chunks load lazily. The eager guardrail is 5.72 MiB. Each output file must also stay below 10 MB, where CloudFront stops compressing it. The module boundary is enforced separately by check-toolbar-graph.

Metric Size Δ vs base Budget
Eager (shipped)
entry + static imports
2.19 MiB · 19 files no change ████░░░░░░ 38.3% of 5.72 MiB
Deferred (lazy) 2.10 MiB · 44 files no change n/a — loads on demand
Loader dist/toolbar.js 1.2 KiB no change █░░░░░░░░░ 6.0% of 19.5 KiB
Largest eagerly-shipped chunks
Size File
830.3 KiB dist/toolbar/toolbar-app-LYCS7NJJ.css
656.8 KiB dist/toolbar/chunk-chunk-O6SCHU33.js
259.4 KiB dist/toolbar/chunk-chunk-6WGZ4M27.js
138.2 KiB dist/toolbar/chunk-chunk-5NW543U7.js
131.8 KiB dist/toolbar/chunk-chunk-FDH2IBXT.js
75.2 KiB dist/toolbar/toolbar-app-XPVDG57Y.js
69.0 KiB dist/toolbar/chunk-chunk-TSAL54PB.js
35.6 KiB dist/toolbar/chunk-chunk-Y5MCMH2E.js
21.0 KiB dist/toolbar/chunk-chunk-7Y6KIVPX.js
6.8 KiB dist/toolbar/chunk-chunk-DV7IWQNF.js

Posted automatically by check-toolbar-size · sizes are toolbar output bytes (shipped, post-tree-shake) from the esbuild metafile

✅ Dist folder size — 🟢 -3.1 KiB (-0.0%)

Total size of the built frontend/dist folder (all assets), compared against the base branch.

Total: 965.51 MiB · 🟢 -3.1 KiB (-0.0%)

✅ Playwright — all passed

All tests passed.

View test results →

@pauldambra
pauldambra marked this pull request as ready for review October 1, 2026 21:26
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Oct 1, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-10-01T21:32:35.185684Z df69289 Draft marked ready
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@github-actions
github-actions Bot requested a deployment to preview-pr-110356 October 1, 2026 21:27 In progress
@github-actions

github-actions Bot commented Oct 1, 2026 •

Copy link
Copy Markdown
Contributor

🦔 Hogbox preview · ✅ ready

▶ Open the preview

🔑 Login test@posthog.com / 12345678 (demo data)
🧩 Running this PR's backend and frontend, on the PostHog :master base
🔗 Link stable across rebuilds — a re-push swaps the box underneath, the URL stays
🔒 Access tailnet only (PostHog VPN)
🛠️ Admin inspect & debug state in hogland
💤 Idle sleeps after ~30 min idle (snapshot to S3, zero node cost) and wakes on your next visit in ~30s, behind a brief "waking up" screen

commit 5046c3e · box box-2300d48978bd · ready in 828s (push → usable) · build log · rebuilds on every push, torn down on close

@coderabbitai

coderabbitai Bot commented Oct 1, 2026 •

Copy link
Copy Markdown
Contributor

Review in Change Stack →

Navigate logical layers of code changes, visualize relationships, and explore their blast radius.

🧰 Additional context used
📚 Code guidelines (12)
.cursor/rules/react-typescript.mdc — auto-discovered
.agents/skills/using-kea-disposables/SKILL.md — configured
.agents/skills/writing-ui-components/SKILL.md — configured
.agents/security.md — configured
docs/published/handbook/engineering/type-system.md — configured
.agents/skills/writing-tests/SKILL.md — configured
.agents/skills/adopting-generated-api-types/SKILL.md — configured
.agents/skills/placing-product-frontend-code/SKILL.md — configured
.claude/commands/conventions.md — configured
.agents/skills/writing-kea-logics/SKILL.md — configured
.agents/skills/writing-user-facing-copy/SKILL.md — configured
.agents/skills/writing-code-comments/SKILL.md — configured

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Repository: PostHog/posthog/.coderabbit.yaml

Review profile: QUIET

Plan: Enterprise

Run ID: 95889099-1c4a-47b1-ad96-4b089188f6fe

📥 Commits

Reviewing files that changed from the base of the PR and between df69289 and 5046c3e.

📒 Files selected for processing (3)
  • frontend/src/queries/nodes/DataTable/DataTable.tsx
  • frontend/src/queries/nodes/DataTable/ExpandedEventRow.test.tsx
  • frontend/src/queries/nodes/DataTable/ExpandedEventRow.tsx

Included review availability: This review used your included allowance. Your plan provides up to 12 included reviews per hour; 5 remain after this review.


📝 Walkthrough

Walkthrough

DataTable selects an event from array-shaped or object-shaped results for an expanded row. ExpandedEventRow lazy-loads EventDetails and shows a spinner while it loads. If the chunk fails to load, the component displays a warning with a page-reload action. A test verifies that this error does not replace the table.

Priority: ➖ Normal

Merge Risk: ⚪ Minimal · up to 5046c

Event details now load on expansion, with a spinner and a local reload warning if loading fails. No actionable merge-blocking risk is identified; merge after normal checks.

Security Architecture Review

Security architecture risk: 🔵 Low · up to 5046c

The change preserves event selection and existing rendering behavior without demonstrating new access or privileges. The main uncertainty is recovery during stale deployments or repeated loading failures, which has not been checked in a browser.

Retained concerns
No architecture-level concerns identified.

Security review details

Security Blast Radius

  • inferred — The direct new failure surface is browser-side event-detail availability. Fallback rendering is row-local, but automatic recovery reloads the whole page and uses browser-origin localStorage shared beyond an individual row.

Trust Boundaries and Controls

  • observed — The new boundary contains recognized chunk failures rather than changing data-access authority. Non-chunk rendering errors are rethrown to the existing outer error handling instead of being converted into a reload warning.

Resilience and Maintainability Implications

  • inferred — The lazy component is shared at module scope, so collapsing and reopening a row does not create a fresh loader after a cached rejection. Full-page reload is the explicit recovery path, while the local warning preserves access to the table.
🚥 Pre-merge checks | ✅ 1
✅ Passed checks (1 passed)
Check name Status Explanation
Description check ✅ Passed The description covers the problem, user-visible changes, testing, release status, and agent context. It is mostly complete, but the test rationale says no new test was added even though the PR adds E…
✨ Finishing Touches
📝 Generate docstrings
  • Commit to this branch
  • Create a new PR
🧪 Generate unit tests (beta)
  • Commit to this branch
  • Create a new PR
  • Autopilot · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Autopilot is currently an internal CodeRabbit preview.


Comment @coderabbitai help to get the list of available commands.

…onent

The lazy EventDetails wrapper lived inline in DataTable as a module-scope
component plus an expandedRowRender closure, so nothing covered the
ChunkLoadErrorBoundary fallback that keeps the table on screen when the chunk
fails after a reload. It moves to ExpandedEventRow with a focused test, the
same shape as the AI observability cell fallback test.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>

Generated-By: PostHog Desktop
Task-Id: acec8cb2-f000-4747-a659-05b72b42513e
@parameterai

parameterai Bot commented Oct 1, 2026

Copy link
Copy Markdown

Risk: No findings

This increment extracts the inline expanded-row rendering from DataTable into a new ExpandedEventRow component (identical behavior: lazy-loaded EventDetails behind ChunkLoadErrorBoundary with a reload fallback) and adds a test for the stale-chunk path. It is a behavior-preserving refactor with no new security surface.

Sentinel reviewed 5046c3e · Review settings

@trunk-io

trunk-io Bot commented Oct 1, 2026 •

Copy link
Copy Markdown

Static Badge   Static Badge   Static Badge

Failed Test Failure Summary Logs
Scenes/Code review Default play-test The test failed because a logic component was not mounted when accessed, and there were unhandled network requests intercepted by the mock service... Logs ↗︎

View Full Report ↗︎ ⋅ Docs

Copy link
Copy Markdown
Member Author

Note

🤖 Automated comment by QA Swarm — not written by a human

Router pass over the full diff, then a second pass over the fix commits. No delegated lenses: danger graded LOW.

Verdict: ✅ APPROVE (@ 5046c3e)

One LOW finding: the lazy row's fallback had no test, unlike the AI observability cell. Fixed in 5046c3e by extracting ExpandedEventRow with a focused test; re-reviewed clean.

Checked against the lazy-load checklist from the #110093–#110095 reviews: lazyWithRetry for every dynamic import, a ChunkLoadErrorBoundary with a fallback inside query and card error boundaries, loading only on open or expand, no change to modal props or styles, and no imports left at moved paths.


Automated by QA Swarm — not a human review

@pauldambra pauldambra added the stamphog Request AI approval (no full review) label Oct 1, 2026 — with PostHog

@stamphog stamphog Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Approved.

Contained frontend perf change that lazy-loads the expanded row details using the existing retry and chunk-error helpers. It outside risky territory, behavior is preserved, a fallback test is included, and no reviewer raised concerns.

  • 👍 on the PR from chatgpt-codex-connector[bot].
Gate mechanics and policy version
Gate Result
prerequisites ✓ all clear
deny-list ✓ no deny categories matched
size ✓ 50L, 2F substantive, 106L/3F incl. docs/generated/snapshots — within ceiling
tier ✓ T1-agent / T1c-medium (106L, 3F, single-area, perf)
stamphog 2.3.1 .stamphog/policy.yml @ 5046c3e · reviewed head 5046c3e

@trunk-io
trunk-io Bot merged commit 8524659 into master Oct 2, 2026
252 checks passed
@trunk-io
trunk-io Bot deleted the posthog/lazy-event-details branch October 2, 2026 09:26
@deployment-status-posthog

deployment-status-posthog Bot commented Oct 2, 2026 •

Copy link
Copy Markdown

Deploy status

Environment Status Deployed At Workflow
dev ✅ Deployed 2026-10-02 09:51 UTC Run
prod-us ✅ Deployed 2026-10-02 10:01 UTC Run
prod-eu ✅ Deployed 2026-10-02 10:03 UTC Run

This branch was successfully deployed

1 active deployment
preview-pr-110356 — 5046c3e3 Deployed Oct 1, 2026 by github-actions[bot]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

stamphog Request AI approval (no full review)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant