Skip to content

Conversation

@makhalin
Copy link

Previously, using sa.BINARY, sa.LargeBinary, or sa.BLOB resulted in an AttributeError because ydb_dbapi lacks the Binary attribute required by SQLAlchemy's default bind_processor for these types.

This change introduces Binary, a custom type that inherits from sa.LargeBinary but overrides bind_processor to bypass the call to dbapi.Binary and pass the raw bytes directly. This type is mapped to sa.BINARY, sa.LargeBinary, and sa.BLOB in the dialect's colspecs.

@makhalin makhalin changed the title Feat/binary type Support for sa.BINARY and sa.BLOB types Dec 19, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant