Add type hints for reviewboard.scmtools.core.

Review Request #13064 — Created May 24, 2023 and submitted — Latest diff uploaded

Information

Review Board
release-6.x

Reviewers

This introduces type hints for some of our most important underlying
structures in Review Board. Types are now available for SCMTool,
SCMClient, Branch, Commit, ChangeSet, Revision,
FileLookupContext, and _SCMToolIDProperty.

This should help ensure proper usage of these classes, and proper
implementation of new SCMTools.

Some typing errors and and bad documentation were uncovered while
adding types. For instance, Popen had a bad string conversion and
bad documented return type, and some objects had unsafe comparison
logic. These have been fixed.

Unit tests pass.

Changes between revision 1 and 2

orig
1
2

Commits

Summary ID Author
Add type hints for reviewboard.scmtools.core.
This introduces type hints for some of our most important underlying structures in Review Board. Types are now available for `SCMTool`, `SCMClient`, `Branch`, `Commit`, `ChangeSet`, `Revision`, `FileLookupCnotext`, and `_SCMToolIDProperty`. This should help ensure proper usage of these classes, and proper implementation of new SCMTools.
52606f8a0f7a5fe50020f61be64e8281070a5f34 Christian Hammond
Add type hints for reviewboard.scmtools.core.
This introduces type hints for some of our most important underlying structures in Review Board. Types are now available for `SCMTool`, `SCMClient`, `Branch`, `Commit`, `ChangeSet`, `Revision`, `FileLookupContext`, and `_SCMToolIDProperty`. This should help ensure proper usage of these classes, and proper implementation of new SCMTools.
f308f1e77fc131da5509f323d9814628a8c08685 Christian Hammond
reviewboard/scmtools/core.py
Loading...