Rework the ReviewRequestApprovalHook docs for better flow and guidance.

Review Request #14757 — Created Jan. 1, 2026 and updated

Information

Review Board
release-7.1.x

Reviewers

The ReviewRequestApprovalHook docs were pretty old and did little to
communicate the expectations of the hook. The very first sentence said
these were new in Review Board 2.0.

This change reworks the docs to clearly describe what approval state is
for and where it's used, the execution and chaining model of these
hooks, the signature of is_approved() methods, examples, and best
practices.

Typing and docs for the affected codepaths have been updated as well to
reflect what's shown in the guide and to link back to it.

Built the docs and checked the references/links on all affected code.

Ran content through ChatGPT for analysis and suggestions.

Summary ID
Rework the ReviewRequestApprovalHook docs for better flow and guidance.
The `ReviewRequestApprovalHook` docs were pretty old and did little to communicate the expectations of the hook. The very first sentence said these were new in Review Board 2.0. This change reworks the docs to clearly describe what approval state is for and where it's used, the execution and chaining model of these hooks, the signature of `is_approved()` methods, examples, and best practices. Typing and docs for the affected codepaths have been updated as well to reflect what's shown in the guide and to link back to it.
9552ba8a5d3f866120211119e82c8d7660bbc0b2
Description From Last Updated

This reads a little bit awkward. The review request isn't a user, the review request author (or submitter) is a …

daviddavid

Based on the docstring, this should be bool | tuple[bool, str | None] (str -> bool)

daviddavid
david
  1. 
      
  2. Show all issues

    This reads a little bit awkward. The review request isn't a user, the review request author (or submitter) is a user.

  3. Show all issues

    Based on the docstring, this should be bool | tuple[bool, str | None] (str -> bool)

  4. 
      
chipx86
Review request changed
Change Summary:
  • Fixed an awkwardly-worded comment in an example.
  • Fixed a bad return type in the hook.
Commits:
Summary ID
Rework the ReviewRequestApprovalHook docs for better flow and guidance.
The `ReviewRequestApprovalHook` docs were pretty old and did little to communicate the expectations of the hook. The very first sentence said these were new in Review Board 2.0. This change reworks the docs to clearly describe what approval state is for and where it's used, the execution and chaining model of these hooks, the signature of `is_approved()` methods, examples, and best practices. Typing and docs for the affected codepaths have been updated as well to reflect what's shown in the guide and to link back to it.
e16867a5bb3c4853e5f204d8fe9a5ae373120e8e
Rework the ReviewRequestApprovalHook docs for better flow and guidance.
The `ReviewRequestApprovalHook` docs were pretty old and did little to communicate the expectations of the hook. The very first sentence said these were new in Review Board 2.0. This change reworks the docs to clearly describe what approval state is for and where it's used, the execution and chaining model of these hooks, the signature of `is_approved()` methods, examples, and best practices. Typing and docs for the affected codepaths have been updated as well to reflect what's shown in the guide and to link back to it.
9552ba8a5d3f866120211119e82c8d7660bbc0b2

Checks run (2 succeeded)

flake8 passed.
JSHint passed.
david
  1. Ship It!
  2.