Skip to content

PARAF-527: Ordered imio.esign signers by held position, removed ones dropped from the order - #157

Open
chris-adam wants to merge 3 commits into
masterfrom
PARAF-527/signers_order
Open

chris-adam wants to merge 3 commits into
masterfrom
PARAF-527/signers_order

Conversation

@chris-adam

@chris-adam chris-adam commented Oct 2, 2026 •

Copy link
Copy Markdown
Contributor

https://support-imio.atlassian.net/browse/PARAF-527

Feeds the imio.esign signers order with one entry per signer held position: imio.esign.signers is the cached OMSignersVocabulary, and ItemSignersAdapter.sort_signers (outgoing mails and sign requests) sorts by held position rank, then signer number. Removed signers are dropped from the order by the held position subscribers, new ones sign last until ordered, and a personnel dashboard viewlet lists the signers missing from the order.

⚠️ Depends on IMIO/imio.esign#50. Sessions are matched on userid/email: the same person on two held positions can share a session.

🤖 Generated with Claude Code

Summary by CodeRabbit

  • New Features
    • Signers can be ordered by their configured held positions when signing sessions are created or recreated. Other signers follow in a consistent order, and signers no longer in the configured order are excluded from it.
    • Signer choices refresh when personnel contacts or held positions change. A signer-order view is available on the personnel dashboard.
  • Bug Fixes
    • Corrected warning display behavior when configuring a demo site.

@coderabbitai

coderabbitai Bot commented Oct 2, 2026 •

Copy link
Copy Markdown

Review in Change Stack →

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration
  • Configuration used: defaults
  • Review profile: CHILL
  • Plan: Essentials
  • Run ID: f6019a06-3850-4eb2-a49b-de9d18c70e3b

📥 Commits

Reviewing files that changed from the base of the PR and between d623c21 and cca7766.


📒 Files selected for processing (15)
  • CHANGES.rst
  • imio/dms/mail/adapters.py
  • imio/dms/mail/adapters.zcml
  • imio/dms/mail/browser/configure.zcml
  • imio/dms/mail/browser/viewlets.py
  • imio/dms/mail/browser/views.py
  • imio/dms/mail/overrides.zcml
  • imio/dms/mail/steps.py
  • imio/dms/mail/subscribers.py
  • imio/dms/mail/tests/test_adapters.py
  • imio/dms/mail/tests/test_subscribers.py
  • imio/dms/mail/tests/test_viewlets.py
  • imio/dms/mail/tests/test_views.py
  • imio/dms/mail/tests/test_vocabularies.py
  • imio/dms/mail/utils.py

💤 Files with no reviewable changes (1)
  • imio/dms/mail/browser/views.py

Included review availability: This review used your included allowance. 3 included reviews remain after this review. Your included PR review attempts over the past 7 days set your current allowance at 5 reviews per hour.



📝 Walkthrough

Walkthrough

The change adds configured eSign signer ordering for signing sessions, maintains signer vocabulary and registry data as personnel records change, and registers a signer-order viewlet for the personnel dashboard. It also guards a demo-site warning call when no request is available.

Changes

eSign signer ordering

Layer / File(s) Summary
Signer vocabulary and registry synchronization
imio/dms/mail/overrides.zcml, imio/dms/mail/subscribers.py, imio/dms/mail/utils.py, imio/dms/mail/tests/test_subscribers.py, imio/dms/mail/tests/test_vocabularies.py, CHANGES.rst
The signer vocabulary is registered and refreshed when relevant personnel contacts or held-position usages change. Approver updates also refresh the configured signer order. Tests cover vocabulary contents and registry updates. The changelog records the signer-order change.
Signer ordering in signing sessions
imio/dms/mail/adapters.py, imio/dms/mail/adapters.zcml, imio/dms/mail/tests/test_adapters.py, imio/dms/mail/tests/test_views.py
The adapter sorts signers by configured held-position order when enforcement is enabled, then by signer number. Its registration covers sign-request objects. Tests cover sorting and recreated-session order.
Personnel dashboard signer-order viewlet
imio/dms/mail/browser/viewlets.py, imio/dms/mail/browser/configure.zcml, imio/dms/mail/tests/test_viewlets.py
A signer-order viewlet is registered for the personnel dashboard. Tests cover terms shown for personnel folders, people, and held positions.

Request-aware setup warning

Layer / File(s) Summary
Guard setup warning by request availability
imio/dms/mail/steps.py
The demo-site warning is shown only when a request exists, and the request is passed to show_message.

Priority: ⬇️ Low

Estimated code review effort: 3 (Moderate) | ~20 minutes

Change: Feature

Suggested reviewers: sgeulette


Merge Risk: ⚪ Minimal · up to cca77

No identified issue remains that needs resolution before merge.

Pre-merge checks | Passed 4 | Failed 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage Warning Docstring coverage is 48.39% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 31 functions across 10 files. (4 skipped:… Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (4 passed)
Check name Status Explanation
Description Check Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check Passed The title clearly and concisely describes the main change: ordering imio.esign signers by held position and removing signers dropped from the order.
Linked Issues check Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check Passed Check skipped because no linked issues were found for this pull request.

Full details: Docstring Coverage

Explanation

Docstring coverage is 48.39% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 31 functions across 10 files. (4 skipped: 4 unsupported.)


  • Fix all pre-merge checks with AI
✨ Finishing Touches 💡 1
📝 Generate docstrings 💡
  • Commit to this branch
  • Create a new PR

🧪 Generate unit tests (beta)
  • Commit to this branch
  • Create a new PR

  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Comment @coderabbitai help to get the list of available commands.

@chris-adam
chris-adam force-pushed the PARAF-527/signers_order branch from d4bae64 to d42a94c Compare October 5, 2026 09:50
…dropped from the order

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@chris-adam
chris-adam force-pushed the PARAF-527/signers_order branch from d42a94c to e243598 Compare October 5, 2026 14:01
chris-adam and others added 2 commits October 7, 2026 17:32
…lso for sign requests

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant