pub enum PoolProfilerError {
AlreadyInitialized {
instrument_id: InstrumentId,
pool_identifier: PoolIdentifier,
},
NotInitialized {
instrument_id: InstrumentId,
pool_identifier: PoolIdentifier,
event_kind: PoolEventKind,
},
InitialTickMismatch {
instrument_id: InstrumentId,
pool_identifier: PoolIdentifier,
initial_tick: i32,
calculated_tick: i32,
},
LiquidityOverflow {
location: PoolEventLocation,
current: u128,
delta: u128,
},
LiquidityUnderflow {
location: PoolEventLocation,
current: u128,
delta: u128,
},
NoEventsProcessed {
instrument_id: InstrumentId,
pool_identifier: PoolIdentifier,
},
}Expand description
Structured errors emitted by the pool profiler during event replay.
Each variant carries enough context to identify the offending pool, event, and the simulated vs. observed values that disagreed, so capture pipelines can choose between hard-halt and skip-and-log on a per-pool basis.
Variants§
AlreadyInitialized
NotInitialized
InitialTickMismatch
LiquidityOverflow
LiquidityUnderflow
NoEventsProcessed
Implementations§
Source§impl PoolProfilerError
impl PoolProfilerError
Sourcepub fn location(&self) -> Option<&PoolEventLocation>
pub fn location(&self) -> Option<&PoolEventLocation>
Returns the event location for variants that carry one.
Trait Implementations§
Source§impl Debug for PoolProfilerError
impl Debug for PoolProfilerError
Source§impl Display for PoolProfilerError
impl Display for PoolProfilerError
Source§impl Error for PoolProfilerError
impl Error for PoolProfilerError
1.30.0 · Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
Returns the lower-level source of this error, if any. Read more
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
👎Deprecated since 1.42.0:
use the Display impl or to_string()
Auto Trait Implementations§
impl Freeze for PoolProfilerError
impl RefUnwindSafe for PoolProfilerError
impl Send for PoolProfilerError
impl Sync for PoolProfilerError
impl Unpin for PoolProfilerError
impl UnsafeUnpin for PoolProfilerError
impl UnwindSafe for PoolProfilerError
Blanket Implementations§
impl<T> Allocation for T
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