From 792de8e49fa8a3c04bfb747adadf71572d753055 Mon Sep 17 00:00:00 2001 From: Owen Jacobson Date: Fri, 18 Jul 2025 01:12:36 -0400 Subject: Remove `pilcrow::cli::Error` from the lib crate's public interface. This might be the pettiest rude change I've ever made to a Rust program. If I saw this - or did this - in code _intend_ to be used as a library, I'd be appalled. --- src/db/mod.rs | 8 -------- 1 file changed, 8 deletions(-) (limited to 'src/db') diff --git a/src/db/mod.rs b/src/db/mod.rs index 632cd9c..99b8986 100644 --- a/src/db/mod.rs +++ b/src/db/mod.rs @@ -102,16 +102,12 @@ async fn migration_replaced( Ok(()) } -/// Errors occurring during database setup. #[derive(Debug, thiserror::Error)] pub enum Error { - /// Failure due to a database error. See [`sqlx::Error`]. #[error(transparent)] Database(#[from] sqlx::Error), - /// Failure because an existing database backup already exists. #[error("backup from a previous failed migration already exists: {0}")] BackupExists(String), - /// Failure due to a database backup error. See [`backup::Error`]. #[error(transparent)] Backup(#[from] backup::Error), #[error("migration failed: {1}\nrestoring backup failed: {0}")] @@ -120,12 +116,8 @@ pub enum Error { "migration failed: {1}\nrestoring from backup succeeded, but deleting backup failed: {0}" )] Drop(sqlx::Error, sqlx::migrate::MigrateError), - /// Failure due to a database migration error. See - /// [`sqlx::migrate::MigrateError`]. #[error(transparent)] Migration(#[from] sqlx::migrate::MigrateError), - /// Failure because the database contains a migration from an unsupported - /// schema version. #[error("database contains rejected migration {0}:{1}, move it aside")] Rejected(String, String), } -- cgit v1.2.3