nydus icon indicating copy to clipboard operation
nydus copied to clipboard

Use thiserror crate to simply errors across the repo

Open liubogithub opened this issue 3 years ago • 1 comments

Errors like DaemonError, RafsError can be simplified with the abilities provided in thiserror crate.

For instance, display, from can be derived directly if using thiserror.

liubogithub avatar Jul 06 '21 19:07 liubogithub

Thanks for your suggestion. It sounds like a good idea.

changweige avatar Jul 08 '21 01:07 changweige

#1027 PR seems to have resolved this issue

adamqqqplay avatar Feb 01 '23 01:02 adamqqqplay

It seems only part of them be handled in https://github.com/dragonflyoss/image-service/pull/1027 ?

imeoer avatar Feb 01 '23 02:02 imeoer

Addition: the target of using thiserror & andhow is to remove the api/src/error.rs file.

imeoer avatar Oct 26 '23 07:10 imeoer