Skip to content

docs: ask users to review before_send hooks for the v1 event shape - #1159

Merged
eli-r-ph merged 1 commit into
v1from
eli/v1-guide-before-send-shape
Nov 2, 2026
Merged

eli-r-ph merged 1 commit into
v1from
eli/v1-guide-before-send-shape

Conversation

@eli-r-ph

@eli-r-ph eli-r-ph commented Oct 30, 2026 •

Copy link
Copy Markdown
Contributor

💡 Motivation and Context

In v1, before_send sees the event's options, and nothing is added back after it runs. The personless marker moved from a property into options, so a hook written for the old shape that rebuilds the event from its properties now sends no options. That includes the SDK's process_person_profile: false for an event with no distinct ID, so PostHog creates a person for the generated ID. The guide now asks users to review their hooks for the new event shape and to change options through options, not legacy properties.

💚 How did you test it?

Docs only.

📝 Checklist

  • All commits are signed (see Commit signing)
  • I reviewed the submitted code.
  • I added tests to verify the changes.
  • I updated the docs if needed.
  • No breaking change or entry added to the changelog.

If releasing new changes

  • Ran sampo add to generate a changeset file

🤖 Agent context

Autonomy: Human-driven (agent-assisted)

  • Written with Claude Code (claude-opus-5-5). The drop was checked against the hook code on v1: the event the hook returns is the one sent, and no SDK value is re-added after it.

🤖 Generated with Claude Code

@eli-r-ph eli-r-ph self-assigned this Oct 30, 2026
@eli-r-ph
eli-r-ph requested a review from a team as a code owner October 30, 2026 18:18

@dustinbyrne dustinbyrne left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

The migration warning matches v1’s hook and options handling. No issues found in this documentation-only change.

AI-assisted review.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@eli-r-ph
eli-r-ph force-pushed the eli/v1-guide-before-send-shape branch from e5d3c99 to 68b8421 Compare November 2, 2026 17:10
@eli-r-ph
eli-r-ph merged commit 3f37e3d into v1 Nov 2, 2026
40 checks passed
@eli-r-ph
eli-r-ph deleted the eli/v1-guide-before-send-shape branch November 2, 2026 17:33
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