Skip to content

feat(repo): --carry-login lets an isolated reach probe use the operator's sign-in and no settings - #1582

Merged
napetrov merged 8 commits into
intel:mainfrom
vchamarthi:carry-login
Dec 6, 2026
Merged

napetrov merged 8 commits into
intel:mainfrom
vchamarthi:carry-login

Conversation

@vchamarthi

@vchamarthi vchamarthi commented Dec 3, 2026 •

Copy link
Copy Markdown
Contributor

Reach probes can now run Codex or Claude Code on your own sign-in, without letting any of your personal settings into the run.

Why

  • repo reach and repo skill-reach give the harness a fresh config dir per run, so your config, skills and memory cannot leak in. A Codex signed in with codex login keeps its credential in that dir (auth.json), so in a probe it has no bearer.
  • Measured with Dokimi on Codex, repo reach <repo> --harness codex --only cwd=. on IntelPython/mkl-service: every scenario failed with 401 Unauthorized: Missing bearer or basic authentication.
  • The only way around it was an API key. There was no supported way to use an existing sign-in that still kept the run isolated.

What changes

  • New opt-in flag --carry-login on repo reach, repo skill-reach and repo run. The default stays fully isolated.
  • Codex: copies only auth.json (from $CODEX_HOME, else ~/.codex) into the run's own CODEX_HOME, readable by the owner only. Config, skills, memory and AGENTS.md stay behind.
  • Claude Code: requires CLAUDE_CODE_OAUTH_TOKEN (from claude setup-token, which the profile forwards) to be set, and records it as the carried login. The config dir is still the run's own.
  • A missing or unreadable login, a harness with no known login, or a set credential that wins over the login is a usage error (exit 2) before any run. A Codex login the run refreshed is written back to the original.
  • harness.isolation in reach.json and skill-discovery.json records login: isolated (the default) or login: carried, with the note "login carried, settings not". Both schemas describe the new field.
  • repo run: the token reaches the agent's container by name only (never by value in the spec). The copied auth.json is removed from the cell's kept config dir once the agent exits, even on a crash. Each cell's meta.json gets the same isolation record, so the batch-ledger golden key list gains isolation.
  • To stay under the file size caps, repo report/repo compare move to commands/repo_run_reports.py and the batch spend reserve/read/write helpers move to repos/batch_spend.py. Behaviour is unchanged and the runner re-exports the names.
  • New module dokimi/repos/login_carry.py. HarnessProfile gains carry_login, which write_config and env honour. Also updated: the CLI snapshot, the flag allowlist row, the contract doc and a changelog fragment.

Evidence

Measured with Dokimi on Codex (codex-cli 0.171.0, gpt-6.2-sol), repo reach <mkl-service> --harness codex --only cwd=.:

Scenario cwd=. Root AGENTS.md harness.isolation
Before (default) error: 401 Missing bearer E (error) login: isolated
After (--carry-login) answered L (loaded) login: carried, files ["auth.json"]

How to test

cd dokimi
python -m pytest -q tests/test_repo_reach_carry_login.py tests/test_repo_run_carry_login.py tests/test_repo_reach.py tests/test_skill_reach.py \
  tests/test_repo_cli_harnesses.py tests/test_cli_flags.py tests/test_import_architecture.py
# 443 passed

make ci-local CI_LOCAL_ARGS='--offline'
# 2 failed, 34326 passed, 33 skipped

One of the 2 failures also fails on unchanged main: test_repo_compare_interval::test_the_row_p_places_zero_where_large_deltas_round_p_at_zero_apart. The other was test_batch_ledger_golden, which pins the meta.json keys. It was updated for the new isolation key, and it now passes (5 passed). schema_compat shows only the two expected warnings for the new harness.isolation property.

Live check, one cheap call (needs a signed-in Codex):

python cli.py repo reach <repo> --harness codex --model <model> --only cwd=. --carry-login

Mutation

The PR's mutation check missed 2 mutants. Both were in the moved repo compare lines (the --arm split and the --metric default). Tests were added for both in tests/test_repo_run_reports.py. The check now reports 27 caught and 0 missed (53 not tried in time).

References

…or's sign-in and no settings

A Codex signed in with codex login keeps its credential in CODEX_HOME/auth.json;
reach and skill-reach give the harness a fresh CODEX_HOME, so every scenario
failed 401 Missing bearer. --carry-login copies only auth.json into the run's
own CODEX_HOME (owner-readable), or forwards CLAUDE_CODE_OAUTH_TOKEN for Claude
Code. Config, skills and memory stay out. A missing login is a usage error, and
harness.isolation records login isolated (default) or carried.

Signed-off-by: vchamarthi <123653452+vchamarthi@users.noreply.github.com>
@vchamarthi
vchamarthi requested a review from a team as a code owner December 3, 2026 10:09
Copilot AI balanced review requested due to automatic review settings December 3, 2026 10:09
@github-actions github-actions Bot added the cli-interface-change Changes dokimi's user-facing CLI surface label Dec 3, 2026
@github-actions

github-actions Bot commented Dec 3, 2026

Copy link
Copy Markdown

CLI interface change detected

This PR changes dokimi's user-facing CLI surface (commands and/or options):

~ `dokimi repo reach` parameters changed:
    + added option `--carry-login`
~ `dokimi repo run` parameters changed:
    + added option `--carry-login`
~ `dokimi repo skill-reach` parameters changed:
    + added option `--carry-login`

Updated on every push; the cli-interface-change label is on while the diff is non-empty.

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

🟡 Changes recommended

Credential copying and cleanup can expose or retain live logins, while execution IDs fail to distinguish login modes, allowing incompatible results to be reused.

5 open issues
What changed in this PR

5 findings. Adds --carry-login so Dokimi’s repository probes and batch runs can use an operator’s Codex or Claude Code sign-in.

Changes:

  • Adds opt-in credential copying or token forwarding and isolation metadata.
  • Updates schemas, documentation, CLI snapshots, and regression tests.
  • Extracts reporting commands and batch-spend helpers into separate modules.
File Description
dokimi/​tests/​test_repo_run_reports.py Tests compare argument forwarding.
dokimi/​tests/​test_repo_run_carry_login.py Tests batch credential handling and metadata.
dokimi/​tests/​test_repo_reach_carry_login.py Tests login copying, forwarding, and refusals.
dokimi/​tests/​test_batch_ledger_golden.py Adds the isolation metadata key.
dokimi/​tests/​data/​cli_flags_allowlist.txt Registers the new flag.
dokimi/​dokimi/​schemas/​skill_discovery.v1.json Describes skill-probe isolation metadata.
dokimi/​dokimi/​schemas/​guidance_reach.v1.json Describes reach-probe isolation metadata.
dokimi/​dokimi/​repos/​skill_reach.py Records login isolation.
dokimi/​dokimi/​repos/​runner.py Forwards credentials, cleans up, and records isolation.
dokimi/​dokimi/​repos/​reach.py Records login isolation.
dokimi/​dokimi/​repos/​login_carry.py Implements credential validation, copying, and cleanup.
dokimi/​dokimi/​repos/​harness_profile.py Integrates login carrying into profiles.
dokimi/​dokimi/​repos/​batch_spend.py Houses extracted spend helpers.
dokimi/​dokimi/​commands/​repo_skill_reach.py Adds skill-reach flag handling.
dokimi/​dokimi/​commands/​repo_run.py Adds batch flag handling and extracts reporting.
dokimi/​dokimi/​commands/​repo_run_reports.py Houses report and compare commands.
dokimi/​dokimi/​commands/​repo_reach.py Adds reach flag handling and replay restrictions.
dokimi/​dokimi/​cli_flags.py Defines shared flag help.
dokimi/​docs/​repo-evaluation-contract.md Documents credential-carrying behavior.
dokimi/​docs/​reference/​cli-interface.json Updates the CLI snapshot.
dokimi/​changelog.d/​20261202_120000_vchamarthi_carry-login.md Announces the feature.

Review effort: Balanced

Comment thread dokimi/dokimi/repos/harness_profile.py Resolved
Comment thread dokimi/dokimi/repos/harness_profile.py Resolved
Comment thread dokimi/dokimi/repos/login_carry.py Resolved
Comment thread dokimi/dokimi/repos/runner.py Resolved
Comment thread dokimi/dokimi/repos/reach.py Resolved
@exai-bot

exai-bot commented Dec 3, 2026 •

Copy link
Copy Markdown

OpenCodeReview: Commit 589a216 was not reviewed. This PR has reached its review limit (6 reviews).

CI at `589a216`: 6 still running, 20 passing, 3 skipped
Check Status
Mutation of changed lines still running
Test Linux Python 3.14 still running
Test Linux Wheels Python 3.14 still running
Tests (py3.14) still running
Windows smoke test (py3.13) still running
self / repo tasks check (fix-degrade-pre) still running

To review this commit: re-request review from exai-bot in the Reviewers list.

Last review (0519e52): 1 medium

Open threads from the bot: 0

Comment thread dokimi/dokimi/commands/repo_reach.py Resolved
Comment thread dokimi/dokimi/repos/harness_profile.py Resolved
Comment thread dokimi/dokimi/repos/login_carry.py Resolved
Comment thread dokimi/dokimi/repos/runner.py Resolved
Comment thread dokimi/dokimi/repos/runner.py Resolved
@github-actions

github-actions Bot commented Dec 3, 2026 •

Copy link
Copy Markdown

Mutation of changed lines

⚠️ Not a clean result: some breaks or tests were left out

At 589a216: 46 caught · 0 missed · 34 not tried in time

This is not a clean result:

  • 34 breaks were not tried before the time budget ran out
  • 232 more breaks of covered changed lines were over the limit and not tried
  • 34 changed lines were not mutated

Warning only: a missed break does not fail the job. Updated on every push; the full report is in the ci run summary.

- execution_id includes a carried login, so a resume in the other mode
  does not reuse its cells; default ids are unchanged
- copy_login creates the file 0600 through a temp file and leaves none
  behind on failure
- repo run drops the login whatever fails after write_config
- repo reach and skill-reach drop the login from a --keep fixture
- a carried reach run gets a fixture HOME
- move the overlay note lines to reach_overlays.py to stay under the cap

Signed-off-by: vchamarthi <123653452+vchamarthi@users.noreply.github.com>
@vchamarthi

Copy link
Copy Markdown
Contributor Author

This is ready for another look: I've pushed 1 commit on carry-login (1e10586..77ca68e).

Changes:

  • A carried login changes the batch execution id.
  • The login file is created 0600 through a temp file.
  • --keep reach and skill-reach fixtures no longer keep auth.json.
  • repo run drops the login when setup fails after the copy.
  • A carried reach run gets a fixture HOME.

Threads:

  • I answered each one in its thread: 10 fixed.

Not caused by this PR:

  • Fails on main too: Tests; runner received a shutdown signal at 99% of the pytest run; no test failed.

What I checked on the new commit: all 2 new tests fail before the fix and pass after it; the full test suite passes with main merged in (35,629 tests), apart from 2 failures main has too.

What each test shows
  • the new hardening tests: fails before, passes after.
  • a failed setup keeps no login in repo run: fails before, passes after.
  • Also changed, outside the PR's files: dokimi/dokimi/repos/batch_ledger.py, dokimi/dokimi/repos/reach_overlays.py.

@codecov-commenter

codecov-commenter commented Dec 4, 2026 •

Copy link
Copy Markdown

⚠️ Please install the 'codecov app svg image' to ensure uploads and comments are reliably processed by Codecov.

Codecov Report

❌ Patch coverage is 95.70957% with 13 lines in your changes missing coverage. Please review.
✅ Project coverage is 96.42%. Comparing base (1bf62d3) to head (589a216).
⚠️ Report is 24 commits behind head on main.

Files with missing lines Patch % Lines
dokimi/dokimi/repos/login_carry.py 89.68% 10 Missing and 3 partials ⚠️
❗ Your organization needs to install the Codecov GitHub app to enable full functionality.
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #1582      +/-   ##
==========================================
- Coverage   96.47%   96.42%   -0.06%     
==========================================
  Files         564      578      +14     
  Lines       74672    75905    +1233     
  Branches    12890    13065     +175     
==========================================
+ Hits        72042    73191    +1149     
- Misses       1610     1658      +48     
- Partials     1020     1056      +36     
Files with missing lines Coverage Δ
dokimi/dokimi/cli_flags.py 100.00% <ø> (ø)
dokimi/dokimi/commands/repo_reach.py 99.54% <100.00%> (+0.03%) ⬆️
dokimi/dokimi/commands/repo_run.py 96.90% <100.00%> (-0.41%) ⬇️
dokimi/dokimi/commands/repo_run_reports.py 100.00% <100.00%> (ø)
dokimi/dokimi/commands/repo_skill_reach.py 98.87% <100.00%> (+0.02%) ⬆️
dokimi/dokimi/repos/agent_env.py 100.00% <100.00%> (ø)
dokimi/dokimi/repos/batch_ledger.py 100.00% <100.00%> (ø)
dokimi/dokimi/repos/batch_spend.py 100.00% <100.00%> (ø)
dokimi/dokimi/repos/harness_profile.py 97.89% <100.00%> (+0.10%) ⬆️
dokimi/dokimi/repos/reach.py 98.27% <100.00%> (-0.05%) ⬇️
... and 5 more

... and 76 files with indirect coverage changes

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@vlad-perevezentsev vlad-perevezentsev 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.

🟡 Changes needed · reviewed 77ca68e

To fix: a Codex token refresh in a carried run is lost and can sign the operator out, and after a rebase on main one new import fails the import test (line comments); the record and refusal gaps there matter less. To answer: how this PR and #1563 share CLAUDE_CODE_OAUTH_TOKEN.

✅ GitHub CI on 77ca68e: 27 jobs pass · ❌ on the merge with current main: 1,645 passed, test_import_architecture.py::test_package_uses_the_new_modules fails · ✅ Windows (Server 2025, Python 3.13): the reach and hardening tests, 17 passed, and the copied auth.json is byte-identical (the repo run ones need Linux, as on main)

The login copy is now private, dropped on every path, and part of the execution id.

Comment thread dokimi/dokimi/repos/login_carry.py Resolved
Comment thread dokimi/dokimi/repos/login_carry.py Resolved
Comment thread dokimi/dokimi/repos/login_carry.py Resolved
Comment thread dokimi/dokimi/repos/login_carry.py Resolved
Comment thread dokimi/dokimi/repos/login_carry.py Resolved
Comment thread dokimi/dokimi/repos/login_carry.py Outdated


def with_login(profile: HarnessProfile, environ: Mapping[str, str] | None = None) -> HarnessProfile:
"""``profile`` set to carry the login; a ProfileError when it has no known login or the login is missing."""

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.

Nit: The docstring says with_login raises a ProfileError, but it raises LoginError, which is not one.

A caller that trusts it and catches ProfileError lets the refusal through as a traceback. Also the comment at cli_flags.py:605 and the cli_flags_allowlist.txt entry name only repo reach/repo skill-reach, while repo run has the flag too.

Suggestion: say LoginError here and add repo run to both.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

This was already fixed in 2ee4163c5: the with_login docstring at dokimi/dokimi/repos/login_carry.py:54 now says it raises LoginError, and the comment at cli_flags.py:638 and the --carry-login entry in cli_flags_allowlist.txt:31 both name repo reach/skill-reach/run.

Signed-off-by: vchamarthi <123653452+vchamarthi@users.noreply.github.com>
- Write a Codex login the harness refreshed back to its source (0600,
  atomic) before dropping the run's copy, so the rotated refresh token
  is not lost.
- Refuse --carry-login when the login file is unreadable, or when a
  credential that wins over it (CODEX_API_KEY, ANTHROPIC_API_KEY, ...)
  is forwarded and set.
- Forward CLAUDE_CODE_OAUTH_TOKEN once now that claude-code's env_allow
  has it.
- Say only what holds in the default isolation note.
- Import InputError from dokimi.files in repo_run_reports.
- Name LoginError in with_login's docstring and add repo run to the
  --carry-login flag comment and allowlist row.

Signed-off-by: vchamarthi <123653452+vchamarthi@users.noreply.github.com>
@vchamarthi

Copy link
Copy Markdown
Contributor Author

@vlad-perevezentsev, this is ready for another look: 2 commits on carry-login (77ca68e..2ee4163) answers 6 of your threads and 2 of your comments.

PR description updated:

  • Claude Code: requires CLAUDE_CODE_OAUTH_TOKEN (from claude setup-token, which the profile forwards) to be set, and records it as the carried login.
  • A missing or unreadable login, a harness with no known login, or a set credential that wins over the login is a usage error (exit 2) before any run. A Codex login the run refreshed is written back to the original.

Your comment:

Threads:

  • I answered each one in its thread: 6 fixed.

What I checked on the new commit: all 6 new tests fail before the fix and pass after it; the full test suite passes with main merged in (36,430 tests), apart from 1 failure main has too.

What each test shows
  • a refreshed login is written back: fails before, passes after.
  • an unchanged copy or moved-on source is not written back: passes.
  • unreadable login refused: fails before, passes after.
  • winning credential refused: fails before, passes after.
  • token forwarded once: fails before, passes after.
  • default note holds: fails before, passes after.
  • import architecture: fails before, passes after.

Comment thread dokimi/dokimi/commands/repo_run.py Resolved
Comment thread dokimi/dokimi/repos/harness_profile.py Resolved
Comment thread dokimi/dokimi/repos/login_carry.py Resolved
Comment thread dokimi/dokimi/repos/login_carry.py Resolved
Comment thread dokimi/dokimi/repos/reach.py Resolved
Comment thread dokimi/dokimi/repos/runner.py Resolved

@napetrov napetrov 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.

Change class: ARCHITECTURAL (head 2ee4163)

  • Contract: changed. errors dokimi/dokimi/commands/repo_run_reports.py:20; errors dokimi/dokimi/commands/repo_run_reports.py:28
  • Responsibility: changed. move cmd_repo_report from dokimi/dokimi/commands/repo_run.py to dokimi/dokimi/commands/repo_run_reports.py; move _print_leaf from dokimi/dokimi/commands/repo_run.py to dokimi/dokimi/commands/repo_run_reports.py
  • Dependency: changed (count signal only, no file:line)
  • Review depth: design read: new dependency/responsibility, ask for rationale
  • Coverage gaps: none

Open issues to resolve on 2ee4163c.

  • The default sign-in preflight still needs credential cleanup in retained directories. Earlier finding
  • Credential refresh should verify the replacement file before updating the operator’s login. Earlier finding

Give sign-in preflight the same credential cleanup as the main run and validate refreshed credential files before updating the operator copy.

Reviewed the diff, edge cases and prior threads. Credential handling was reviewed statically. Live logins and token refresh were outside coverage. The full local suite was outside coverage.

- checked_version and check_container_signed_in drop the copied login
  (and write a refresh back) on every path, including a refused sign-in.
- The write-back refuses a link (lstat first, then O_NOFOLLOW and an
  fstat check, so it also holds where O_NOFOLLOW does not exist) and
  only reads a regular file.
- A refreshed copy that cannot be read raises instead of being dropped.
- A competing credential set in the profile's env_set is refused like one
  forwarded from the shell.
- A failed write-back after the agent ran is noted in trace_errors, so the
  cell is still graded and its charge counted.

Signed-off-by: vchamarthi <123653452+vchamarthi@users.noreply.github.com>
@vchamarthi

Copy link
Copy Markdown
Contributor Author

@napetrov, this is ready for another look: 1 commit on carry-login (2ee4163..4ef0ad7) answers 2 of your comments.

Your comment:

  • Both are fixed in 07b3bb3a4: the preflights drop the login, and the write-back refuses a symlink or a non-regular file.
  • The PR text says the move keeps repo_run.py and the runner under the file size caps, and behaviour is unchanged; tests/test_repo_run_reports.py covers the moved code.

Threads:

  • I answered each one in its thread: 6 fixed.

What I checked on the new commit:

  • 5 of 6 new tests fail before the fix and pass after it; the other passes before the fix too, so it guards the change rather than reproduce a bug.
  • The full test suite passes with main merged in (36,808 tests), apart from 1 failure main has too.
What each test shows
  • preflight copies are dropped and refreshes written back: fails before, passes after.
  • a symlink in the config dir is not followed: fails before, passes after.
  • env_set credential refused: fails before, passes after.
  • failed write-back keeps the cell graded: fails before, passes after.
  • a link is refused without O_NOFOLLOW: fails before, passes after.
  • an unreadable refreshed copy is reported: passes before the fix too.
  • Also changed, outside the PR's files: dokimi/dokimi/repos/sign_in.py.

Comment thread dokimi/dokimi/repos/sign_in.py Resolved
check_container_signed_in let an OSError from drop_login escape before the
call's charge was returned, so repo run lost the spend. The failure is now
reported on stderr and the charge is returned.

Signed-off-by: vchamarthi <123653452+vchamarthi@users.noreply.github.com>
@vchamarthi

Copy link
Copy Markdown
Contributor Author

This is ready for another look: I've pushed 1 commit on carry-login (4ef0ad7..3842942).

Changes:

  • check_container_signed_in reports a failed drop_login on stderr instead of raising, so the charge is returned.

Threads:

  • I answered each one in its thread: 1 fixed.

What I checked on the new commit: the new test fails before the fix and passes after it; the full test suite passes with main merged in (36,829 tests), apart from 1 failure main has too.

What each test shows
  • A failed write-back keeps the preflight charge: fails before, passes after.

@antonwolfy antonwolfy 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.

Review at 3842942. The earlier rounds' fixes hold: the 0600 copy, cleanup in every probe and preflight path, write-back with no link following, and the execution id all behave as described. Two risks are left, both in login_carry.py.

What I ran, on a Linux review host at 3842942:

  • make ci-local: 38 passed, 0 failed, 16 skipped (matrix legs on other Pythons and the merge with current main are not covered). 35,619 tests passed, 28 skipped, total coverage 97%.
  • Reproductions for both findings, with no model or network call.
  • Mutation of the override list (see the inline comment).

Checked, no issues

  • Commits: all five non-merge commits carry Signed-off-by.
  • Schemas and docs: harness.isolation is described in both schemas, the flag is in the CLI snapshot and the allowlist, and the changelog fragment is present.
  • Moved code: repo report/repo compare and the spend helpers are re-exported, and the new tests pass against the moved names.

Comment thread dokimi/dokimi/repos/login_carry.py Resolved
Comment thread dokimi/dokimi/repos/login_carry.py Resolved
copy_login resolves the login source, so a refreshed login is written back
to the real file instead of replacing the link. Tests also cover every
override name that makes --carry-login refuse.

Signed-off-by: vchamarthi <123653452+vchamarthi@users.noreply.github.com>
@vchamarthi

Copy link
Copy Markdown
Contributor Author

@antonwolfy, this is ready for another look: 1 commit on carry-login (3842942..0519e52) answers 2 of your threads and your comment.

Your comment:

  • Both findings were inline threads and are answered there: the symlink write-back and the override-name test.

Threads:

  • I answered each one in its thread: 2 fixed.

What I checked on the new commit: the new test fails before the fix and passes after it; the full test suite passes with main merged in (36,976 tests), apart from 1 failure main has too.

What each test shows
  • a refreshed login lands in the file a symlinked auth.json points at: fails before, passes after.
  • every override name is refused: passes.

@napetrov napetrov 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.

Change class: ARCHITECTURAL (head 0519e52)

  • Contract: changed. errors dokimi/dokimi/commands/repo_run_reports.py:20; errors dokimi/dokimi/commands/repo_run_reports.py:28
  • Responsibility: changed. move cmd_repo_report from dokimi/dokimi/commands/repo_run.py to dokimi/dokimi/commands/repo_run_reports.py; move _print_leaf from dokimi/dokimi/commands/repo_run.py to dokimi/dokimi/commands/repo_run_reports.py
  • Dependency: changed (count signal only, no file:line)
  • Review depth: design read: new dependency/responsibility, ask for rationale
  • Coverage gaps: none

Follow-up question.

--carry-login carries the operator sign-in into a fresh run for Codex and Claude Code. The review focused on identity, credential lifetime, retained outputs, and accounting.

Review with #1559 and #1654. The paired merges conflict in the reach/CLI surfaces and harness profile, respectively.

CI on head 0519e52: 0 failing Actions jobs; merge base 1bf62d3 is behind base tip 5225c2a.

Compared the change and input edges against the merge base and checked existing threads and GitHub Actions. Runtime checks used local fixtures. Live credentials and external path access were outside the review. Focused tests on the head: extra 7 passed in 4.97s.

Comment thread dokimi/dokimi/repos/login_carry.py Resolved
The digest compare and the write-back of a refreshed Codex login were
separate steps under a process-local lock, so two dokimi runs refreshing
the same login could overwrite each other. Hold an exclusive file lock
next to the login file around both.

Signed-off-by: vchamarthi <123653452+vchamarthi@users.noreply.github.com>
@vchamarthi

Copy link
Copy Markdown
Contributor Author

@napetrov, this is ready for another look: 1 commit on carry-login (0519e52..589a216) answers your thread.

Changes:

  • The compare of the source login's digest and the write-back now run under an exclusive file lock shared by all dokimi processes.

Threads:

  • I answered each one in its thread: 1 fixed.

What I checked on the new commit: the new test fails before the fix and passes after it; the full test suite passes with main merged in (37,093 tests), apart from 1 failure main has too.

What each test shows
  • A write-back waits while another holder has the login lock and does not overwrite the login it then finds changed: fails before, passes after.

@napetrov napetrov 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.

Change class: ARCHITECTURAL (head 589a216)

  • Contract: changed. errors dokimi/dokimi/commands/repo_run_reports.py:20; errors dokimi/dokimi/commands/repo_run_reports.py:28
  • Responsibility: changed. move cmd_repo_report from dokimi/dokimi/commands/repo_run.py to dokimi/dokimi/commands/repo_run_reports.py; move _print_leaf from dokimi/dokimi/commands/repo_run.py to dokimi/dokimi/commands/repo_run_reports.py
  • Dependency: changed (count signal only, no file:line)
  • Review depth: design read: new dependency/responsibility, ask for rationale
  • Coverage gaps: none

Ready for approval.

The previous write-back question is addressed for concurrent Dokimi processes. A paired merge with #1654 still needs a manual reconciliation in harness_profile.py.

CI on head 589a216: 0 failing Actions jobs; merge base 1bf62d3 is behind base tip 60948d0.

Checked the source lock, acquisition and cleanup ordering, two focused tests using synthetic login data, required CI, and a merge with current main. Runtime coverage was Linux with fixture credentials.

@napetrov
napetrov merged commit 977b1ff into intel:main Dec 6, 2026
30 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

cli-interface-change Changes dokimi's user-facing CLI surface

Projects

None yet

Development

Successfully merging this pull request may close these issues.

7 participants