diff --git a/libs/user-facing-errors/src/query_engine/mod.rs b/libs/user-facing-errors/src/query_engine/mod.rs index 065189ee75d6..cf2893670363 100644 --- a/libs/user-facing-errors/src/query_engine/mod.rs +++ b/libs/user-facing-errors/src/query_engine/mod.rs @@ -22,7 +22,7 @@ impl fmt::Display for DatabaseConstraint { } Self::Index(index) => write!(f, "constraint: `{index}`"), Self::ForeignKey => write!(f, "foreign key"), - Self::CannotParse => write!(f, "(not available)"), + Self::CannotParse => write!(f, "THIS SHOULD BE SOMETHING ELSE (mod.rs, DatabaseConstraint, parsing)"), } } } diff --git a/quaint/src/error.rs b/quaint/src/error.rs index 43e2f88e4b6a..ebee27283922 100644 --- a/quaint/src/error.rs +++ b/quaint/src/error.rs @@ -53,7 +53,7 @@ impl fmt::Display for Name { fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result { match self { Self::Available(name) => name.fmt(f), - Self::Unavailable => write!(f, "(not available)"), + Self::Unavailable => write!(f, "THIS SHOULD BE SOMETHING ELSE (error.rs, Display, Name, Unavailable"), } } } diff --git a/query-engine/connector-test-kit-rs/query-engine-tests/tests/writes/ids/byoid.rs b/query-engine/connector-test-kit-rs/query-engine-tests/tests/writes/ids/byoid.rs index 66ca6defd4e9..4ebb18a5d1e9 100644 --- a/query-engine/connector-test-kit-rs/query-engine-tests/tests/writes/ids/byoid.rs +++ b/query-engine/connector-test-kit-rs/query-engine-tests/tests/writes/ids/byoid.rs @@ -56,7 +56,7 @@ mod byoid { let error_target = match runner.connector_version() { query_engine_tests::ConnectorVersion::MySql(_) => "constraint: `PRIMARY`", - query_engine_tests::ConnectorVersion::Vitess(_) => "(not available)", + query_engine_tests::ConnectorVersion::Vitess(_) => "MISSING", _ => "fields: (`id`)", }; @@ -84,7 +84,7 @@ mod byoid { let error_target = match runner.connector_version() { ConnectorVersion::MySql(_) => "constraint: `PRIMARY`", - ConnectorVersion::Vitess(_) => "(not available)", + ConnectorVersion::Vitess(_) => "MISSING", _ => "fields: (`id`)", }; @@ -142,7 +142,7 @@ mod byoid { let error_target = match runner.connector_version() { ConnectorVersion::MySql(_) => "constraint: `PRIMARY`", - ConnectorVersion::Vitess(_) => "(not available)", + ConnectorVersion::Vitess(_) => "MISSING", _ => "fields: (`id`)", }; @@ -170,7 +170,7 @@ mod byoid { let error_target = match runner.connector_version() { ConnectorVersion::MySql(_) => "constraint: `PRIMARY`", - ConnectorVersion::Vitess(_) => "(not available)", + ConnectorVersion::Vitess(_) => "MISSING", _ => "fields: (`id`)", }; diff --git a/query-engine/connectors/query-connector/src/error.rs b/query-engine/connectors/query-connector/src/error.rs index 903fca348ce1..baccc7910969 100644 --- a/query-engine/connectors/query-connector/src/error.rs +++ b/query-engine/connectors/query-connector/src/error.rs @@ -46,7 +46,7 @@ impl ConnectorError { DatabaseConstraint::Fields(fields) => fields.join(","), DatabaseConstraint::Index(index) => format!("{index} (index)"), DatabaseConstraint::ForeignKey => "foreign key".to_string(), - DatabaseConstraint::CannotParse => "(not available)".to_string(), + DatabaseConstraint::CannotParse => "THIS SHOULD BE SOMETHING ELSE (error.rs, CannotParse)".to_string(), }; Some(KnownError::new(user_facing_errors::query_engine::ForeignKeyViolation { diff --git a/schema-engine/sql-migration-tests/tests/errors/error_tests.rs b/schema-engine/sql-migration-tests/tests/errors/error_tests.rs index 76a18c984fd0..92efc36a03e0 100644 --- a/schema-engine/sql-migration-tests/tests/errors/error_tests.rs +++ b/schema-engine/sql-migration-tests/tests/errors/error_tests.rs @@ -319,7 +319,7 @@ fn unique_constraint_errors_in_migrations_must_return_a_known_error(api: TestApi let json_error = serde_json::to_value(&res).unwrap(); let expected_msg = if api.is_vitess() { - "Unique constraint failed on the (not available)" + "Unique constraint failed on the MISSING" } else if api.is_mysql() || api.is_mssql() { "Unique constraint failed on the constraint: `Fruit_name_key`" } else { diff --git a/schema-engine/sql-migration-tests/tests/migrations/cockroachdb.rs b/schema-engine/sql-migration-tests/tests/migrations/cockroachdb.rs index 70b16900f32f..b8ac5c6a9cc4 100644 --- a/schema-engine/sql-migration-tests/tests/migrations/cockroachdb.rs +++ b/schema-engine/sql-migration-tests/tests/migrations/cockroachdb.rs @@ -883,7 +883,7 @@ fn unique_constraint_errors_in_migrations_must_return_a_known_error(api: TestApi let json_error = serde_json::to_value(&res).unwrap(); let expected_msg = if api.is_vitess() { - "Unique constraint failed on the (not available)" + "Unique constraint failed on the MISSING" } else if api.is_mysql() || api.is_mssql() { "Unique constraint failed on the constraint: `Fruit_name_key`" } else { diff --git a/schema-engine/sql-migration-tests/tests/migrations/diagnose_migration_history_tests.rs b/schema-engine/sql-migration-tests/tests/migrations/diagnose_migration_history_tests.rs index 9650e6b32cbc..bd6d43553dfa 100644 --- a/schema-engine/sql-migration-tests/tests/migrations/diagnose_migration_history_tests.rs +++ b/schema-engine/sql-migration-tests/tests/migrations/diagnose_migration_history_tests.rs @@ -569,7 +569,7 @@ fn diagnose_migrations_history_reports_migrations_failing_to_apply_cleanly(api: assert!( known_error.message.contains("yolo") || known_error.message.contains("YOLO") - || known_error.message.contains("(not available)") + || known_error.message.contains("MISSING") ); } _ => panic!("assertion failed"),