Re: [sqlalchemy] 'validates' include_removes=True doesn't seem to prevent deletion?

2021-10-05 Thread Mike Bayer
On Mon, Oct 4, 2021, at 9:49 PM, niuji...@gmail.com wrote: > I have the following validator: > > @sa_orm.validates('variant_names', include_removes=True) > def validate_unique_identifying(self, key, name_dict, > is_remove): > if is_remove: >

[sqlalchemy] 'validates' include_removes=True doesn't seem to prevent deletion?

2021-10-04 Thread niuji...@gmail.com
I have the following validator: @sa_orm.validates('variant_names', include_removes=True) def validate_unique_identifying(self, key, name_dict, is_remove): if is_remove: raise ValueError("DOn't") else: if