Compare commits

...

1 Commits

Author SHA1 Message Date
jimmyfraiture
c8d65bbf5e core: scaffold state module with SessionState/ActiveTurn/TurnState and wire into lib 2025-09-24 17:04:38 +01:00
4 changed files with 31 additions and 0 deletions

View File

@@ -75,6 +75,7 @@ pub use rollout::find_conversation_path_by_id_str;
pub use rollout::list::ConversationItem;
pub use rollout::list::ConversationsPage;
pub use rollout::list::Cursor;
mod state;
mod user_notification;
pub mod util;

View File

@@ -0,0 +1,9 @@
//! Session/turn state module scaffolding.
//!
//! This module will encapsulate all mutable state for a Codex session.
//! It starts with lightweight placeholders to enable incremental refactors
//! without changing behaviour.
mod session;
mod turn;

View File

@@ -0,0 +1,12 @@
//! Session-wide mutable state scaffolding.
/// Placeholder for session-persistent state.
#[derive(Debug, Default)]
pub(crate) struct SessionState;
impl SessionState {
/// Create a new, empty session state.
pub(crate) fn new() -> Self {
Self
}
}

View File

@@ -0,0 +1,9 @@
//! Turn-scoped state and active turn metadata scaffolding.
/// Metadata about the currently running turn.
#[derive(Debug, Default)]
pub(crate) struct ActiveTurn;
/// Mutable state for a single turn.
#[derive(Debug, Default)]
pub(crate) struct TurnState;