We're running Playwright E2E tests inside Dagger containers in CI. We need to pass git/CI metadata (commit SHA, branch ref, author name, commit message) into the container for test reporting (Currents.dev integration).
The problem: All function parameters contribute to Dagger's cache key. These values change on every commit, so passing them as regular string params invalidates the entire E2E test cache — tests re-run from scratch even when no test code changed.
Our current workaround: We use Secret type with a static ?cacheKey= identifier:
--commit-sha=env://CURRENTS_COMMIT_SHA?cacheKey=currents-commit-sha --commit-info-author=env://COMMIT_INFO_AUTHOR?cacheKey=commit-info-author --github-ref=env://CURRENTS_GITHUB_REF?cacheKey=currents-github-ref
This keeps the cache key stable — great. But Dagger now treats these as secrets and sanitizes their values across all downstream logs. If the commit author is "John", every occurrence of "John" in the entire CI output gets replaced with ***. Short values like PR numbers or single digits are especially bad — they get redacted everywhere, making logs unreadable.
These values are not sensitive — they're public git metadata. We just need them excluded from cache key computation.
What we're looking for:
Is there a way to mark a parameter as cache-transparent without using Secret? (e.g., some annotation or decorator we're missing)
Is there a way to disable log sanitization for specific Secret values?
Has anyone solved a similar problem with a different pattern?
We looked through the source (dagql/call/id.go) and it seems like isSensitive controls both cache exclusion and log scrubbing with no way to separate them. Would a feature like @argument({ cacheTransparent: true }) be something that's been discussed or planned?
Running Dagger v0.19.3, TypeScript SDK.