#[non_exhaustive]pub enum FromSqlxError {
NoTransaction {
version: i64,
},
LedgerTable {
table: String,
},
Setting(&'static str),
Checksum {
version: i64,
},
}Expand description
Why an sqlx Migrator cannot be run by Migrates::migrate as it stands.
Each variant is something sqlx would honour and this crate would not: refusing is the point, so
a program never believes it ran sqlx::migrate! and got a different run.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
NoTransaction
The migration asks to run outside a transaction (-- no-transaction, or no_tx on the
Migrator); Migration always runs in one.
LedgerTable
The Migrator keeps its ledger in another table than _sqlx_migrations, so this crate would
read and write a different ledger than the program asked for.
Setting(&'static str)
The Migrator was set to create a schema or to skip locking; this crate always locks and never
creates a schema.
Checksum
A migration’s stored checksum is not the SHA-384 of its text, so a ledger written by this crate would differ from the one sqlx writes for the same migration.
Trait Implementations§
Source§impl Clone for FromSqlxError
impl Clone for FromSqlxError
Source§impl Debug for FromSqlxError
impl Debug for FromSqlxError
Source§impl Display for FromSqlxError
impl Display for FromSqlxError
impl Eq for FromSqlxError
Source§impl Error for FromSqlxError
impl Error for FromSqlxError
1.30.0 · Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
use the Display impl or to_string()
Source§impl PartialEq for FromSqlxError
impl PartialEq for FromSqlxError
impl StructuralPartialEq for FromSqlxError
Auto Trait Implementations§
impl Freeze for FromSqlxError
impl RefUnwindSafe for FromSqlxError
impl Send for FromSqlxError
impl Sync for FromSqlxError
impl Unpin for FromSqlxError
impl UnsafeUnpin for FromSqlxError
impl UnwindSafe for FromSqlxError
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§fn in_current_span(self) -> Instrumented<Self> ⓘ
fn in_current_span(self) -> Instrumented<Self> ⓘ
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> ⓘ
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> ⓘ
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