pub struct CommitLogSession { /* private fields */ }Expand description
Session tracker for commit generation logging.
Manages a unique run directory for a commit generation session, ensuring log files are organized and don’t overwrite each other.
Implementations§
Source§impl CommitLogSession
impl CommitLogSession
Sourcepub fn new(base_log_dir: &str) -> Result<Self>
pub fn new(base_log_dir: &str) -> Result<Self>
Create a new logging session.
Creates a unique run directory under the base log path.
§Arguments
base_log_dir- Base directory for commit logs (e.g.,.agent/logs/commit_generation)
Sourcepub const fn next_attempt_number(&mut self) -> usize
pub const fn next_attempt_number(&mut self) -> usize
Get the next attempt number and increment the counter.
Sourcepub fn new_attempt(&mut self, agent: &str, strategy: &str) -> CommitAttemptLog
pub fn new_attempt(&mut self, agent: &str, strategy: &str) -> CommitAttemptLog
Create a new attempt log for this session.
§Arguments
agent- The agent being usedstrategy- The retry strategy being used
Trait Implementations§
Auto Trait Implementations§
impl Freeze for CommitLogSession
impl RefUnwindSafe for CommitLogSession
impl Send for CommitLogSession
impl Sync for CommitLogSession
impl Unpin for CommitLogSession
impl UnwindSafe for CommitLogSession
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more