Repository navigation
fix(android): make the posthog-android 4.x range strict - #729
Merged
turnipdabeets merged 1 commit intoNov 13, 2026
Merged
turnipdabeets merged 1 commit into
turnipdabeets merged 1 commit into
Conversation
A plain range lets Gradle raise posthog-android past 4.x when something else in the app asks for a newer major, and the plugin, compiled against 4.x, would crash at runtime instead of failing the build. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
3 of 6 tasks
Contributor
posthog-flutter Compliance ReportDate: 2026-11-12T21:12:37.006230+00:00 ✅ All Tests Passed!232/232 tests passed Capture_V1 Tests✅ 105/105 tests passed View Details
Capture_Ai_V1 Tests✅ 110/110 tests passed View Details
Feature_Flags Tests✅ 17/17 tests passed View Details
|
turnipdabeets
marked this pull request as ready for review
November 12, 2026 23:08
PR overviewNo security issues were found in this pull request. Reviews
|
There was a problem hiding this comment.
Approved.
The disclosed dependency and build changes enter risky territory, but current-head reviewer assurance and STRONG author familiarity cover the change. No unresolved substantive concerns or other refusal grounds were found.
- Author wrote 100% of the modified lines and has 30 merged PRs in these paths (familiarity STRONG).
- PostHog Review (Standard) reviewed the current head: no findings.
Gate mechanics and policy version
| Gate | Result | |
|---|---|---|
| prerequisites | ✓ | all clear |
| deny-list | ✓ | no deny categories matched |
| size | ✓ | 6L, 1F substantive, 7L/2F incl. docs/generated/snapshots — within ceiling |
| tier | ✓ | T1-agent / T1b-small (7L, 2F, two-areas, fix) |
| stamphog 2.8.0 | .stamphog/policy.yml @ 5d52818 · reviewed head 5d52818 |
dustinbyrne
approved these changes
Nov 13, 2026
turnipdabeets
deleted the
fix/v6-android-strict-posthog-android-range
branch
November 13, 2026 17:58
6 of 17 tasks
turnipdabeets
added a commit
that referenced
this pull request
Nov 13, 2026
Keeps this branch's restructured MIGRATION.md and changeset, and carries over what changed on #637 since the last merge: - #730: a registered process_person_profile no longer applies to identity events, so "Fix identity calls" becomes "Check registered person processing" and the identify example goes away - #729: Android build fails instead of crashing past posthog-android 4.x - e1178f8: iOS add-to-app modules work on Flutter 3.50.0 - 862cdd3: capture v1 link points at /docs/api/capture-v1 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
💡 Motivation and Context
Stacked on #637 (posthog_flutter 6). Same fix as #728 for 5.x, on 6's
[4.0.0,5.0.0)range.A plain Gradle range isn't a ceiling: when anything else in the app asks for a newer posthog-android major, Gradle picks the highest version. The plugin compiles in its own Gradle project against 4.x, so the build succeeds and the app crashes at runtime. #728 confirmed this with posthog_flutter 5.60.2 next to posthog-android 4.0.
strictly '[4.0.0,5.0.0)'turns that into a dependency resolution error. It also stops a posthog-android 5.0 from slipping into a 6.x app later.An app that still declares posthog-android 3.x natively still resolves 4.x here: the strict range wins over its plain version.
Adds one line to
.changeset/v6-major-release.md.💚 How did you test it?
With posthog-android 4.0.0 and core 7.0.0 built from PostHog/posthog-android#871 and published to a scratch Maven repo (the example's
repositorieschange was local only and isn't committed):flutter build apk --debuginexample/builds.dependencyInsightshowscom.posthog:posthog-android:{strictly [4.0.0,5.0.0)} -> 4.0.0.:posthog_flutter:testDebugUnitTestpasses.📝 Checklist
If releasing new changes
pnpm changesetto generate a changeset file (added a line to the existingv6-major-release.md)🤖 Agent context
Autonomy: Human-driven (agent-assisted)
Claude Code (Claude Opus 5.5) made this alongside #728 after the posthog-android 4.0 wrapper checks. No added test, for the same reason as #728: it's Gradle resolution in a consuming app.
🤖 Generated with Claude Code