Code review comment for lp:~garyvdm/bzr/PublicStackedParentsProvider

Revision history for this message
John A Meinel (jameinel) wrote :

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Gary van der Merwe wrote:
> Gary van der Merwe has proposed merging lp:~garyvdm/bzr/PublicStackedParentsProvider into lp:bzr.
>
> Requested reviews:
> bzr-core (bzr-core)
>
> The patch make StackedParentsProvider a public api. It also adds a test to check that overlaping revisions from the different providers are handled correctly.
>
     def __repr__(self):
- - return "_StackedParentsProvider(%r)" % self._parent_providers
+ return "StackedParentsProvider(%r)" % self._parent_providers

^- we generally try to do:

return "%s(%r)" % (self.__class__.__name__, self._parent_providers)

so that you don't have to update these things, and so that child classes
automatically get named the right thing, too.

We might want to add:

@deprecated((0,1, 16)
def _StackedParentsProvider(*args, **kwargs):
  return StackedParentsProvider(*args, **kwargs)

I realize we don't *need* to by our contract rules. But where we can, it
is a lot nicer to start giving deprecation warnings, rather than causing
existing code to just start breaking.

John
=:->

 Review: approve

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (Cygwin)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iEYEARECAAYFAkoeZFMACgkQJdeBCYSNAANTBQCcCGnzpFlAqI74sq5veUieoEOP
5BgAn2Jk/pRDdA+Vh/2ZUDS35bRo8kiC
=12aX
-----END PGP SIGNATURE-----

« Back to merge proposal