Code review comment for lp://qastaging/~jelmer/bzr-builder/stacked-on

Revision history for this message
Martin Pool (mbp) wrote :

On 11 January 2011 21:49, Jelmer Vernooij <email address hidden> wrote:
> On Wed, 2011-01-12 at 02:51 +0000, Martin Pool wrote:
>> Review: Needs Fixing
>> > stacked=(bzr_version_info >= (2, 3, 0, 'dev', 5)))
>>
>> That comparison is wrong because 2.3.0.beta.5 is lexicographically
>> lower.  Sorry.  (Maybe we should change our encoding to avoid this.)
> Thanks, that's a good point.
>
>> You can use a more complex expression, or just assume 2.3.0.* is enough.
> I'm not sure if it's worth adding a more complex expression here, so
> I've updated it to simply assume that 2.3.0 is enough.

Works for me.

I wonder what the easiest way in Python to introspect "does callable a
accept a parameter b" is? (There is probably no non-Turing-complete
way to check for kwargs, but for statically declared arguments it
seems possible in principle.)

> Another alternative would have been to check for one of the private
> methods that was added by the commit-on-stacked branch, but I'm worried
> that will quietly degrade performance again if it ever gets removed.

I agree, that would be poor.

--
Martin

« Back to merge proposal