Make some improvements to our changesets code.
Review Request #4236 — Created June 12, 2013 and submitted
Make some improvements to our changesets code. The existing stuff for changesets is pretty heavily biased towards Perforce--from assuming that the changeset ID will only be a number, to doing some queries that will only make sense for servers that support pending changesets with a server-side representation. This change adds a "supports_pending_changesets" property to scmtools and gates things based on that.
Ran unit tests, used this in conjunction with my post-commit branch.
-
Looks good. Just one thing I think would help code flow.
-
I think this could look a little more cleaner and easier to follow as: if not scmtool.supports_pending_changesets: raise NotImplementedError changeset = ... if not changeset or not changeset.pending: raise InvalidChangeNumberError self.update_from_pending_change(...)