Skip to content

Commit 1330eef

Browse files
committed
fix: skip stage group notification when assigned_to is resolved
Remove the use_triggering_stage guard from _skip_stage_groups so that when an approval task has an individual assigned_to (resolved via assignee_form_field), the fallback stage approval groups are never notified — regardless of the use_triggering_stage flag. Bump version to 0.63.2.
1 parent 9d0c30c commit 1330eef

File tree

3 files changed

+16
-8
lines changed

3 files changed

+16
-8
lines changed

CHANGELOG.md

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,16 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
77

88
## [Unreleased]
99

10+
## [0.63.2] - 2026-04-02
11+
12+
### Fixed
13+
- **notify_stage_groups skips group when assigned_to is resolved** — when an
14+
approval task has an individual `assigned_to` (resolved via
15+
`assignee_form_field`), the fallback stage approval groups are no longer
16+
notified. Previously this skip only applied when `use_triggering_stage=True`;
17+
it now applies unconditionally, preventing duplicate notifications to both
18+
the resolved individual and the group.
19+
1020
## [0.63.1] - 2026-04-02
1121

1222
### Fixed

django_forms_workflows/tasks.py

Lines changed: 5 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1102,14 +1102,12 @@ def _effective_stage_id():
11021102
_add(email)
11031103

11041104
# 5. Stage approval groups (NotificationRule only)
1105-
# When using the triggering stage and the task already has a specific
1106-
# individual assigned (assigned_to), skip the group notification —
1107-
# the individual was resolved via assignee_form_field so the fallback
1108-
# group should not also be notified.
1105+
# When the task already has a specific individual assigned
1106+
# (assigned_to), skip the group notification — the individual was
1107+
# resolved via assignee_form_field so the fallback group should not
1108+
# also be notified, regardless of use_triggering_stage.
11091109
_skip_stage_groups = (
1110-
getattr(notif, "use_triggering_stage", False)
1111-
and task is not None
1112-
and getattr(task, "assigned_to_id", None) is not None
1110+
task is not None and getattr(task, "assigned_to_id", None) is not None
11131111
)
11141112
if (
11151113
getattr(notif, "notify_stage_groups", False)

pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[tool.poetry]
22
name = "django-forms-workflows"
3-
version = "0.63.1"
3+
version = "0.63.2"
44
description = "Enterprise-grade, database-driven form builder with approval workflows and external data integration"
55
license = "LGPL-3.0-only"
66
readme = "README.md"

0 commit comments

Comments
 (0)