Repository navigation
ci: upload test results to a Trunk test collection - #1202
Open
EliSchleifer wants to merge 3 commits into
Open
EliSchleifer wants to merge 3 commits into
EliSchleifer wants to merge 3 commits into
Conversation
trunk-analytics-cli 1.x only uploads to a test collection and requires --test-collection-id, so the upload step fails after the tests finish and marks every test job red. Move to trunk-io/analytics-uploader v3, which takes the collection ID and a v2 API key instead of an organization token. The ID comes from the TRUNK_TEST_COLLECTION_ID repository variable and the key from the TRUNK_UPLOAD_API_KEY secret. The upload step is skipped while either is unset. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01GdsoH3X377cYtfd7BXCc7m
|
❌ This pull request was removed from the merge queue because it failed tests. PR #1205 was used for testing. See more details here.
After your PR is submitted to the merge queue, this comment will be automatically updated with its status. If the PR fails, failure details will also be posted here |
The collection id is not a secret, so carry it in the repository rather than in a repo variable someone has to create before the uploads work. Each test action now defaults test-collection-id to L6rxKpAC, and the 13 call sites that passed vars.TRUNK_TEST_COLLECTION_ID are gone; a caller that wants a different collection, or none, still passes the input. TRUNK_UPLOAD_API_KEY is still a secret and still has to be set. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01GdsoH3X377cYtfd7BXCc7m
Member
Author
|
This PR was dropped from the merge queue, but none of the failures come from it — this is a CI-config change and every failing suite also fails on ubuntu-latest — Fixes for four of them are on
Two are not fixed:
Generated by Claude Code |
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.
Problem
Every test job in CI ends red even when all tests pass.
trunk-analytics-cli1.x uploads only to a test collection, so the "Upload prod results" step fails with:Change
trunk-io/analytics-uploaderfrom v2.1.1 to v3.0.0 (pinned by SHA) in thelinter_tests,tool_testsandaction_testsactions.test-collection-idinput to those actions and pass it to the uploader. Uploads still go to prod, orgtrunk.vars.TRUNK_TEST_COLLECTION_IDas the collection ID.secrets.TRUNK_UPLOAD_API_KEYinstead ofsecrets.TRUNK_ORG_PROD_TOKEN. Uploader v3 refuses organization tokens and needs a v2 API key (trunk_v2_...) with the "Upload test results" permission.Required before uploads resume
Neither of these exists yet as far as I can tell (this session cannot read repository variables or secrets):
TRUNK_TEST_COLLECTION_ID: the 8-character ID from app.trunk.io → Flaky Tests → Collections.TRUNK_UPLOAD_API_KEY: a v2 API key from Settings → Developer → API Keys.Until both are set, CI runs the tests and skips the upload.
TRUNK_ORG_PROD_TOKENis no longer referenced and can be removed afterwards.Testing
git ls-remote.Generated by Claude Code