django-bulk-hooks 0.1.229__py3-none-any.whl → 0.1.230__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.

Potentially problematic release.


This version of django-bulk-hooks might be problematic. Click here for more details.

@@ -1,6 +1,5 @@
1
1
  import logging
2
2
 
3
- from django.conf import settings as django_settings
4
3
  from django.core.exceptions import ValidationError
5
4
  from django.db import transaction
6
5
 
@@ -123,9 +122,6 @@ def run(model_cls, event, new_records, old_records=None, ctx=None):
123
122
  hook_vars.model = None
124
123
  hook_vars.depth -= 1
125
124
 
126
- # AFTER_* timing policy: default immediate; optional on-commit
127
- use_on_commit = bool(getattr(django_settings, "BULK_HOOKS_AFTER_ON_COMMIT", False))
128
- if event.startswith("after_") and use_on_commit and transaction.get_connection().in_atomic_block:
129
- transaction.on_commit(_execute)
130
- else:
131
- _execute()
125
+ # Execute immediately so AFTER_* runs within the transaction.
126
+ # If a hook raises, the transaction is rolled back (Salesforce-style).
127
+ _execute()
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.3
2
2
  Name: django-bulk-hooks
3
- Version: 0.1.229
3
+ Version: 0.1.230
4
4
  Summary: Hook-style hooks for Django bulk operations like bulk_create and bulk_update.
5
5
  License: MIT
6
6
  Keywords: django,bulk,hooks
@@ -3,7 +3,7 @@ django_bulk_hooks/conditions.py,sha256=7C0enCYMgmIP0WO9Sf_rBbmdHC1yORMELAFoyuBcG
3
3
  django_bulk_hooks/constants.py,sha256=3x1H1fSUUNo0DZONN7GUVDuySZctTR-jtByBHmAIX5w,303
4
4
  django_bulk_hooks/context.py,sha256=L95s1n9N5oBdfdrIA3_zoi0tf7GnDVrQxYaSXPwBkvg,2626
5
5
  django_bulk_hooks/decorators.py,sha256=3x16zCsEFIvjg2ld1tUnweH0SWqT0SwrRKRdFs0nC4Y,8523
6
- django_bulk_hooks/engine.py,sha256=HGAXa9XsG3ilWdoA9rExp6sQZpm02Pkt9CSlq_gRs0I,4974
6
+ django_bulk_hooks/engine.py,sha256=0Wd3PKTQbrEfAYe0i0pzAmY_MtUYSo3uUkMOXhrCBuo,4748
7
7
  django_bulk_hooks/enums.py,sha256=ZSYPwHcjlAMrISOHb9sqNjEfxyv4XupoDoe1hn87VJg,499
8
8
  django_bulk_hooks/handler.py,sha256=BKthdeCrgzuLzvy_UUfGLjFFZipAHzuxoelaH6zJVWo,5468
9
9
  django_bulk_hooks/manager.py,sha256=uqmvGlskkzKMERf3iexxXCAaQl0v3Wc45BeN-YmfTnE,4060
@@ -11,7 +11,7 @@ django_bulk_hooks/models.py,sha256=1m1POWtfAhWUBrr2uTUEPzBFJpBfAf8WlKUu8muB3z8,6
11
11
  django_bulk_hooks/priority.py,sha256=EGFBbRmX_LhwRYFCKzM8I5m8NGCsUEVJp2pfNTcoHe4,378
12
12
  django_bulk_hooks/queryset.py,sha256=u8Abj_W5cABM9pi-vQG_6zGsekbPI6It3tA_zDHUDC4,37480
13
13
  django_bulk_hooks/registry.py,sha256=eIjT6xolQYSGbakTOfRDrrc8J6gv0DnYI9rpHAo6XVk,4380
14
- django_bulk_hooks-0.1.229.dist-info/LICENSE,sha256=dguKIcbDGeZD-vXWdLyErPUALYOvtX_fO4Zjhq481uk,1088
15
- django_bulk_hooks-0.1.229.dist-info/METADATA,sha256=1gWbfBTL8ROM7ng-JOB8fawz9xj5v3X1chqLxuApgLM,9743
16
- django_bulk_hooks-0.1.229.dist-info/WHEEL,sha256=b4K_helf-jlQoXBBETfwnf4B04YC67LOev0jo4fX5m8,88
17
- django_bulk_hooks-0.1.229.dist-info/RECORD,,
14
+ django_bulk_hooks-0.1.230.dist-info/LICENSE,sha256=dguKIcbDGeZD-vXWdLyErPUALYOvtX_fO4Zjhq481uk,1088
15
+ django_bulk_hooks-0.1.230.dist-info/METADATA,sha256=GM3fPWUU0Na_q490s_d95-3N-MMNaXinsicS8E0T5mw,9743
16
+ django_bulk_hooks-0.1.230.dist-info/WHEEL,sha256=b4K_helf-jlQoXBBETfwnf4B04YC67LOev0jo4fX5m8,88
17
+ django_bulk_hooks-0.1.230.dist-info/RECORD,,