From 3107464d7f5e00d174eeaba2910a8257813d408e Mon Sep 17 00:00:00 2001 From: Eric Eastwood Date: Mon, 1 Jun 2026 18:13:01 -0500 Subject: [PATCH] Iterate PyO3 --- rust/src/db.rs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/rust/src/db.rs b/rust/src/db.rs index 5f45c05c69..6fcbba85d2 100644 --- a/rust/src/db.rs +++ b/rust/src/db.rs @@ -13,7 +13,7 @@ * */ -use pyo3::{ffi::PyObject, intern, prelude::*}; +use pyo3::{intern, prelude::*}; #[derive(Copy, Clone, Debug)] pub enum DatabaseEngine { @@ -34,7 +34,7 @@ impl DatabaseEngine { /// Wrapper for a `LoggingTransaction` from the Python side of Synapse. pub struct LoggingTransactionWrapper<'py> { /// The underlying `LoggingTransaction` - raw: Bound<'py, PyObject>, + raw: Bound<'py, PyAny>, database_engine: DatabaseEngine, } @@ -51,7 +51,7 @@ impl<'py> FromPyObject<'_, 'py> for LoggingTransactionWrapper<'py> { .name() .expect("Expected `LoggingTransaction.database_engine` to have a type name") .to_str() - .expect("Expected to be able to convert the `LoggingTransaction.database_engine` type to a string") + .expect("Expected to be able to convert the `LoggingTransaction.database_engine` type name to a string") { "PostgresEngine" => DatabaseEngine::Postgres, "Sqlite3Engine" => DatabaseEngine::Sqlite,