Skip to content

trunk-merge/pr-108243/138f8145-1c3c-41cc-8ce2-e89119d6fecf - #108411

Closed
trunk-io[bot] wants to merge 88 commits into
masterfrom
trunk-merge/pr-108243/138f8145-1c3c-41cc-8ce2-e89119d6fecf
Closed

trunk-io[bot] wants to merge 88 commits into
masterfrom
trunk-merge/pr-108243/138f8145-1c3c-41cc-8ce2-e89119d6fecf

Conversation

@trunk-io

@trunk-io trunk-io Bot commented Sep 29, 2026

Copy link
Copy Markdown
Trunk Merge Pull Request Banner

This pull request was created and is being managed by Trunk Merge.

This pull request is based on the master branch at SHA b6aa2611afc7b08d8b30b730529dfd1f7cc39fb6.

See more details here.

When CI completes, this pull request will be closed automatically.

Pull Requests Being Tested

This pull request is testing the changes from pull request 108243.

Dependencies

This pull request depends on the changes from pull requests 108356, 108308, 107116, 107914, 107597, 108302, 108008, 107133, 108307, 103775, 108214, and 108372.

lucasheriques and others added 30 commits September 24, 2026 18:40
MCP protocol revisions are date-named identifiers (2025-11-25, 2026-07-28)
plus non-date values like "draft". Type detection inferred DateTime, so
HogQL read them back as midnight timestamps and MCP analytics queries
comparing revisions broke. Special-case the key like utm_* and $feature/*.

Only affects new property definitions; existing ones keep their type.

Tested: cargo test -p property-defs-rs --test types (31 passed, new
parameterized case red before the fix), cargo fmt --check, cargo clippy
-D warnings.
Show table source metadata, sync health, downstream dependencies, and data quality checks in the model detail scene.

Expose stable warehouse table identity through the node API and refresh it when a source table is recreated.

Generated-By: PostHog Desktop
Task-Id: 33438e7c-a314-4def-9226-11e120637404
Cover the synced warehouse and PostHog-managed table states in the full model detail scene.

Generated-By: PostHog Desktop
Task-Id: 33438e7c-a314-4def-9226-11e120637404
Keep the table summary count and the rendered lineage graph consistent in the screenshot states.

Generated-By: PostHog Desktop
Task-Id: 33438e7c-a314-4def-9226-11e120637404
…fails

A grant on a warehouse table alone outranks a denial on its source, so the
optional source and schema reads no longer take the whole summary down with
them.

The node row's timestamps describe the graph row, not the table, so a node with
a table of its own now shows nothing when that table load fails instead of the
node's own dates.

Narrow the summary's table, source and schema props to the fields it reads, so
the tests and stories build complete fixtures instead of casting.

Generated-By: PostHog Desktop
Task-Id: dc26e96b-0644-4b07-830d-8b6db3872be4
Generated-By: PostHog Desktop
Task-Id: dc26e96b-0644-4b07-830d-8b6db3872be4
Generated-By: PostHog Desktop
Task-Id: dc26e96b-0644-4b07-830d-8b6db3872be4
The model table summary stories had no mockDate, so the Synced story rendered
last_synced_at through TZLabel against the real clock. Its snapshot drifted on
its own between two runs a week apart, which would break the visual gate on
master every day once the baseline landed.

The new node detail scene fixtures were dated after that story's mocked clock,
so the card read "in 10 hours" for both the last sync and the update time. Both
now sit a day before it.

Generated-By: PostHog Desktop
Task-Id: dc26e96b-0644-4b07-830d-8b6db3872be4
A HogQL predicate compiles only against the events schema, so the
unsweepable-rows gate refused every immediate event-removal request
with a predicate whose team had matching $feature_flag_called rows in
flag_evaluations. Immediate event removal now leaves that table out,
and its rows age out with the TTL. Deferred event removal still queues
the table's uuids.
…h pass

The schedule update now copies the live Temporal state, so a deploy does not resume a paused sweep.
The sweep logs skipped and started passes, and flushes score events after each team.

Generated-By: PostHog Desktop
Task-Id: 4a8788b7-152c-4fde-a89d-c03cbf015800
Mechanical output of `hogli product:isolate:move workflows`: backend/api/ moves to backend/presentation/views/, the api tests move to backend/tests/api/, and dotted paths are rewritten repo-wide.

The four grandfathered routes -> api import-linter entries are removed. The thick views are recorded as exact-pair ignore_imports entries under a workflows presentation-wave TODO, so backend:contract-check stays off until they are thinned. Adds the root tsconfig.json that strict product lint requires.

Refs #84402

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

Generated-By: PostHog Desktop
Task-Id: 2c495d5e-31cf-40c2-96cc-2d8ab721f180
Adds the boundary other code calls instead of workflows internals:

- facade/contracts.py holds the data types that cross the boundary. The audience filters, workflow references, tier limits and tier decisions move there from services and utils, which now import them.
- facade/api.py gains capability functions that take ids and return contracts: workflow names, active-workflow checks, an activity summary, integration usage, the email sending controls, and SES/Twilio helpers.
- facade/tasks.py, facade/enums.py, facade/team_extension.py and facade/account_audience.py re-export the beat tasks, EmailTrackingConsentMode, the team-extension model and the account-audience hook.
- services/email_sending_controls.py takes the staff suspend, unsuspend and set-tier writes from the Django admin, with the same row locks.

Refs #84402

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

Generated-By: PostHog Desktop
Task-Id: 2c495d5e-31cf-40c2-96cc-2d8ab721f180
Core, signals, warehouse_sources, customer_analytics and ai_observability now call the workflows facade instead of its models, services, utils and providers. The Django admin email controls use the facade write functions. TwilioIntegration calls the facade per request instead of holding a provider. Facade imports in posthog/models/ stay function-local because those modules load during django.setup().

The three workflows management commands in posthog/management/commands/ move into the product with their tests. Command names are unchanged.

posthog/api/search.py and the core test fixtures still import workflows internals; they follow in this PR before workflows joins the tach interfaces.

Refs #84402

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

Generated-By: PostHog Desktop
Task-Id: 2c495d5e-31cf-40c2-96cc-2d8ab721f180
…facade

Core search no longer unions a HogFlow queryset. search_entities merges ranked results from the facade's search_workflows, the same way PostHog AI entity search does. search_workflows gains include_archived, with_access_levels and include_count so /api/search keeps the same results, counts and user_access_level values.

Tests outside the product seed workflow rows through facade/testing.py helpers. Tests of workflows behavior (batch jobs, SES verification, admin registration) move into the product. @patch targets in core tests point at facade paths, and facade/tasks.py re-exports refresh_affected_hog_flows for the one core test that patches it.

Refs #84402

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

Generated-By: PostHog Desktop
Task-Id: 2c495d5e-31cf-40c2-96cc-2d8ab721f180
Adds workflows to the shared tach [[interfaces]] regex. hogli lint:tach in backend CI now fails any import from outside the product of anything but backend/facade/, backend/presentation/views/ and backend/routes.py, tests included.

For the edits tach cannot see, products/workflows/AGENTS.md states the boundary for agents working in the product: add a facade function that returns a contract, seed test rows through facade/testing.py, and never widen a tach expose list or add ignore_imports entries. CODEOWNERS adds backend/facade/** so any growth of the public surface needs a workflows review.

Refs #84402

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

Generated-By: PostHog Desktop
Task-Id: 2c495d5e-31cf-40c2-96cc-2d8ab721f180
GitHub's createCommitOnBranch API cannot write a symlink, so the products/workflows/CLAUDE.md symlink that the AGENTS.md check requires cannot land through signed commits. Drop the AGENTS.md pair, and put the rule where a boundary change is made instead: the shared tach [[interfaces]] block now says to add a facade function or a facade/testing.py helper rather than widen the block, and the workflows presentation-wave ignore_imports list says entries are only deleted.

Refs #84402

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

Generated-By: PostHog Desktop
Task-Id: 2c495d5e-31cf-40c2-96cc-2d8ab721f180
…iew imports

facade/enums.py is a contract file, so EmailTrackingConsentMode is now a stdlib StrEnum. EMAIL_TRACKING_CONSENT_MODE_CHOICES carries the labels TextChoices derived before, so the model field and the API schema keep the same choices and no migration changes.

Master added two imports to the moved hog_flow view after the migration was scanned (metrics, workflow_proposal). They join the deferred presentation-wave ignore_imports list with the rest. Two frontend comments point at the view's new path.

Refs #84402

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

Generated-By: PostHog Desktop
Task-Id: 2c495d5e-31cf-40c2-96cc-2d8ab721f180
Gilbert09 and others added 27 commits September 29, 2026 14:44
Generated-By: PostHog Desktop
Task-Id: 76e43e2d-0844-449d-9b12-7ef7006bbc5e
Mark chained Freshchat resources as non-resumable so full-refresh retries reset their destination, and declare the resume state dataclass immutable for the repository's Semgrep convention.
…g/fixsignals-bound-inbox-ranking-sweep-460c61

# Conflicts:
#	products/signals/backend/ranking/sweep.py
#	products/signals/backend/test/test_ranking_sweep.py
@trunk-io trunk-io Bot closed this Sep 29, 2026
@trunk-io
trunk-io Bot deleted the trunk-merge/pr-108243/138f8145-1c3c-41cc-8ce2-e89119d6fecf branch September 29, 2026 14:45
@trunk-io

trunk-io Bot commented Sep 29, 2026 •

Copy link
Copy Markdown
Author

Static Badge   Static Badge   Static Badge

View Full Report ↗︎ ⋅ Docs

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.

10 participants