Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Generalize exceptions #301

Open
fcollot opened this issue Oct 16, 2017 · 2 comments
Open

Generalize exceptions #301

fcollot opened this issue Oct 16, 2017 · 2 comments
Assignees

Comments

@fcollot
Copy link

fcollot commented Oct 16, 2017

One of the major architectural changes I would like to make to MUSIC is to fix the current error handling mechanism which isn't very well standardised and has a lot of code cloned here and there. This is important because currently when the program fails, depending on what failed, it sometimes crashes, sometimes does nothing, sometimes gives a warning that is not easily visible etc. The overall user experience is frustrating.

Currently the code is split up between parts that use error codes and parts that use exceptions. It doesn't help that DTK uses error codes, ITK uses exceptions and VTK doesn't use either but uses events (so you have to add an observer for the error).

There is a lot of debate about which one is better, but I personally prefer exceptions and after having transitioned from error codes to exceptions in the pipeline system there is no doubt for me that they are much better suited to the architecture of MUSIC.

@fcollot
Copy link
Author

fcollot commented Oct 16, 2017

(There is a large part of the code that doesn't do anything when there is an error, and simply returns from the function. This is equivalent to ignoring errors altogether and makes it impossible to debug properly).

@fcollot
Copy link
Author

fcollot commented May 24, 2018

As mentioned in https://github.com/Inria-Asclepios/music-clinical-pipelines/pull/20 I'm working on the issue of error handling.

@fcollot fcollot self-assigned this May 24, 2018
# for free to join this conversation on GitHub. Already have an account? # to comment
Projects
None yet
Development

No branches or pull requests

1 participant