[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH] gwl/ui: Check for log-events configuration
From: |
Olivier Dion |
Subject: |
Re: [PATCH] gwl/ui: Check for log-events configuration |
Date: |
Mon, 06 Jun 2022 09:25:23 -0400 |
On Mon, 06 Jun 2022, Ricardo Wurmus <rekado@elephly.net> wrote:
> Olivier Dion <olivier.dion@polymtl.ca> writes:
>
>> On Sat, 04 Jun 2022, Ricardo Wurmus <rekado@elephly.net> wrote:
>>> Olivier Dion <olivier.dion@polymtl.ca> writes:
>>>
>>>> Some GWL sub-commands such as `graph' do not accept a log event
>>>> configuration.
>>>> This results in returning `#f' from `(%config 'log-events)'
>>>
>>> I don’t understand how this leads to a problem. Do any of the features
>>> of “graph” use “log-event”?
>>
>> Yes. `load-workflow' -> `load-workflow*' -> `load*' -> `log-event 'info
>> "Loading workflow file"'.
>
> I see.
>
> Does it make sense to support the --log-events option on “graph”? Or
> should we just work around it in the log-event procedure?
I think that in all cases, the default of `(%config 'log-events)' should
be '() like you proposed. In that way, if new commands are added in the
future, this undesired behavior won't re-surface.
As for adding the `--log-events` option to the `graph' command. The
thing is that the output of the graph is printed on stdout. Adding
log-event would add an extra step in order to separate the logs from the
desired output. Thus, I think that if we do that, we also need to add a
`--output=DOT' option for redirecting the graph's output away from the
terminal.
WDY?
--
Olivier Dion
oldiob.dev
[PATCH 1/3] gwl/ui: Check for log-events configuration, Olivier Dion, 2022/06/06