From 96df26fdfe7e651716d5c84c50ce8981714efbc8 Mon Sep 17 00:00:00 2001 From: cthomas Date: Sat, 19 Jul 2025 22:03:22 -0700 Subject: [PATCH] feat: remove groups selectin on blocks model (#3423) --- letta/orm/block.py | 2 +- letta/serialize_schemas/marshmallow_block.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/letta/orm/block.py b/letta/orm/block.py index 40dfcf08..a653eb16 100644 --- a/letta/orm/block.py +++ b/letta/orm/block.py @@ -74,7 +74,7 @@ class Block(OrganizationMixin, SqlalchemyBase): groups: Mapped[List["Group"]] = relationship( "Group", secondary="groups_blocks", - lazy="selectin", + lazy="raise", back_populates="shared_blocks", passive_deletes=True, ) diff --git a/letta/serialize_schemas/marshmallow_block.py b/letta/serialize_schemas/marshmallow_block.py index 6325f2c8..15ff703b 100644 --- a/letta/serialize_schemas/marshmallow_block.py +++ b/letta/serialize_schemas/marshmallow_block.py @@ -12,4 +12,4 @@ class SerializedBlockSchema(BaseSchema): class Meta(BaseSchema.Meta): model = Block - exclude = BaseSchema.Meta.exclude + ("agents", "identities", "is_deleted") + exclude = BaseSchema.Meta.exclude + ("agents", "identities", "is_deleted", "groups")