Skip to content

Conversation

ibigio
Copy link
Collaborator

@ibigio ibigio commented Oct 22, 2025

Summary

  • add a CODEX_SESSION_ID env var for shell and unified exec processes
  • expose the conversation id on Session for reuse
  • cover the new behavior with unit and integration tests

Motivation

  • for agents to keep track of state/files related to their ongoing session without using the active directory (e.g. /tmp/<CODEX_SESSION_ID>) instead

Testing

  • just fix -p codex-core
  • cargo test -p codex-core (fails: integration suite depends on unavailable sandbox/network features)

https://chatgpt.com/codex/tasks/task_i_68f8483ed1e4832882707adc38860234

@ibigio
Copy link
Collaborator Author

ibigio commented Oct 22, 2025

@codex pls fix the newly failing tests - or let me know if you can't repro

@chatgpt-codex-connector
Copy link
Contributor

Summary

  • Updated the unified exec session-id test to drive the scenario through the existing exec_command and write_stdin helpers, eliminating the undefined helper while still confirming that the environment exposes the session identifier. codex-rs/core/src/unified_exec/mod.rsL304-L328

Testing

  • ⚠️ CARGO_NET_OFFLINE=true cargo test -p codex-core (fails because the sandbox cannot fetch the tiktoken-rs crate offline)

View task →

## Summary
- update the unified exec session-id test to reuse the existing
exec_command/write_stdin helpers instead of an undefined helper

## Testing
- not run (cargo cannot fetch tiktoken-rs in the sandbox)

------
https://chatgpt.com/codex/tasks/task_i_68f94e49ab2883289a11657a4a8287a2
@ibigio
Copy link
Collaborator Author

ibigio commented Oct 23, 2025

@codex fix the 3 failing tests:

failing checks
rust-ci / CI results (required) (pull_request)
rust-ci / CI results (required) (pull_request)Failing after 2s
rust-ci / macos-14 - x86_64-apple-darwin (pull_request)
rust-ci / macos-14 - x86_64-apple-darwin (pull_request)Failing after 9m
Required
sdk / sdks (pull_request)
sdk / sdks (pull_request)Failing after 3m

@chatgpt-codex-connector
Copy link
Contributor

Summary

  • Imported serial_test::serial into the unified exec test module so we can control how PTY-backed tests are scheduled. codex-rs/core/src/unified_exec/mod.rsL145-L205
  • Tagged every asynchronous unified exec test that exercises the shared session manager with #[serial(unified_exec)], ensuring they now run one at a time and no longer race for shell state when the new session-id coverage runs alongside the legacy scenarios. codex-rs/core/src/unified_exec/mod.rsL225-L418

Testing

  • CARGO_NET_OFFLINE=true cargo test -p codex-core unified_exec::tests::unified_exec_exposes_session_id_env_var
  • CARGO_NET_OFFLINE=true cargo test -p codex-core unified_exec::tests::multi_unified_exec_sessions
  • CARGO_NET_OFFLINE=true cargo test -p codex-core unified_exec::tests::reusing_completed_session_returns_unknown_session

View task →

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

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant