Repository navigation
feat(data-warehouse): add 1 missing table to the E2B source - #124262
Conversation
Add a template_tags table that reads GET /templates/{templateID}/tags
for each template. Skip /teams, /teams/{teamID}/metrics/max and the
build status endpoint for the reasons in the coverage appendix.
|
😎 Merged successfully - details. |
|
Risk: No findings This PR adds a Sentinel reviewed |
|
/trunk merge |
There was a problem hiding this comment.
Reviewed the PR description, diff, existing discussion, E2B source wiring, shared fan-out behavior, and the added regression test. Checked endpoint response shape and authentication against the E2B OpenAPI spec, composite-key preservation, pagination, full-refresh partitioning, data safety, performance, and scope/overengineering. The change reuses the existing source machinery and stays within scope. Tests, builds, and linters were not run, as requested.
No issues found.
— Robo Bill v2 (gpt-6.1-sol, high reasoning)
There was a problem hiding this comment.
Approved.
The ingestion change has current-head review assurance and an owning-team author. No unresolved substantive concerns or other refusal grounds were found.
- Author wrote 50% of the modified lines and has 25 merged PRs in these paths (familiarity MODERATE).
- PostHog Review (Standard) reviewed the current head: no findings.
- bill-ph reviewed the current head.
Gate mechanics and policy version
| Gate | Result | |
|---|---|---|
| prerequisites | ✓ | all clear |
| deny-list | ✓ | no deny categories matched |
| size | ✓ | 20L, 2F substantive, 46L/5F incl. docs/generated/snapshots — within ceiling |
| tier | ✓ | T1-agent / T1b-small (46L, 5F, single-area, feat) |
| stamphog 2.6.1 | .stamphog/policy.yml @ bf1ed58 · reviewed head bf1ed58 |
|
Hey @Gilbert09! 👋 It looks like your git author email on this PR isn't your
You can fix it for this repo with: git config user.email "you@posthog.com"Or set it globally with |
🤖 CI report
|
Problem
latest) in the warehouse.Changes
template_tagstable lists every tag of every template, with the build that the tag points at.templates, one request per template, liketemplate_builds.templateIDplustag, because the same tag name (for examplelatest) occurs on many templates.createdAtchanges when the tag moves to a new build.COVERAGE_GAPS_APPENDIX.md.template_tagsGET /templates/{templateID}/tagsFull refresh only: the endpoint has no timestamp filter and no pagination.
Skipped endpoints
Each one was checked against the E2B OpenAPI spec. The appendix already records these reasons.
GET /teams: the spec allows onlyAuthProviderBearerAuth, so the team API key of this source cannot call it. The response also contains the team's liveapiKey.GET /teams/{teamID}/metrics/max: each call returns one{timestamp, value}object for one metric. That is one value, not a table, and it is the maximum of the existingteam_metricsseries.GET /templates/{templateID}/builds/{buildID}/status: it needs a second fan-out hop with one request per build. Its only non-log fields already arrive intemplate_builds. The rest is build log lines.How did you test this code?
sources/tests/filtered to E2B. Both pass.mypy products/warehouse_sources products/data_warehouseandruffon the changed files.Test rationale:
test_template_tags_carry_their_template_idcatches tag rows that lose theirtemplateID. Two templates that share the taglatestwould then collide on the composite key. The nearest test,test_fanout_checkpoints_under_its_own_slot_and_resumes_from_it, checks only resume state, not row shape.Release status
Docs update
The source doc at
e2b/e2b.mdnow mentions template tags. The table list renders fromget_schemasand the canonical descriptions.