To help ensure we’re all on the same page, I’ve gone ahead and implemented the 
new functionality via the following PR:

Base: add lower-level debug output, via new levels debug1-3:
https://github.com/macports/macports-base/pull/243

It’s very close to working; all that’s left is to export the new ui_debugX 
calls to the TCL realm. And if anyone’s willing to share the secret to the 
latter, I’d appreciate it, as I’m still scratching my head on that one. 
(Normally I’d expect that we’d use ‘Tcl_CreateObjCommand’, but that’s not being 
done - or I missed where it’s being done - for the existing ‘ui_xxx’ logging 
procedures.)


> On 2021-05-26-W, at 09:38, Christopher Nielsen <[email protected]> 
> wrote:
> 
> I’m referring to debug output like the following, in this cases taken from 
> one of our builtbot logs. Some of these are generated by base, while others 
> are generated by the portgroups themselves.
> 
> While I’m not necessarily advocating that we hide all of these (via output at 
> level debug2 or debug3), we’d have the option.
> 
> Does that make sense?
> 
> DEBUG: Sourcing PortGroup legacysupport 1.1 from 
> /opt/bblocal/var/buildworker/ports/build/ports/_resources/port1.0/group/legacysupport-1.1.tcl
> DEBUG: Sourcing PortGroup compiler_wrapper 1.0 from 
> /opt/bblocal/var/buildworker/ports/build/ports/_resources/port1.0/group/compiler_wrapper-1.0.tcl
> DEBUG: Re-registering default for universal_variant
> DEBUG: Re-registering default for use_configure
> DEBUG: Re-registering default for dist_subdir
> DEBUG: Re-registering default for worksrcdir
> […etc…]
> 
>> On 2021-05-26-W, at 09:30, Ryan Schmidt <[email protected]> wrote:
>> 
>>> On May 26, 2021, at 06:07, Christopher Nielsen wrote:
>>> 
>>> Great question!
>>> 
>>> One of the key things this would allow us to do, is reduce our current 
>>> Debug output, by outputting less-important details at Debug2 or Debug3. For 
>>> example, if we don’t want to see some of the ui_debug messages from our 
>>> various portgroups - like, say, the numerous messages related to adding 
>>> port callbacks - we could modify those to output some things at ui_debug2 
>>> or ui_debug3.
>>> 
>>> So if we needed to diagnose precisely what portgroup callbacks are added, 
>>> those diagnostic messages could be enabled by setting the output level [via 
>>> the port command] to Debug2 or Debug3. But at the current Debug level, 
>>> they’d be hidden, making things less verbose.
>>> 
>>> Does that make sense?
>> 
>> I'm not familiar with "numerous messages related to adding port callbacks". 
>> Is this information MacPorts automatically prints when adding a callback, or 
>> something individual portgroups are printing - if so why?

Reply via email to