[Yum-devel] Logging (no excitement)
Tim Lauridsen
tim at rasmil.dk
Thu Jun 1 06:19:10 UTC 2006
James Bowes wrote:
> Hi:
>
> Tim Lauridsen wrote:
>> I dont know if this patch is the right way to go, it breaks the
>> logging in the yum API, Programs using the API like yumex overloads the
>> log, error, filelog methods in yumbase to redirect the log output fx.
>> to a TextView, other application build on the yum API. yum utils,
>> pup, pirut might be affected too.
>
> It should be easy enough for yumex or other frontends to get ahold of
> the logging output by creating a new StreamHandler and registering it
> with the logging system to catch yum's output.
>
> One of my goals for this was so that other programs using the yum API
> wouldn't have to inherit from YumBase and overload the log methods to
> grab the output. With python's logging module, yum can log where it
> wants to, yumex can display the logging info in a text widget, and Joe
> Developer's crazy plugin can send the output to his yum log
> aggregating Internet appliance. or something.
>
That make sense to me, the more i study the code, the more sense it make
to me
Tim.
More information about the Yum-devel
mailing list