[rfc] transport activity locally?

Martin Pool mbp at canonical.com
Tue Jul 21 09:00:28 BST 2009

2009/7/21 John Arbash Meinel <john at arbash-meinel.com>:
> Hash: SHA1
> Martin Pool wrote:
>> That's what I was planning to do next - but I think there is a lot of
>> code that bypasses it.
>>> On Jul 20, 2009 11:37 PM, "Aaron Bentley" <aaron at aaronbentley.com
>>> <mailto:aaron at aaronbentley.com>> wrote:
>> Martin Pool wrote: > The annoying thing here is that it says all
>> application code needs to > know w...
>> We can make Command.outf pb-aware.  I think that would handle
>> everything, assuming we carefully stamped out all use of sys.stdout.
>> Aaron
> We also have to have 'trace.note()' which wants to use the logging
> module and eventually writes to sys.stderr. And all the other
> 'trace.XXX' functions know about the current UI factory and to call
> '.clear()'.

Right, those are some of the other things.  I think really they should
be all writing to a (somewhat) file-like object that coordinates with
the progress bar, so that 'clear it off, i have some output' is done

> At one point we tried putting the functionality on "ProgressBar" itself,
> but I'm pretty sure we decided to deprecate that.

I think functions that don't themselves want to report on progress
shouldn't have to have a progress bar - either being passed around as
a pb parameter, or for the sake of reporting messages; that implies
that pb.note() is probably not a good idea.

> FWIW bzrlib.trace.note() may already call ui.ui_factory...clear_somethnig()

Martin <http://launchpad.net/~mbp/>

More information about the bazaar mailing list