Repository navigation
feat!: default identify-style events to person processing on - #1247
Conversation
The migration guide is also published on posthog.com, where the relative link resolves to a missing page. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> (cherry picked from commit f143283)
The posthog.com Python SDK pages redirect to this reference once 8.0.0 ships, so their setup, how-to, and configuration sections now live in docs/getting-started.md. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> (cherry picked from commit 9db7014)
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> (cherry picked from commit 0e9f755)
…d page" This reverts commit 7abca08.
This reverts commit bc7bc9c.
…other page has Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The reference renders each docstring under its entry, per major, so the tracing, ASGI, keepalive, and AsyncPosthog facts now live there. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
$identify, $create_alias, $merge_dangerously, $groupidentify, $set and $set_once now resolve process_person_profile from the call alone before any layer fills: a non-null call option wins, else a non-null call $process_person_profile property moves into the option, else the option is true unless the SDK generated the distinct ID. Context options and tags, super_options and super_properties can no longer turn person processing off for these events. before_send still sees the value and has the final say. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…0 guide Replaces the guidance that layered process_person_profile false reaches alias, group_identify, set and set_once and needs a per-call true, and regenerates the 8.x and migration references. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
SDK performance: posthog-python1 change worth reviewing: 1 observed regression. Flags require at least a 5% change in the median and all six pairs agreeing on direction. This is a noise filter, not proof of a performance change or a CI gate.
View all results
Values are medians of paired measurements. Not flagged does not mean unchanged. Unavailable means a measurement could not be provided, not zero. Estimated allocation measurements retain their instrumentation uncertainty. RSS measures the whole process, not just SDK allocations; observed peaks are sampled checkpoints. Paired ranges in the diagnostics describe variability, not confidence intervals. Each shard uses its own runner; compare Before PR against With PR within a row, not across shards. Compared 102 metric rows; 102 rows shown in all results. Omitted or shortened data remain in |
…vents After the layers fill, an identify-style event whose process_person_profile option is set loses its $process_person_profile property, so before_send sees one value and a hook that drops options cannot send a layered legacy false. Event defaults now take one personless flag, which sets both the personless option layer and the generated-id check. Option layer docstrings say they never set process_person_profile on these events. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Moves the release note into identity-and-context-rules, notes that before_send sees only the option, and regenerates the 8.x and migration references. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Context options and super_options still fill process_person_profile on an identify-style event whose distinct ID the SDK generated, so the release note, guide, AGENTS.md and option docstrings now say so, and a test pins it. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Keeps both new generator functions (migration_page, getting_started) and their tests. The guide keeps this branch's text; its Celery eager line already carries #1232's wording. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…rted guide The sorted 8.0.0 guide dropped facts the v1 guide states: the self-hosted capture v1 route check, the 404 hint, the 400 duplicate_event_uuid on older PostHog, the legacy path removal, and NaN as null since 7.75.0. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…rted guide Identify-style events now default process_person_profile to true unless the call sets it or the SDK generated the distinct ID, so layered false no longer reaches them. Replaces the old reach rules and opt-in sample, and updates the checklist row, precedence step 1 and the before_send section. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
start_span evicts spans older than max_span_age first and returns an unrecorded span only if still at max_live_spans. A full span keeps the exception message in its status and loses only the type and stack trace. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Generated with bin/docs_scripts/generate_markdown.py --major 8. The migration page now carries the sorted guide, which it had not before. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…onless Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…he option Only capture and capture_ai take event properties. The properties of set, set_once and group_identify are person and group properties. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
…he option Only capture and capture_ai take event properties. The properties of set, set_once and group_identify are person and group properties. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
Each entry is now a CaptureDroppedEvent named tuple with uuid and details, so code that unpacks or compares (uuid, details) tuples keeps working. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
…-structure Stacks the sorted guide on the identify-style person processing default and the CaptureDroppedEvent change. The guide keeps the sorted text, which already describes the default. References regenerated. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
…he guide Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
Compression formats including zstd, the proxy pass-through rule, and that a `$set` in a global or context layer reaches every event. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
…es and semicolons Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The 8.x page is titled "PostHog Python SDK 8.x" before and after the release. Regenerating also picks up the self-hosted paragraph the migration guide's source already dropped. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…identify "so set the option there" read as setting it in properties, where the SDK treats it as a person property. set, set_once, and group_identify take options, so the guide now names them. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Vincent ruled out self-hosted framing in the guides, and the endpoint and 404 sentences read as self-host framing. The retry tables and the proxy notes stay. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
💡 Motivation and Context
In posthog-python 8.0, a
process_person_profile: Falseset insuper_options,super_properties, a context option or a context tag reachesalias,group_identify,setandset_once. PostHog then drops those events or ignores their person update, so an app that turns person processing off globally silently stops identifying users.$identify,$create_alias,$merge_dangerously,$groupidentify,$set,$set_once) now default toprocess_person_profile: True, from any method, unless the call sets it.$process_person_profileproperty becomes the option and is removed from the properties;Nonecounts as unset.False.before_sendsees the value and can change it. The default is decided from the event name the call used, so a hook that renames an event or builds an identify-style event sets the option itself._default_identify_style_person_processingincapture_event.py, runs at the top of_fill_event_defaults, before any layer, in both the sync and async clients.personlessflag replaces the old derived personless options, and drives both the personless layer and the generated-ID check._fill_event_defaults, a$process_person_profileproperty left bysuper_propertiesor a context tag is removed from these events once the option is set.before_sendsees one value, and a hook that dropsoptionscan't bring back a layeredFalse. The wire output is unchanged.Truereaches ingestion the same way as no value, except that it replaces a layeredFalse. Server-side opt-outs still win.--major 8). The existingidentity-and-context-ruleschangeset gains the exception, with no new changeset, because this lands in 8.0.💚 How did you test it?
test_event_options.pycases, through the public API to the v1 wire payload, sync and async:None;$<type>_<key>group fallback;before_sendseeing and changing the value;before_sendrename;False;event_family.jsonsnapshot, are updated to the new behavior.pytest: 7,673 passed; 3 failed, the macOS-only fork tests intest_metrics_autocapture.py, which fail identically onv1;ruff check,ruff format --check, mypy,make public_api_check: all pass.📝 Checklist
If releasing new changes
sampo addto generate a changeset file (not needed: an existing 8.0 changeset is updated)🤖 Agent context
Autonomy: Human-driven (agent-assisted)
Written with Claude Code (Claude Opus 5.5) at Eli's direction, as part of the capture v1 release. The rule, the event list and the generated-ID exception were decided by Eli. The SDK-side check runs before any layer so only the call's own value counts. Always sending
Truewas chosen over sending it only when a layer would set another value, because the backend treats an explicitTruelike an unset value for these events.🤖 Generated with Claude Code