[BUG] Strict commit is a little too strict :}
Michael Ellerman
michael at ellerman.id.au
Wed Oct 19 06:49:27 BST 2005
Blush,
My strict commit patch from the other day is a little too strict,
in that --strict won't let you commit ... ever.
Fix is here: http://michael.ellerman.id.au/files/bzr
------------------------------------------------------------
revno: 1301
committer: Michael Ellerman <michael at ellerman.id.au>
timestamp: Wed 2005-10-19 15:37:33 +1000
message:
Strict commit was a little .. ah .. too strict, oops :}
branch.unknowns() returns a generator, so we can't do if branch.unknowns(),
it's always True.
if len(list(branch.unknowns())) might look cleanest, but creating the list of
unknowns is not cheap for large numbers of unknown files.
Instead we use a for loop to raise an exception as soon as we get one unknown
back from the generator.
Add more tests to make sure this doesn't break again.
cheers
--
Michael Ellerman
IBM OzLabs
email: michael:ellerman.id.au
inmsg: mpe:jabber.org
wwweb: http://michael.ellerman.id.au
phone: +61 2 6212 1183 (tie line 70 21183)
We do not inherit the earth from our ancestors,
we borrow it from our children. - S.M.A.R.T Person
More information about the bazaar
mailing list