Skip to content

feat(launch): read unset profile secrets through secretspec - #84

Open
runewright[bot] wants to merge 2 commits into
mainfrom
change/launch-secret-declaration-lookup
Open

runewright[bot] wants to merge 2 commits into
mainfrom
change/launch-secret-declaration-lookup

Conversation

@runewright

@runewright runewright Bot commented Nov 2, 2026 •

Copy link
Copy Markdown

rune launch and rune run read a profile's from_env key that the shell leaves unset through secretspec, from a manifest the new secrets config key names.

Plan

Change launch-secret-declaration-lookup: proposal, design, one ADDED delta (launch-secret-declaration-lookup), tasks, and adr.md under docs/changes/launch-secret-declaration-lookup/.

Changes

  • Add the secrets config key and the RUNE_SECRETS override (src/ontology.rs). With neither set and no env file named, use ~/.config/rune/secretspec.toml when it exists. An empty value turns the manifest off. rune config set secrets <path> works.
  • Add src/cli/launch/secrets.rs: the SecretSource trait and SecretspecBinary, which runs secretspec get <KEY> --file <manifest> with a reason and --caller rune, and returns stdout byte for byte.
  • Read through the manifest in apply_profile_env when one applies, and never read the env file then. Without a manifest, keep the env file fallback. Read each key once per launch.
  • Stop the launch on a missing manifest, a missing binary, or a failed read, with the key, the manifest path, and a cause from a fixed list. Secretspec's own error text is never repeated, because a dotenv parse error quotes a stored value.
  • Update the launch help text, config.example.yaml, docs/config-reference.json, docs/Manual Testing.md, and CHANGELOG.md.

Testing

  • cargo test --workspace --all-features: every test binary passes. New tests cover the manifest read, the environment winning, one read per key, a failed read, a missing manifest, the argument list, and a fake secretspec binary.
  • cargo clippy --workspace --all-targets --all-features -- -D warnings and cargo fmt --check clean.
  • rune spec validate launch-secret-declaration-lookup passes.
  • One live dry run of sol@claude with no shell variable and no env file: secretspec's audit log shows the Keychain served CLIPROXY_API_KEY with rune's reason and caller.

Release Notes

  • rune launch and rune run read unset from_env keys through secretspec from ~/.config/rune/secretspec.toml, or the manifest that secrets or RUNE_SECRETS names. Without a manifest, the env file works as before.

Note

Read unset profile secrets through secretspec in launch

The PR diff contains only blank-line changes. There are no functional changes to the launch code, despite the stated intent in the title.

Macroscope summarized 6d8abce.

A launch profile's from_env key that the shell leaves unset is read with
secretspec get from a manifest: the new secrets config key, RUNE_SECRETS,
or ~/.config/rune/secretspec.toml when it exists and no env file is
named. An empty secrets value turns the manifest off. With a manifest
the env file is not read, so a stale ~/.env cannot answer for a failed
read. Without one, the env file works as before.

Each read passes a reason and the caller fields, so secretspec's audit
log names the profile and the key. A missing manifest, a missing binary,
or a failed read stops the launch with the key, the manifest, and a
cause from a fixed list. Secretspec's own report is never repeated: a
dotenv parse error quotes the failing line, which can hold a value. The
SecretSource trait leaves room for the SDK.

Change launch-secret-declaration-lookup.

Co-Authored-By: Martin Zeman <N4M3Z@users.noreply.github.com>
@github-actions github-actions Bot added size:large auto: changed-lines bucket area:docs auto: documentation and markdown labels Nov 2, 2026
@github-actions

github-actions Bot commented Nov 2, 2026

Copy link
Copy Markdown

review/correctness stood down on 89a0bf17: free lanes only: deterministic check quality is pending on this head. Apply review:runeseer to force a paid round.

@github-actions

github-actions Bot commented Nov 2, 2026

Copy link
Copy Markdown

review/correctness stood down on 89a0bf17: free lanes only: deterministic check quality is pending on this head. Apply review:runeseer to force a paid round.

Main carries this change already, as be0f4fc, with the follow-ups that
hide values in the dry run, record the proof, and add secrets_profile.
The merge takes the main side of every conflict, so the branch matches
main.

Co-Authored-By: Martin Zeman <N4M3Z@users.noreply.github.com>
@github-actions github-actions Bot added size:small auto: changed-lines bucket and removed size:large auto: changed-lines bucket labels Nov 24, 2026
@runeseer

runeseer Bot commented Nov 24, 2026

Copy link
Copy Markdown
Contributor

review/correctness round 1 started on 6d8abce5 at ledger generation 1.

@runeseer

runeseer Bot commented Nov 24, 2026 •

Copy link
Copy Markdown
Contributor

Claude finished @N4M3Z's task in 1m 19s —— View job


  • Read the ledger and the other lanes' findings for 6d8abce5
  • Review the pull request range
  • Record the verdict

Looks good. The branch head carries the same tree as main, so this pull request changes no files and leaves nothing in scope to review.

  • The secretspec work it describes, including src/cli/launch/secrets.rs, is already present on main; the merge commit left no remaining delta.
  • No other reviewer raised a finding on this head, and no review thread is open.
    · branch change/launch-secret-declaration-lookup

@runeseer

runeseer Bot commented Nov 24, 2026 •

Copy link
Copy Markdown
Contributor

Runeseer review — clean

Looks good. The branch head carries the same tree as main, so this pull request changes no files and leaves nothing in scope to review.

  • git diff cfe90ab1 6d8abce5 is empty: the merge commit left no remaining delta, and the secretspec work it describes is already on main.
  • No reviewer raised a finding on this head, and no review thread is open.

No open findings · Reviewed 6d8abce5 · review run · $0.54 · 0m46s · 18 turns

@runeseer runeseer Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Earned approval: review/correctness returned a clean verdict for 6d8abce at ledger generation 1. Dismissed automatically on any new push or generation.

@N4M3Z
N4M3Z marked this pull request as ready for review November 24, 2026 01:13
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Nov 24, 2026 •

Copy link
Copy Markdown
Codex Review Summary: ✅ Completed

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-11-24T01:14:14.567343Z 6d8abce Draft marked ready
🔒 Security Review ✅ Completed 2026-11-24T01:15:06.872459Z 6d8abce Draft marked ready
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@runeseer

runeseer Bot commented Nov 24, 2026

Copy link
Copy Markdown
Contributor

review/correctness round 2 started on 6d8abce5 at ledger generation 2.

@runeseer

runeseer Bot commented Nov 24, 2026 •

Copy link
Copy Markdown
Contributor

Claude finished @N4M3Z's task in 46s —— View job


Runeseer review

  • Read the ledger and the other lanes' findings for 6d8abce5
  • Review the pull request range
  • Record the verdict

Looks good. The branch head carries the same tree as main, so this pull request changes no files and leaves nothing in scope to review.

  • git diff cfe90ab1 6d8abce5 is empty: the merge commit left no remaining delta, and the secretspec work it describes is already on main.
  • No reviewer raised a finding on this head, and no review thread is open.
    · branch change/launch-secret-declaration-lookup

@macroscopeapp

macroscopeapp Bot commented Nov 24, 2026

Copy link
Copy Markdown

Approvability

Verdict: Approved at 6d8abce

Macroscope's review found this PR approvable — The supplied base-to-head comparison is empty; the feature is already present on main. This PR introduces no additional behavior or risk.

Notes:

  • Macroscope's correctness review did not run, so approvability was decided on eligibility alone.

You can add or adjust custom eligibility rules. Learn more.

@runeseer runeseer Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Earned approval: review/correctness returned a clean verdict for 6d8abce at ledger generation 2. Dismissed automatically on any new push or generation.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area:docs auto: documentation and markdown size:small auto: changed-lines bucket

Projects

None yet

Development

Successfully merging this pull request may close these issues.

0 participants