[patch] deprecation warnings branch

Jamie Wilkinson jaq at spacepants.org
Thu Jan 12 04:29:30 GMT 2006


This one time, at band camp, Robert Collins wrote:
>On Thu, 2006-01-12 at 14:54 +1100, Jamie Wilkinson wrote:
>> This one time, at band camp, Robert Collins wrote:
>> >On Wed, 2006-01-11 at 19:27 +1100, Jamie Wilkinson wrote:
>> >> This one time, at band camp, Robert Collins wrote:
>> >> >@deprecated_function(zero_seven)
>> >> >def get_bzr_revision():
>> >> >    """If bzr is run from a branch, return (revno,revid) or None."""
>> >> >    import bzrlib.errors
>> >> >    ...
>> >> >
>> >> >results in the following pydoc output:
>> >> >Help on function decorated_function in bzrlib:
>> >> >
>> >> >bzrlib.get_bzr_revision = decorated_function(*args, **kwargs)
>> >> >    If bzr is run from a branch, return (revno,revid) or None.
>> >> >    
>> >> >    This function was deprecated in version 0.7.
>> >> >
>> >> >I'm not sure how to change the 'bzrlib.get_bzr_revision =
>> >> >decorated_function(*args, **kwargs)' line - that seems a little ugly to
>> >> >me right now.
>> >> 
>> >> FWIW this also affects the output of build-api, all decorated functions
>> >> appear without documentation and their signature as (self, *args, *kwargs),
>> >> which suck because after tracing the structure in the browser you have to go
>> >> open the file in an editor anyway :)  (Better go learn ctags I guess :)
>> >
>> >the docstrings should be correct on the deprecated though, because of
>> >the work done.
>> 
>> Parse error :)
>> 
>> Do you mean, they should be correct on your deprecated branch, but possibly
>> still broken on bzr.dev?  If so, that clears things up for me :)
>
>The warnings patch is in mainline AFAIK, its definately in integration -
>so the docstrings should be correct for bzr.dev or integration. But only
>on deprecated functions, not on random decorated functions.

Right.

The api docs are still broken then, what will it take to make all decorated
functions display correctly?




More information about the bazaar mailing list