Use SCMTool IDs to look up repositories when possible.
Review Request #13973 — Created June 12, 2024 and submitted — Latest diff uploaded
Many versions of Review Board currently have a bug where sending an
unknown value in the tool= parameter to the repository list API would
cause a crash. We'll be shipping a fix for that, but unfortunately there
are a variety of released versions where the Git and ClearCase clients
can trigger this crash on servers that do not have Power Pack installed.This change fixes the RBTools side to not include the Power Pack SCMTool
names, which will avoid the problem for existing servers. For new
servers, we'll be shipping a server-side fix that fixes the crash, adds
the SCMTool IDs to the capabilities, and allows us to pass SCMTool IDs
rather than names to the repository list API. If we see the IDs in the
capability blob, we can assume that we can pass the IDs, including
potentially unknown IDs.This also fixes a problem where we were sometimes accessing the
repository list API twice with exactly the same parameters.
- Ran unit tests.
- Verified that the repository list API was accessed using SCMTool names
that did not include potentially missing ones when running against an
older server. - Verified that the repository list API was accessed with SCMTool IDs
when running against a server with the new API fixes.