repo
stringlengths
6
65
file_url
stringlengths
81
311
file_path
stringlengths
6
227
content
stringlengths
0
32.8k
language
stringclasses
1 value
license
stringclasses
7 values
commit_sha
stringlengths
40
40
retrieved_at
stringdate
2026-01-04 15:31:58
2026-01-04 20:25:31
truncated
bool
2 classes
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/src/rollout/tests.rs
codex-rs/core/src/rollout/tests.rs
#![allow(clippy::unwrap_used, clippy::expect_used)] use std::fs::File; use std::fs::{self}; use std::io::Write; use std::path::Path; use tempfile::TempDir; use time::OffsetDateTime; use time::PrimitiveDateTime; use time::format_description::FormatItem; use time::macros::format_description; use uuid::Uuid; use crate:...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
false
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/src/rollout/list.rs
codex-rs/core/src/rollout/list.rs
use std::cmp::Reverse; use std::io::{self}; use std::num::NonZero; use std::path::Path; use std::path::PathBuf; use std::sync::Arc; use std::sync::atomic::AtomicBool; use time::OffsetDateTime; use time::PrimitiveDateTime; use time::format_description::FormatItem; use time::format_description::well_known::Rfc3339; use ...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
false
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/src/rollout/policy.rs
codex-rs/core/src/rollout/policy.rs
use crate::protocol::EventMsg; use crate::protocol::RolloutItem; use codex_protocol::models::ResponseItem; /// Whether a rollout `item` should be persisted in rollout files. #[inline] pub(crate) fn is_persisted_response_item(item: &RolloutItem) -> bool { match item { RolloutItem::ResponseItem(item) => shou...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
false
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/src/rollout/error.rs
codex-rs/core/src/rollout/error.rs
use std::io::ErrorKind; use std::path::Path; use crate::error::CodexErr; use crate::rollout::SESSIONS_SUBDIR; pub(crate) fn map_session_init_error(err: &anyhow::Error, codex_home: &Path) -> CodexErr { if let Some(mapped) = err .chain() .filter_map(|cause| cause.downcast_ref::<std::io::Error>()) ...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
false
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/src/rollout/recorder.rs
codex-rs/core/src/rollout/recorder.rs
//! Persist Codex session rollouts (.jsonl) so sessions can be replayed or inspected later. use std::fs::File; use std::fs::{self}; use std::io::Error as IoError; use std::path::Path; use std::path::PathBuf; use codex_protocol::ConversationId; use serde_json::Value; use time::OffsetDateTime; use time::format_descript...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
false
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/src/rollout/mod.rs
codex-rs/core/src/rollout/mod.rs
//! Rollout module: persistence and discovery of session rollout files. use codex_protocol::protocol::SessionSource; pub const SESSIONS_SUBDIR: &str = "sessions"; pub const ARCHIVED_SESSIONS_SUBDIR: &str = "archived_sessions"; pub const INTERACTIVE_SESSION_SOURCES: &[SessionSource] = &[SessionSource::Cli, Session...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
false
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/src/features/legacy.rs
codex-rs/core/src/features/legacy.rs
use super::Feature; use super::Features; use tracing::info; #[derive(Clone, Copy)] struct Alias { legacy_key: &'static str, feature: Feature, } const ALIASES: &[Alias] = &[ Alias { legacy_key: "enable_experimental_windows_sandbox", feature: Feature::WindowsSandbox, }, Alias { ...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
false
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/src/unified_exec/errors.rs
codex-rs/core/src/unified_exec/errors.rs
use crate::exec::ExecToolCallOutput; use thiserror::Error; #[derive(Debug, Error)] pub(crate) enum UnifiedExecError { #[error("Failed to create unified exec session: {message}")] CreateSession { message: String }, // Called "session" in the model's training. #[error("Unknown session id {process_id}")] ...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
false
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/src/unified_exec/session_manager.rs
codex-rs/core/src/unified_exec/session_manager.rs
use rand::Rng; use std::cmp::Reverse; use std::collections::HashMap; use std::collections::HashSet; use std::path::PathBuf; use std::sync::Arc; use tokio::sync::Notify; use tokio::sync::mpsc; use tokio::time::Duration; use tokio::time::Instant; use tokio_util::sync::CancellationToken; use crate::bash::extract_bash_com...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
false
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/src/unified_exec/session.rs
codex-rs/core/src/unified_exec/session.rs
#![allow(clippy::module_inception)] use std::collections::VecDeque; use std::sync::Arc; use tokio::sync::Mutex; use tokio::sync::Notify; use tokio::sync::mpsc; use tokio::sync::oneshot::error::TryRecvError; use tokio::task::JoinHandle; use tokio::time::Duration; use tokio_util::sync::CancellationToken; use crate::exe...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
false
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/src/unified_exec/mod.rs
codex-rs/core/src/unified_exec/mod.rs
//! Unified Exec: interactive PTY execution orchestrated with approvals + sandboxing. //! //! Responsibilities //! - Manages interactive PTY sessions (create, reuse, buffer output with caps). //! - Uses the shared ToolOrchestrator to handle approval, sandbox selection, and //! retry semantics in a single, descriptive...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
false
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/src/unified_exec/async_watcher.rs
codex-rs/core/src/unified_exec/async_watcher.rs
use std::path::PathBuf; use std::pin::Pin; use std::sync::Arc; use tokio::sync::Mutex; use tokio::time::Duration; use tokio::time::Instant; use tokio::time::Sleep; use crate::codex::Session; use crate::codex::TurnContext; use crate::exec::ExecToolCallOutput; use crate::exec::MAX_EXEC_OUTPUT_DELTAS_PER_CALL; use crate...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
false
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/src/config/service.rs
codex-rs/core/src/config/service.rs
use super::CONFIG_TOML_FILE; use super::ConfigToml; use crate::config::edit::ConfigEdit; use crate::config::edit::ConfigEditsBuilder; use crate::config_loader::ConfigLayerEntry; use crate::config_loader::ConfigLayerStack; use crate::config_loader::LoaderOverrides; use crate::config_loader::load_config_layers_state; use...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
true
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/src/config/types.rs
codex-rs/core/src/config/types.rs
//! Types used to define the fields of [`crate::config::Config`]. // Note this file should generally be restricted to simple struct/enum // definitions that do not contain business logic. use codex_utils_absolute_path::AbsolutePathBuf; use std::collections::BTreeMap; use std::collections::HashMap; use std::path::Path...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
true
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/src/config/mod.rs
codex-rs/core/src/config/mod.rs
use crate::auth::AuthCredentialsStoreMode; use crate::config::types::DEFAULT_OTEL_ENVIRONMENT; use crate::config::types::History; use crate::config::types::McpServerConfig; use crate::config::types::Notice; use crate::config::types::Notifications; use crate::config::types::OtelConfig; use crate::config::types::OtelConf...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
true
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/src/config/edit.rs
codex-rs/core/src/config/edit.rs
use crate::config::CONFIG_TOML_FILE; use crate::config::types::McpServerConfig; use crate::config::types::Notice; use anyhow::Context; use codex_protocol::config_types::TrustLevel; use codex_protocol::openai_models::ReasoningEffort; use std::collections::BTreeMap; use std::path::Path; use std::path::PathBuf; use tempfi...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
true
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/src/config/constraint.rs
codex-rs/core/src/config/constraint.rs
use std::fmt; use std::sync::Arc; use thiserror::Error; #[derive(Debug, Error, PartialEq, Eq)] pub enum ConstraintError { #[error("value `{candidate}` is not in the allowed set {allowed}")] InvalidValue { candidate: String, allowed: String }, #[error("field `{field_name}` cannot be empty")] EmptyFiel...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
false
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/src/config/profile.rs
codex-rs/core/src/config/profile.rs
use codex_utils_absolute_path::AbsolutePathBuf; use serde::Deserialize; use serde::Serialize; use crate::protocol::AskForApproval; use codex_protocol::config_types::ReasoningSummary; use codex_protocol::config_types::SandboxMode; use codex_protocol::config_types::Verbosity; use codex_protocol::openai_models::Reasoning...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
false
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/src/config_loader/merge.rs
codex-rs/core/src/config_loader/merge.rs
use toml::Value as TomlValue; /// Merge config `overlay` into `base`, giving `overlay` precedence. pub fn merge_toml_values(base: &mut TomlValue, overlay: &TomlValue) { if let TomlValue::Table(overlay_table) = overlay && let TomlValue::Table(base_table) = base { for (key, value) in overlay_tabl...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
false
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/src/config_loader/tests.rs
codex-rs/core/src/config_loader/tests.rs
use super::LoaderOverrides; use super::load_config_layers_state; use crate::config::CONFIG_TOML_FILE; use crate::config::ConfigBuilder; use crate::config::ConfigOverrides; use crate::config_loader::ConfigLayerEntry; use crate::config_loader::ConfigRequirements; use crate::config_loader::config_requirements::ConfigRequi...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
false
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/src/config_loader/macos.rs
codex-rs/core/src/config_loader/macos.rs
use base64::Engine; use base64::prelude::BASE64_STANDARD; use core_foundation::base::TCFType; use core_foundation::string::CFString; use core_foundation::string::CFStringRef; use std::ffi::c_void; use std::io; use tokio::task; use toml::Value as TomlValue; const MANAGED_PREFERENCES_APPLICATION_ID: &str = "com.openai.c...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
false
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/src/config_loader/fingerprint.rs
codex-rs/core/src/config_loader/fingerprint.rs
use codex_app_server_protocol::ConfigLayerMetadata; use serde_json::Value as JsonValue; use sha2::Digest; use sha2::Sha256; use std::collections::HashMap; use toml::Value as TomlValue; pub(super) fn record_origins( value: &TomlValue, meta: &ConfigLayerMetadata, path: &mut Vec<String>, origins: &mut Has...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
false
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/src/config_loader/layer_io.rs
codex-rs/core/src/config_loader/layer_io.rs
use super::LoaderOverrides; #[cfg(target_os = "macos")] use super::macos::load_managed_admin_config_layer; use codex_utils_absolute_path::AbsolutePathBuf; use std::io; use std::path::Path; use std::path::PathBuf; use tokio::fs; use toml::Value as TomlValue; #[cfg(unix)] const CODEX_MANAGED_CONFIG_SYSTEM_PATH: &str = "...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
false
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/src/config_loader/state.rs
codex-rs/core/src/config_loader/state.rs
use crate::config_loader::ConfigRequirements; use super::fingerprint::record_origins; use super::fingerprint::version_for_toml; use super::merge::merge_toml_values; use codex_app_server_protocol::ConfigLayer; use codex_app_server_protocol::ConfigLayerMetadata; use codex_app_server_protocol::ConfigLayerSource; use code...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
false
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/src/config_loader/overrides.rs
codex-rs/core/src/config_loader/overrides.rs
use toml::Value as TomlValue; pub(super) fn default_empty_table() -> TomlValue { TomlValue::Table(Default::default()) } pub(super) fn build_cli_overrides_layer(cli_overrides: &[(String, TomlValue)]) -> TomlValue { let mut root = default_empty_table(); for (path, value) in cli_overrides { apply_tom...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
false
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/src/config_loader/config_requirements.rs
codex-rs/core/src/config_loader/config_requirements.rs
use codex_protocol::config_types::SandboxMode; use codex_protocol::protocol::AskForApproval; use codex_protocol::protocol::SandboxPolicy; use serde::Deserialize; use crate::config::Constrained; use crate::config::ConstraintError; /// Normalized version of [`ConfigRequirementsToml`] after deserialization and /// norma...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
false
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/src/config_loader/mod.rs
codex-rs/core/src/config_loader/mod.rs
mod config_requirements; mod fingerprint; mod layer_io; #[cfg(target_os = "macos")] mod macos; mod merge; mod overrides; mod state; #[cfg(test)] mod tests; use crate::config::CONFIG_TOML_FILE; use crate::config::ConfigToml; use crate::config_loader::config_requirements::ConfigRequirementsToml; use crate::config_loade...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
false
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/src/mcp/auth.rs
codex-rs/core/src/mcp/auth.rs
use std::collections::HashMap; use anyhow::Result; use codex_protocol::protocol::McpAuthStatus; use codex_rmcp_client::OAuthCredentialsStoreMode; use codex_rmcp_client::determine_streamable_http_auth_status; use futures::future::join_all; use tracing::warn; use crate::config::types::McpServerConfig; use crate::config...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
false
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/src/mcp/mod.rs
codex-rs/core/src/mcp/mod.rs
pub mod auth; use std::collections::HashMap; use std::env; use std::path::PathBuf; use async_channel::unbounded; use codex_protocol::protocol::McpListToolsResponseEvent; use codex_protocol::protocol::SandboxPolicy; use mcp_types::Tool as McpTool; use tokio_util::sync::CancellationToken; use crate::config::Config; use...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
false
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/tests/all.rs
codex-rs/core/tests/all.rs
// Single integration test binary that aggregates all test modules. // The submodules live in `tests/all/`. mod suite;
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
false
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/tests/chat_completions_sse.rs
codex-rs/core/tests/chat_completions_sse.rs
use assert_matches::assert_matches; use codex_core::AuthManager; use std::sync::Arc; use tracing_test::traced_test; use codex_core::CodexAuth; use codex_core::ContentItem; use codex_core::ModelClient; use codex_core::ModelProviderInfo; use codex_core::Prompt; use codex_core::ResponseEvent; use codex_core::ResponseItem...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
false
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/tests/responses_headers.rs
codex-rs/core/tests/responses_headers.rs
use std::sync::Arc; use codex_app_server_protocol::AuthMode; use codex_core::AuthManager; use codex_core::CodexAuth; use codex_core::ContentItem; use codex_core::ModelClient; use codex_core::ModelProviderInfo; use codex_core::Prompt; use codex_core::ResponseEvent; use codex_core::ResponseItem; use codex_core::WireApi;...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
false
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/tests/chat_completions_payload.rs
codex-rs/core/tests/chat_completions_payload.rs
#![allow(clippy::expect_used)] use std::sync::Arc; use codex_app_server_protocol::AuthMode; use codex_core::ContentItem; use codex_core::LocalShellAction; use codex_core::LocalShellExecAction; use codex_core::LocalShellStatus; use codex_core::ModelClient; use codex_core::ModelProviderInfo; use codex_core::Prompt; use...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
false
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/tests/suite/quota_exceeded.rs
codex-rs/core/tests/suite/quota_exceeded.rs
use anyhow::Result; use codex_core::protocol::EventMsg; use codex_core::protocol::Op; use codex_protocol::user_input::UserInput; use core_test_support::responses::ev_response_created; use core_test_support::responses::mount_sse_once; use core_test_support::responses::sse; use core_test_support::responses::start_mock_se...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
false
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/tests/suite/remote_models.rs
codex-rs/core/tests/suite/remote_models.rs
#![cfg(not(target_os = "windows"))] // unified exec is not supported on Windows OS use std::sync::Arc; use anyhow::Result; use codex_core::CodexAuth; use codex_core::CodexConversation; use codex_core::ConversationManager; use codex_core::ModelProviderInfo; use codex_core::built_in_model_providers; use codex_core::conf...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
false
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/tests/suite/codex_delegate.rs
codex-rs/core/tests/suite/codex_delegate.rs
use codex_core::config::Constrained; use codex_core::protocol::AskForApproval; use codex_core::protocol::EventMsg; use codex_core::protocol::Op; use codex_core::protocol::ReviewDecision; use codex_core::protocol::ReviewRequest; use codex_core::protocol::ReviewTarget; use codex_core::protocol::SandboxPolicy; use codex_c...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
false
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/tests/suite/stream_no_completed.rs
codex-rs/core/tests/suite/stream_no_completed.rs
//! Verifies that the agent retries when the SSE stream terminates before //! delivering a `response.completed` event. use codex_core::ModelProviderInfo; use codex_core::WireApi; use codex_core::protocol::EventMsg; use codex_core::protocol::Op; use codex_protocol::user_input::UserInput; use core_test_support::load_sse...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
false
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/tests/suite/truncation.rs
codex-rs/core/tests/suite/truncation.rs
#![cfg(not(target_os = "windows"))] #![allow(clippy::unwrap_used, clippy::expect_used)] use anyhow::Context; use anyhow::Result; use codex_core::config::types::McpServerConfig; use codex_core::config::types::McpServerTransportConfig; use codex_core::protocol::AskForApproval; use codex_core::protocol::EventMsg; use cod...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
false
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/tests/suite/shell_command.rs
codex-rs/core/tests/suite/shell_command.rs
use anyhow::Result; use codex_core::features::Feature; use core_test_support::assert_regex_match; use core_test_support::responses::ev_assistant_message; use core_test_support::responses::ev_completed; use core_test_support::responses::ev_function_call; use core_test_support::responses::ev_response_created; use core_te...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
false
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/tests/suite/models_etag_responses.rs
codex-rs/core/tests/suite/models_etag_responses.rs
#![cfg(not(target_os = "windows"))] use std::sync::Arc; use anyhow::Result; use codex_core::CodexAuth; use codex_core::features::Feature; use codex_core::protocol::AskForApproval; use codex_core::protocol::EventMsg; use codex_core::protocol::Op; use codex_core::protocol::SandboxPolicy; use codex_protocol::config_type...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
false
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/tests/suite/apply_patch_cli.rs
codex-rs/core/tests/suite/apply_patch_cli.rs
#![allow(clippy::expect_used)] use anyhow::Result; use core_test_support::responses::ev_apply_patch_call; use core_test_support::responses::ev_apply_patch_custom_tool_call; use core_test_support::responses::ev_shell_command_call; use core_test_support::test_codex::ApplyPatchModelOutput; use pretty_assertions::assert_e...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
true
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/tests/suite/unified_exec.rs
codex-rs/core/tests/suite/unified_exec.rs
use std::collections::HashMap; use std::ffi::OsStr; use std::fs; use std::sync::OnceLock; use anyhow::Context; use anyhow::Result; use codex_core::features::Feature; use codex_core::protocol::AskForApproval; use codex_core::protocol::EventMsg; use codex_core::protocol::ExecCommandSource; use codex_core::protocol::Op; ...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
true
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/tests/suite/compact_remote.rs
codex-rs/core/tests/suite/compact_remote.rs
#![allow(clippy::expect_used)] use std::fs; use anyhow::Result; use codex_core::CodexAuth; use codex_core::features::Feature; use codex_core::protocol::EventMsg; use codex_core::protocol::Op; use codex_core::protocol::RolloutItem; use codex_core::protocol::RolloutLine; use codex_protocol::models::ContentItem; use cod...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
false
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/tests/suite/tool_parallelism.rs
codex-rs/core/tests/suite/tool_parallelism.rs
#![cfg(not(target_os = "windows"))] #![allow(clippy::unwrap_used)] use std::fs; use std::time::Duration; use std::time::Instant; use codex_core::protocol::AskForApproval; use codex_core::protocol::EventMsg; use codex_core::protocol::Op; use codex_core::protocol::SandboxPolicy; use codex_protocol::config_types::Reason...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
false
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/tests/suite/list_dir.rs
codex-rs/core/tests/suite/list_dir.rs
#![cfg(not(target_os = "windows"))] use core_test_support::responses::mount_function_call_agent_response; use core_test_support::responses::start_mock_server; use core_test_support::skip_if_no_network; use core_test_support::test_codex::test_codex; use pretty_assertions::assert_eq; use serde_json::json; #[tokio::test...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
false
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/tests/suite/items.rs
codex-rs/core/tests/suite/items.rs
#![cfg(not(target_os = "windows"))] use anyhow::Ok; use codex_core::protocol::EventMsg; use codex_core::protocol::ItemCompletedEvent; use codex_core::protocol::ItemStartedEvent; use codex_core::protocol::Op; use codex_protocol::items::TurnItem; use codex_protocol::user_input::UserInput; use core_test_support::response...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
false
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/tests/suite/model_overrides.rs
codex-rs/core/tests/suite/model_overrides.rs
use codex_core::CodexAuth; use codex_core::ConversationManager; use codex_core::protocol::EventMsg; use codex_core::protocol::Op; use codex_protocol::openai_models::ReasoningEffort; use core_test_support::load_default_config_for_test; use core_test_support::wait_for_event; use pretty_assertions::assert_eq; use tempfile...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
false
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/tests/suite/text_encoding_fix.rs
codex-rs/core/tests/suite/text_encoding_fix.rs
//! Integration test for the text encoding fix for issue #6178. //! //! These tests simulate VSCode's shell preview on Windows/WSL where the output //! may be encoded with a legacy code page before it reaches Codex. use codex_core::exec::StreamOutput; use pretty_assertions::assert_eq; #[test] fn test_utf8_shell_outpu...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
false
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/tests/suite/shell_snapshot.rs
codex-rs/core/tests/suite/shell_snapshot.rs
use anyhow::Result; use codex_core::features::Feature; use codex_core::protocol::AskForApproval; use codex_core::protocol::EventMsg; use codex_core::protocol::ExecCommandBeginEvent; use codex_core::protocol::ExecCommandEndEvent; use codex_core::protocol::Op; use codex_core::protocol::SandboxPolicy; use codex_protocol::...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
false
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/tests/suite/compact.rs
codex-rs/core/tests/suite/compact.rs
#![allow(clippy::expect_used)] use codex_core::CodexAuth; use codex_core::ConversationManager; use codex_core::ModelProviderInfo; use codex_core::NewConversation; use codex_core::built_in_model_providers; use codex_core::compact::SUMMARIZATION_PROMPT; use codex_core::compact::SUMMARY_PREFIX; use codex_core::config::Con...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
true
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/tests/suite/exec_policy.rs
codex-rs/core/tests/suite/exec_policy.rs
#![allow(clippy::unwrap_used, clippy::expect_used)] use anyhow::Result; use codex_core::protocol::AskForApproval; use codex_core::protocol::EventMsg; use codex_core::protocol::Op; use codex_core::protocol::SandboxPolicy; use codex_protocol::config_types::ReasoningSummary; use codex_protocol::user_input::UserInput; use...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
false
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/tests/suite/json_result.rs
codex-rs/core/tests/suite/json_result.rs
#![cfg(not(target_os = "windows"))] use codex_core::protocol::AskForApproval; use codex_core::protocol::EventMsg; use codex_core::protocol::Op; use codex_core::protocol::SandboxPolicy; use codex_protocol::config_types::ReasoningSummary; use codex_protocol::user_input::UserInput; use core_test_support::responses; use c...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
false
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/tests/suite/rollout_list_find.rs
codex-rs/core/tests/suite/rollout_list_find.rs
#![allow(clippy::unwrap_used, clippy::expect_used)] use std::io::Write; use std::path::Path; use std::path::PathBuf; use codex_core::find_conversation_path_by_id_str; use tempfile::TempDir; use uuid::Uuid; /// Create sessions/YYYY/MM/DD and write a minimal rollout file containing the /// provided conversation id in t...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
false
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/tests/suite/seatbelt.rs
codex-rs/core/tests/suite/seatbelt.rs
#![cfg(target_os = "macos")] //! Tests for the macOS sandboxing that are specific to Seatbelt. //! Tests that apply to both Mac and Linux sandboxing should go in sandbox.rs. use std::collections::HashMap; use std::path::Path; use std::path::PathBuf; use codex_core::protocol::SandboxPolicy; use codex_core::seatbelt::...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
false
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/tests/suite/user_notification.rs
codex-rs/core/tests/suite/user_notification.rs
#![cfg(not(target_os = "windows"))] use std::os::unix::fs::PermissionsExt; use codex_core::protocol::EventMsg; use codex_core::protocol::Op; use codex_protocol::user_input::UserInput; use core_test_support::fs_wait; use core_test_support::responses; use core_test_support::skip_if_no_network; use core_test_support::te...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
false
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/tests/suite/auth_refresh.rs
codex-rs/core/tests/suite/auth_refresh.rs
use anyhow::Context; use anyhow::Result; use base64::Engine; use chrono::Duration; use chrono::Utc; use codex_core::CodexAuth; use codex_core::auth::AuthCredentialsStoreMode; use codex_core::auth::AuthDotJson; use codex_core::auth::REFRESH_TOKEN_URL_OVERRIDE_ENV_VAR; use codex_core::auth::RefreshTokenError; use codex_c...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
false
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/tests/suite/live_cli.rs
codex-rs/core/tests/suite/live_cli.rs
#![expect(clippy::expect_used)] //! Optional smoke tests that hit the real OpenAI /v1/responses endpoint. They are `#[ignore]` by //! default so CI stays deterministic and free. Developers can run them locally with //! `cargo test --test live_cli -- --ignored` provided they set a valid `OPENAI_API_KEY`. use assert_cm...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
false
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/tests/suite/deprecation_notice.rs
codex-rs/core/tests/suite/deprecation_notice.rs
#![cfg(not(target_os = "windows"))] use anyhow::Ok; use codex_core::features::Feature; use codex_core::protocol::DeprecationNoticeEvent; use codex_core::protocol::EventMsg; use core_test_support::responses::start_mock_server; use core_test_support::skip_if_no_network; use core_test_support::test_codex::TestCodex; use ...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
false
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/tests/suite/client.rs
codex-rs/core/tests/suite/client.rs
use codex_core::AuthManager; use codex_core::CodexAuth; use codex_core::ContentItem; use codex_core::ConversationManager; use codex_core::LocalShellAction; use codex_core::LocalShellExecAction; use codex_core::LocalShellStatus; use codex_core::ModelClient; use codex_core::ModelProviderInfo; use codex_core::NewConversat...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
true
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/tests/suite/grep_files.rs
codex-rs/core/tests/suite/grep_files.rs
#![cfg(not(target_os = "windows"))] use anyhow::Result; use core_test_support::responses::mount_function_call_agent_response; use core_test_support::responses::start_mock_server; use core_test_support::skip_if_no_network; use core_test_support::test_codex::TestCodex; use core_test_support::test_codex::test_codex; use ...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
false
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/tests/suite/approvals.rs
codex-rs/core/tests/suite/approvals.rs
#![allow(clippy::unwrap_used, clippy::expect_used)] use anyhow::Result; use codex_core::config::Constrained; use codex_core::features::Feature; use codex_core::protocol::ApplyPatchApprovalRequestEvent; use codex_core::protocol::AskForApproval; use codex_core::protocol::EventMsg; use codex_core::protocol::ExecApprovalR...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
true
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/tests/suite/view_image.rs
codex-rs/core/tests/suite/view_image.rs
#![cfg(not(target_os = "windows"))] use base64::Engine; use base64::engine::general_purpose::STANDARD as BASE64_STANDARD; use codex_core::protocol::AskForApproval; use codex_core::protocol::EventMsg; use codex_core::protocol::Op; use codex_core::protocol::SandboxPolicy; use codex_protocol::config_types::ReasoningSumma...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
false
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/tests/suite/tool_harness.rs
codex-rs/core/tests/suite/tool_harness.rs
#![cfg(not(target_os = "windows"))] use std::fs; use assert_matches::assert_matches; use codex_core::features::Feature; use codex_core::protocol::AskForApproval; use codex_core::protocol::EventMsg; use codex_core::protocol::Op; use codex_core::protocol::SandboxPolicy; use codex_protocol::config_types::ReasoningSummar...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
false
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/tests/suite/undo.rs
codex-rs/core/tests/suite/undo.rs
#![cfg(not(target_os = "windows"))] use std::fs; use std::path::Path; use std::process::Command; use std::sync::Arc; use anyhow::Context; use anyhow::Result; use anyhow::bail; use codex_core::CodexConversation; use codex_core::features::Feature; use codex_core::protocol::EventMsg; use codex_core::protocol::Op; use co...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
false
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/tests/suite/cli_stream.rs
codex-rs/core/tests/suite/cli_stream.rs
use assert_cmd::Command as AssertCommand; use codex_core::RolloutRecorder; use codex_core::protocol::GitInfo; use core_test_support::fs_wait; use core_test_support::skip_if_no_network; use std::time::Duration; use tempfile::TempDir; use uuid::Uuid; use wiremock::Mock; use wiremock::MockServer; use wiremock::ResponseTem...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
false
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/tests/suite/mod.rs
codex-rs/core/tests/suite/mod.rs
// Aggregates all former standalone integration tests as modules. use codex_arg0::arg0_dispatch; use ctor::ctor; use tempfile::TempDir; // This code runs before any other tests are run. // It allows the test binary to behave like codex and dispatch to apply_patch and codex-linux-sandbox // based on the arg0. // NOTE: ...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
false
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/tests/suite/prompt_caching.rs
codex-rs/core/tests/suite/prompt_caching.rs
#![allow(clippy::unwrap_used)] use codex_core::features::Feature; use codex_core::protocol::AskForApproval; use codex_core::protocol::ENVIRONMENT_CONTEXT_OPEN_TAG; use codex_core::protocol::EventMsg; use codex_core::protocol::Op; use codex_core::protocol::SandboxPolicy; use codex_core::protocol_config_types::Reasoning...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
false
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/tests/suite/rmcp_client.rs
codex-rs/core/tests/suite/rmcp_client.rs
use std::collections::HashMap; use std::ffi::OsStr; use std::ffi::OsString; use std::fs; use std::net::TcpListener; use std::path::Path; use std::time::Duration; use std::time::SystemTime; use std::time::UNIX_EPOCH; use codex_core::config::types::McpServerConfig; use codex_core::config::types::McpServerTransportConfig...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
true
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/tests/suite/resume_warning.rs
codex-rs/core/tests/suite/resume_warning.rs
#![allow(clippy::unwrap_used, clippy::expect_used)] use codex_core::AuthManager; use codex_core::CodexAuth; use codex_core::ConversationManager; use codex_core::NewConversation; use codex_core::protocol::EventMsg; use codex_core::protocol::InitialHistory; use codex_core::protocol::ResumedHistory; use codex_core::proto...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
false
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/tests/suite/compact_resume_fork.rs
codex-rs/core/tests/suite/compact_resume_fork.rs
#![allow(clippy::expect_used)] //! Integration tests that cover compacting, resuming, and forking conversations. //! //! Each test sets up a mocked SSE conversation and drives the conversation through //! a specific sequence of operations. After every operation we capture the //! request payload that Codex would send ...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
false
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/tests/suite/user_shell_cmd.rs
codex-rs/core/tests/suite/user_shell_cmd.rs
use anyhow::Context; use codex_core::ConversationManager; use codex_core::NewConversation; use codex_core::protocol::EventMsg; use codex_core::protocol::ExecCommandEndEvent; use codex_core::protocol::ExecCommandSource; use codex_core::protocol::ExecOutputStream; use codex_core::protocol::Op; use codex_core::protocol::S...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
false
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/tests/suite/model_tools.rs
codex-rs/core/tests/suite/model_tools.rs
#![allow(clippy::unwrap_used)] use core_test_support::load_sse_fixture_with_id; use core_test_support::responses; use core_test_support::responses::start_mock_server; use core_test_support::skip_if_no_network; use core_test_support::test_codex::test_codex; fn sse_completed(id: &str) -> String { load_sse_fixture_w...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
false
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/tests/suite/resume.rs
codex-rs/core/tests/suite/resume.rs
use anyhow::Result; use codex_core::protocol::EventMsg; use codex_core::protocol::Op; use codex_protocol::user_input::UserInput; use core_test_support::responses::ev_assistant_message; use core_test_support::responses::ev_completed; use core_test_support::responses::ev_reasoning_item; use core_test_support::responses::...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
false
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/tests/suite/shell_serialization.rs
codex-rs/core/tests/suite/shell_serialization.rs
#![cfg(not(target_os = "windows"))] #![allow(clippy::expect_used)] use anyhow::Result; use codex_core::protocol::SandboxPolicy; use core_test_support::assert_regex_match; use core_test_support::responses::ev_assistant_message; use core_test_support::responses::ev_completed; use core_test_support::responses::ev_functio...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
false
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/tests/suite/list_models.rs
codex-rs/core/tests/suite/list_models.rs
use anyhow::Result; use codex_core::CodexAuth; use codex_core::ConversationManager; use codex_core::built_in_model_providers; use codex_protocol::openai_models::ModelPreset; use codex_protocol::openai_models::ReasoningEffort; use codex_protocol::openai_models::ReasoningEffortPreset; use core_test_support::load_default_...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
false
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/tests/suite/abort_tasks.rs
codex-rs/core/tests/suite/abort_tasks.rs
use assert_matches::assert_matches; use std::sync::Arc; use std::time::Duration; use codex_core::protocol::EventMsg; use codex_core::protocol::Op; use codex_protocol::user_input::UserInput; use core_test_support::responses::ev_completed; use core_test_support::responses::ev_function_call; use core_test_support::respon...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
false
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/tests/suite/read_file.rs
codex-rs/core/tests/suite/read_file.rs
#![cfg(not(target_os = "windows"))] use core_test_support::responses::mount_function_call_agent_response; use core_test_support::responses::start_mock_server; use core_test_support::skip_if_no_network; use core_test_support::test_codex::test_codex; use pretty_assertions::assert_eq; use serde_json::json; #[tokio::test...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
false
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/tests/suite/tools.rs
codex-rs/core/tests/suite/tools.rs
#![cfg(not(target_os = "windows"))] #![allow(clippy::unwrap_used, clippy::expect_used)] use std::fs; use std::time::Duration; use std::time::Instant; use anyhow::Context; use anyhow::Result; use codex_core::features::Feature; use codex_core::protocol::AskForApproval; use codex_core::protocol::SandboxPolicy; use codex...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
false
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/tests/suite/skills.rs
codex-rs/core/tests/suite/skills.rs
#![cfg(not(target_os = "windows"))] #![allow(clippy::unwrap_used, clippy::expect_used)] use anyhow::Result; use codex_core::features::Feature; use codex_core::protocol::AskForApproval; use codex_core::protocol::Op; use codex_core::protocol::SandboxPolicy; use codex_protocol::user_input::UserInput; use core_test_suppor...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
false
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/tests/suite/exec.rs
codex-rs/core/tests/suite/exec.rs
#![cfg(target_os = "macos")] use std::collections::HashMap; use std::string::ToString; use codex_core::exec::ExecParams; use codex_core::exec::ExecToolCallOutput; use codex_core::exec::SandboxType; use codex_core::exec::process_exec_tool_call; use codex_core::protocol::SandboxPolicy; use codex_core::sandboxing::Sandb...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
false
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/tests/suite/otel.rs
codex-rs/core/tests/suite/otel.rs
use codex_core::config::Constrained; use codex_core::features::Feature; use codex_protocol::protocol::AskForApproval; use codex_protocol::protocol::EventMsg; use codex_protocol::protocol::Op; use codex_protocol::protocol::ReviewDecision; use codex_protocol::protocol::SandboxPolicy; use codex_protocol::user_input::UserI...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
true
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/tests/suite/review.rs
codex-rs/core/tests/suite/review.rs
use codex_core::CodexAuth; use codex_core::CodexConversation; use codex_core::ContentItem; use codex_core::ConversationManager; use codex_core::ModelProviderInfo; use codex_core::REVIEW_PROMPT; use codex_core::ResponseItem; use codex_core::built_in_model_providers; use codex_core::config::Config; use codex_core::protoc...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
false
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/tests/suite/stream_error_allows_next_turn.rs
codex-rs/core/tests/suite/stream_error_allows_next_turn.rs
use codex_core::ModelProviderInfo; use codex_core::WireApi; use codex_core::protocol::EventMsg; use codex_core::protocol::Op; use codex_protocol::user_input::UserInput; use core_test_support::load_sse_fixture_with_id; use core_test_support::skip_if_no_network; use core_test_support::test_codex::TestCodex; use core_test...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
false
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/tests/suite/fork_conversation.rs
codex-rs/core/tests/suite/fork_conversation.rs
use codex_core::CodexAuth; use codex_core::ConversationManager; use codex_core::ModelProviderInfo; use codex_core::NewConversation; use codex_core::built_in_model_providers; use codex_core::parse_turn_item; use codex_core::protocol::EventMsg; use codex_core::protocol::Op; use codex_core::protocol::RolloutItem; use code...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
false
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/tests/common/responses.rs
codex-rs/core/tests/common/responses.rs
use std::sync::Arc; use std::sync::Mutex; use anyhow::Result; use base64::Engine; use codex_protocol::openai_models::ModelsResponse; use serde_json::Value; use wiremock::BodyPrintLimit; use wiremock::Match; use wiremock::Mock; use wiremock::MockBuilder; use wiremock::MockServer; use wiremock::Respond; use wiremock::Re...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
false
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/tests/common/lib.rs
codex-rs/core/tests/common/lib.rs
#![expect(clippy::expect_used)] use tempfile::TempDir; use codex_core::CodexConversation; use codex_core::config::Config; use codex_core::config::ConfigBuilder; use codex_core::config::ConfigOverrides; use codex_utils_absolute_path::AbsolutePathBuf; use regex_lite::Regex; use std::path::PathBuf; pub mod process; pub...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
false
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/tests/common/test_codex_exec.rs
codex-rs/core/tests/common/test_codex_exec.rs
#![allow(clippy::expect_used)] use codex_core::auth::CODEX_API_KEY_ENV_VAR; use std::path::Path; use tempfile::TempDir; use wiremock::MockServer; pub struct TestCodexExecBuilder { home: TempDir, cwd: TempDir, } impl TestCodexExecBuilder { pub fn cmd(&self) -> assert_cmd::Command { let mut cmd = as...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
false
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/tests/common/process.rs
codex-rs/core/tests/common/process.rs
use anyhow::Context; use std::fs; use std::path::Path; use std::time::Duration; pub async fn wait_for_pid_file(path: &Path) -> anyhow::Result<String> { let pid = tokio::time::timeout(Duration::from_secs(2), async { loop { if let Ok(contents) = fs::read_to_string(path) { let trim...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
false
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/tests/common/streaming_sse.rs
codex-rs/core/tests/common/streaming_sse.rs
use std::collections::VecDeque; use std::sync::Arc; use std::time::SystemTime; use std::time::UNIX_EPOCH; use tokio::io::AsyncReadExt; use tokio::io::AsyncWriteExt; use tokio::net::TcpListener; use tokio::sync::Mutex as TokioMutex; use tokio::sync::oneshot; /// Streaming SSE chunk payload gated by a per-chunk signal....
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
false
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/core/tests/common/test_codex.rs
codex-rs/core/tests/common/test_codex.rs
use std::mem::swap; use std::path::Path; use std::path::PathBuf; use std::sync::Arc; use anyhow::Result; use codex_core::CodexAuth; use codex_core::CodexConversation; use codex_core::ConversationManager; use codex_core::ModelProviderInfo; use codex_core::built_in_model_providers; use codex_core::config::Config; use co...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
false
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/keyring-store/src/lib.rs
codex-rs/keyring-store/src/lib.rs
use keyring::Entry; use keyring::Error as KeyringError; use std::error::Error; use std::fmt; use std::fmt::Debug; use tracing::trace; #[derive(Debug)] pub enum CredentialStoreError { Other(KeyringError), } impl CredentialStoreError { pub fn new(error: KeyringError) -> Self { Self::Other(error) } ...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
false
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/cli/src/lib.rs
codex-rs/cli/src/lib.rs
pub mod debug_sandbox; mod exit_status; pub mod login; use clap::Parser; use codex_common::CliConfigOverrides; #[derive(Debug, Parser)] pub struct SeatbeltCommand { /// Convenience alias for low-friction sandboxed automatic execution (network-disabled sandbox that can write to cwd and TMPDIR) #[arg(long = "fu...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
false
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/cli/src/wsl_paths.rs
codex-rs/cli/src/wsl_paths.rs
use std::ffi::OsStr; /// Returns true if the current process is running under WSL. pub use codex_core::env::is_wsl; /// Convert a Windows absolute path (`C:\foo\bar` or `C:/foo/bar`) to a WSL mount path (`/mnt/c/foo/bar`). /// Returns `None` if the input does not look like a Windows drive path. pub fn win_path_to_wsl...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
false
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/cli/src/login.rs
codex-rs/cli/src/login.rs
use codex_app_server_protocol::AuthMode; use codex_common::CliConfigOverrides; use codex_core::CodexAuth; use codex_core::auth::AuthCredentialsStoreMode; use codex_core::auth::CLIENT_ID; use codex_core::auth::login_with_api_key; use codex_core::auth::logout; use codex_core::config::Config; use codex_login::ServerOption...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
false
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/cli/src/debug_sandbox.rs
codex-rs/cli/src/debug_sandbox.rs
#[cfg(target_os = "macos")] mod pid_tracker; #[cfg(target_os = "macos")] mod seatbelt; use std::path::PathBuf; use codex_common::CliConfigOverrides; use codex_core::config::Config; use codex_core::config::ConfigOverrides; use codex_core::exec_env::create_env; use codex_core::landlock::spawn_command_under_linux_sandbo...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
false
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/cli/src/exit_status.rs
codex-rs/cli/src/exit_status.rs
#[cfg(unix)] pub(crate) fn handle_exit_status(status: std::process::ExitStatus) -> ! { use std::os::unix::process::ExitStatusExt; // Use ExitStatus to derive the exit code. if let Some(code) = status.code() { std::process::exit(code); } else if let Some(signal) = status.signal() { std::...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
false
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/cli/src/main.rs
codex-rs/cli/src/main.rs
use clap::Args; use clap::CommandFactory; use clap::Parser; use clap_complete::Shell; use clap_complete::generate; use codex_arg0::arg0_dispatch_or_else; use codex_chatgpt::apply_command::ApplyCommand; use codex_chatgpt::apply_command::run_apply_command; use codex_cli::LandlockCommand; use codex_cli::SeatbeltCommand; u...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
true
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/cli/src/mcp_cmd.rs
codex-rs/cli/src/mcp_cmd.rs
use std::collections::HashMap; use anyhow::Context; use anyhow::Result; use anyhow::anyhow; use anyhow::bail; use clap::ArgGroup; use codex_common::CliConfigOverrides; use codex_common::format_env_display::format_env_display; use codex_core::config::Config; use codex_core::config::edit::ConfigEditsBuilder; use codex_c...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
false
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/cli/src/debug_sandbox/seatbelt.rs
codex-rs/cli/src/debug_sandbox/seatbelt.rs
use std::collections::HashSet; use tokio::io::AsyncBufReadExt; use tokio::process::Child; use tokio::task::JoinHandle; use super::pid_tracker::PidTracker; pub struct SandboxDenial { pub name: String, pub capability: String, } pub struct DenialLogger { log_stream: Child, pid_tracker: Option<PidTracker...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
false
openai/codex
https://github.com/openai/codex/blob/279283fe02bf0ce7f93a160db34dd8cf9c8f42c8/codex-rs/cli/src/debug_sandbox/pid_tracker.rs
codex-rs/cli/src/debug_sandbox/pid_tracker.rs
use std::collections::HashSet; use tokio::task::JoinHandle; use tracing::warn; /// Tracks the (recursive) descendants of a process by using `kqueue` to watch for fork events, and /// `proc_listchildpids` to list the children of a process. pub(crate) struct PidTracker { kq: libc::c_int, handle: JoinHandle<HashS...
rust
Apache-2.0
279283fe02bf0ce7f93a160db34dd8cf9c8f42c8
2026-01-04T15:31:59.292600Z
false