[PATCH hglib] hglib: Move string literals in the test code to util.b() (issue4520)
mpm at selenic.com
Wed Mar 11 11:19:25 CDT 2015
On Wed, 2015-03-11 at 15:15 +0000, Brett Cannon wrote:
> On Tue, Mar 10, 2015 at 6:20 PM Matt Mackall <mpm at selenic.com> wrote:
> > On Mon, 2015-03-09 at 18:26 -0400, Brett Cannon wrote:
> > > # HG changeset patch
> > > # User Brett Cannon <brett at python.org>
> > > # Date 1425939985 14400
> > > # Mon Mar 09 18:26:25 2015 -0400
> > > # Node ID 4c0f97d377a0d193743f1b43481dadefc1880cd0
> > > # Parent fe74d55995393f6a72abce49da8d43e5fe37cdcd
> > > hglib: Move string literals in the test code to util.b() (issue4520)
> > Various things spotted by our automated checks (check-code and
> > check-commit in the hg repo):
> > - please don't uppercase "Move" in summary above
> > > + rev0, node0 = self.client.commit(b('first'), addremove=True,
> > > + date=now.isoformat('
> > ').encode('latin-1'))
> > - this and a couple other lines are too long
> > > - print rev0, node0
> > > + print(rev0, node0)
> > - not portable
> Not portable how? It works in every version of Python because Python 2
> prints a tuple while Python 3 prints two space-separate values.
Yep.. which isn't portable in my book. But check-code's complaint is
more of the form "don't pretend keywords like print and return and raise
are functions, it's bad style".
We should probably just drop these as they don't appear to serve a
Mathematics is the supreme nostalgia of our time.
More information about the Mercurial-devel