Skip to content

fix(agent): add session initialization timeout diagnostics - #3962

Merged
trunk-io[bot] merged 3 commits into
mainfrom
posthog-code/add-session-init-timeout-diagnostics
Jul 30, 2026
Merged

fix(agent): add session initialization timeout diagnostics#3962
trunk-io[bot] merged 3 commits into
mainfrom
posthog-code/add-session-init-timeout-diagnostics

Conversation

@tatoalo

@tatoalo tatoalo commented Jul 29, 2026

Copy link
Copy Markdown
Contributor

Problem

session initialization timeouts currently surface a generic error. This makes it difficult to tell whether SDK startup, model configuration, or gateway setup stalled.

Changes

  • Add structured initialization phase, timing, model, timeout, and gateway-presence fields to failure logs
  • Preserve query termination behavior and add regression coverage for timed-out initialization

@trunk-io

trunk-io Bot commented Jul 29, 2026

Copy link
Copy Markdown

😎 Merged successfully - details.

@github-actions

github-actions Bot commented Jul 29, 2026

Copy link
Copy Markdown

React Doctor found no issues in the changed files. 🎉

Reviewed by React Doctor for commit 1f97624.

@tatoalo
tatoalo marked this pull request as ready for review July 29, 2026 16:15
@greptile-apps

greptile-apps Bot commented Jul 29, 2026

Copy link
Copy Markdown
Contributor

Reviews (1): Last reviewed commit: "fix(agent): add session initialization t..." | Re-trigger Greptile

@tatoalo tatoalo self-assigned this Jul 29, 2026
@tatoalo tatoalo added the Stamphog This will request an autostamp by stamphog on small changes label Jul 30, 2026
tatoalo added 3 commits July 30, 2026 09:56
Generated-By: PostHog Code
Task-Id: cd137de1-90a0-4cb9-8509-56f5f210c0e9
Generated-By: PostHog Code
Task-Id: cd137de1-90a0-4cb9-8509-56f5f210c0e9
Generated-By: PostHog Code
Task-Id: cd137de1-90a0-4cb9-8509-56f5f210c0e9
@tatoalo
tatoalo force-pushed the posthog-code/add-session-init-timeout-diagnostics branch from d667a11 to 1f97624 Compare July 30, 2026 08:56

@github-actions github-actions 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.

Additive diagnostic logging and telemetry for session-initialization failures across three agent adapters, with matching regression tests (including an explicit test that secret error detail is never exported via telemetry); no auth, billing, crypto, dependency, CI, or API-contract changes, and diff matches the description.

  • Author wrote 0% of the modified lines and has 105 merged PRs in these paths (familiarity MODERATE).
  • 👍 on the PR from greptile-apps[bot].
Gate mechanics and policy version
Gate Result
prerequisites all clear
deny-list no deny categories matched
size 165L, 6F substantive, 399L/11F incl. docs/generated/snapshots — within ceiling
tier T1-agent / T1d-complex (399L, 11F, single-area, fix)
stamphog 2.0.0b3 .stamphog/policy.yml @ d4ace51 · reviewed head 1f97624

@tatoalo
tatoalo enabled auto-merge (squash) July 30, 2026 09:37
@trunk-io
trunk-io Bot merged commit f4fec98 into main Jul 30, 2026
34 checks passed
@trunk-io
trunk-io Bot deleted the posthog-code/add-session-init-timeout-diagnostics branch July 30, 2026 09:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Stamphog This will request an autostamp by stamphog on small changes

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant