Open josephjclark opened 2 months ago
Hello @josephjclark I have added the sanitization policy as proposed and it seems to be serving the purpose. I am a bit unsure about the approach, as I had another approach in mind where we could add a log function (warn, debug, success etc.) which might also serve the same purpose. I am unsure about these but hopefully you will guide me through. Best Regards
I've been thinking about this after @SatyamMattoo's PR. The original issue is slightly confused and I'll have to address it in the week.
In the meantime here are better notes:
The logger already supports a log=none
mode which is used by the CLI.
Right now the worker always uses debug
, so that all logs are returned and can be filtered by the user.
What we need is for the worker to support a logLevel
option. This should be defaulted on startup and override by run options.
Later, Lightning can choose to set the log level to none
whenever it wishes.
We need to support a mode where all logging is disabled - logs don#t go to stdout and don't go to lightning.
Right now have a bunch of logging policies, I think they're called sanitisation policies? We proably just need to ensure there's one of those for "silent"
I don't think this is supported today