Skip to content

plots/metrics/params(?): stop throwing exceptions #5525

@pared

Description

@pared

After writing fix for #5490 It seems to me that we should be handling exceptions thrown during plots/metrics/params differently.

For some time now we have been drifting towards approach that communicates problems with warnings instead of exceptions. And in case of plots/metrics/params commands it does make sense, as its ok for those commands to do "as much as possible" (eg, show all metrics besides that faulty one, instead of crippling whole command and not allowing user to see anything). This approach is also not ideal, every now and then I have discussion with @dmpetrov on why plots/metrics flood terminal with warnings in some cases, which reminds me of time when we used a lot of warn calls in other parts of code, and had the same problem.

I think that we should gather the exceptions preventing us from displaying particular file at particular revision and return them as part of result and let the error handling happen after doing as much as possible. Errors can still be logged to debug, and in case of dvc plots/metrics command we could issue single warning, like "10 out of 1000 plots could not be shown. Use -v to see why".

Metadata

Metadata

Assignees

Labels

discussionrequires active participation to reach a conclusionp1-importantImportant, aka current backlog of things to douiuser interface / interaction

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions