Skip to content

[stable31] fix: parallel flow signer status#6173

Merged
vitormattos merged 2 commits intostable31from
backport/6172/stable31
Dec 13, 2025
Merged

[stable31] fix: parallel flow signer status#6173
vitormattos merged 2 commits intostable31from
backport/6172/stable31

Conversation

@backportbot-libresign
Copy link
Copy Markdown

Backport of PR #6172

When file status is ABLE_TO_SIGN (1) in parallel flow, all signers
should be set to ABLE_TO_SIGN regardless of individual signer status
sent by frontend. This fixes the issue where signers remained in DRAFT
status (0) even after clicking 'Request signatures'.

The logic now:
1. Check file status DRAFT first - keep all signers as DRAFT
2. Check file status ABLE_TO_SIGN - apply flow-based logic:
   - Parallel: All signers get ABLE_TO_SIGN
   - Ordered: Only first signer gets ABLE_TO_SIGN
3. Fallback to individual signer status for other cases

Resolves issue where sign_request records stayed at status 0 while
libresign_file was updated to status 1.

Signed-off-by: Vitor Mattos <1079143+vitormattos@users.noreply.github.com>
Added two unit tests to validate status determination logic:

1. testParallelFlowIgnoresSignerDraftStatusWhenFileIsAbleToSign:
   Validates that in parallel flow, all signers are set to ABLE_TO_SIGN
   when file status is ABLE_TO_SIGN, ignoring individual DRAFT status
   sent by frontend.

2. testOrderedFlowRespectsSigningOrderWhenFileIsAbleToSign:
   Validates that in ordered flow, only the first signer (order 1)
   gets ABLE_TO_SIGN status, while subsequent signers remain DRAFT
   until their turn.

Also updated getService() method to accept optional
SequentialSigningService parameter for testing different flows.

Signed-off-by: Vitor Mattos <1079143+vitormattos@users.noreply.github.com>
@github-project-automation github-project-automation Bot moved this to 0. Needs triage in Roadmap Dec 13, 2025
@backportbot-libresign backportbot-libresign Bot added this to the Next Patch (31) milestone Dec 13, 2025
@vitormattos vitormattos merged commit 07285d7 into stable31 Dec 13, 2025
62 checks passed
@github-project-automation github-project-automation Bot moved this from 0. Needs triage to 4. to release in Roadmap Dec 13, 2025
@vitormattos vitormattos deleted the backport/6172/stable31 branch December 13, 2025 19:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

Archived in project

Development

Successfully merging this pull request may close these issues.

1 participant