Move support flags out of RepositoryInfo into SCMClient.

Review Request #11520 — Created March 12, 2021 and submitted — Latest diff uploaded

Information

RBTools
master

Reviewers

RepositoryInfo had two old flags for indicating support for features,
supports_changesets and supports_parent_diffs. Having these in
the RepositoryInfo class was weird, since we have a bunch of other
support flags that live on the SCMClient class. Whether a client
supports these isn't something that might change from repository to
repository, so these should live on the client too.

This change moves those flags over. Unfortunately, unlike a lot of the
recent cleanups, this isn't something that can be done in a soft
deprecation. It seems pretty unlikely that there are custom SCMClient
implementations floating around which use these, but just in case, if
they try to use it after upgrading to RBTools 3.0, it'll spit out a
useful error message telling them how to fix it.

Ran unit tests.

Diff Revision 2

This is not the most recent revision of the diff. The latest diff is revision 3. See what's changed.

orig
1
2
3

Commits

First Last Summary ID Author
Move support flags out of RepositoryInfo into SCMClient.
`RepositoryInfo` had two old flags for indicating support for features, `supports_changesets` and `supports_parent_diffs`. Having these in the `RepositoryInfo` class was weird, since we have a bunch of other support flags that live on the `SCMClient` class. Whether a client supports these isn't something that might change from repository to repository, so these should live on the client too. This change moves those flags over. Unfortunately, unlike a lot of the recent cleanups, this isn't something that can be done in a soft deprecation. It seems pretty unlikely that there are custom SCMClient implementations floating around which use these, but just in case, if they try to use it after upgrading to RBTools 3.0, it'll spit out a useful error message telling them how to fix it. Testing Done: Ran unit tests.
e36bde23f6815e441356bc9233949df43287c045 David Trowbridge
rbtools/clients/__init__.py
rbtools/clients/bazaar.py
rbtools/clients/clearcase.py
rbtools/clients/git.py
rbtools/clients/mercurial.py
rbtools/clients/perforce.py
rbtools/clients/plastic.py
rbtools/clients/svn.py
rbtools/clients/tests/test_bzr.py
rbtools/clients/tests/test_git.py
rbtools/clients/tests/test_mercurial.py
rbtools/commands/post.py
rbtools/commands/stamp.py
Loading...