Skip to content

fix(inbox): track signal_report_id on Create PR task_created event#2458

Merged
andrewm4894 merged 1 commit into
mainfrom
fix/inbox-create-pr-tracking-parity
Jun 2, 2026
Merged

fix(inbox): track signal_report_id on Create PR task_created event#2458
andrewm4894 merged 1 commit into
mainfrom
fix/inbox-create-pr-tracking-parity

Conversation

@andrewm4894

Copy link
Copy Markdown
Member

Summary

Brings the Create PR inbox action to tracking parity with Discuss.

Both inbox actions fire a task_created analytics event on success, but the Create PR flow (useCreatePrReport.ts) omitted signal_report_id, while Discuss (useDiscussReport.ts) includes it. That left created-PR-from-inbox tasks unattributable to their originating report when analyzing the task_created event (funnels, attribution), even though the linkage exists on the task record itself via signalReportId in TaskCreationInput.

This adds signal_report_id: reportId to the Create PR task_created event — a one-line change. signal_report_id is already a valid optional property on TaskCreateProperties.

Before / after

  cloud_run_source: "signal_report",
  cloud_pr_authorship_mode: "user",
+ signal_report_id: reportId,
  adapter,

Notes

  • The other inbox tracking layer (inbox_report_action via fireDetailAction) already covers both buttons correctly; Discuss only differs there by has_question/question_text, which is expected (PR has no free-text question).
  • Pre-commit hook was bypassed because a repo-wide typecheck currently fails on pre-existing, unrelated errors in @posthog/agent (Claude Agent SDK type mismatches). This change only touches a renderer hook and does not affect those.

Test plan

  • Create a PR from an inbox report and confirm the task_created event carries signal_report_id.

The Discuss flow attaches signal_report_id to its task_created analytics
event, but the Create PR flow omitted it, leaving created-PR tasks
unattributable to their originating inbox report from that event. Add the
property to bring Create PR to parity with Discuss.
@andrewm4894 andrewm4894 self-assigned this Jun 2, 2026
@andrewm4894 andrewm4894 requested a review from a team June 2, 2026 09:43
@greptile-apps

greptile-apps Bot commented Jun 2, 2026

Copy link
Copy Markdown
Contributor

Reviews (1): Last reviewed commit: "fix(inbox): include signal_report_id in ..." | Re-trigger Greptile

@andrewm4894 andrewm4894 enabled auto-merge (squash) June 2, 2026 09:49
@andrewm4894 andrewm4894 merged commit fa2b684 into main Jun 2, 2026
15 checks passed
@andrewm4894 andrewm4894 deleted the fix/inbox-create-pr-tracking-parity branch June 2, 2026 09:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants