Skip to content

Conversation

bspratt
Copy link
Member

@bspratt bspratt commented Oct 18, 2024

…r make the FileModifiedException more informative
@bspratt bspratt requested a review from brendanx67 October 18, 2024 22:49
Replace(TextUtil.SEPARATOR_TSV_STR, @" ");
errorList.Add(new TransitionImportErrorInfo(x.PlainMessage, x.ColumnIndex, x.LineNumber + 1, line)); // CONSIDER: worth the effort to pull row and column info from error message?
}
catch (Exception ex)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't think this is the right place to put this. This is supposed to be for issues with parsing a line, not for global errors. You should be catching other exceptions higher up the callstack.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Catching it here is advantageous as it ties into the reporting mechanism for both the UI and commandline use cases.

{
errorList.Add(new TransitionImportErrorInfo(x));
}
catch (Exception ex)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't think this is the right place to put this. This is supposed to be for issues with parsing a line, not for global errors. You should be catching other exceptions higher up the callstack.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Catching it here is advantageous as it ties into the reporting mechanism for both the UI and commandline use cases.

@bspratt
Copy link
Member Author

bspratt commented Nov 12, 2024

@brendanx67 do you still want to change this? I could add two sets of error handling (UI and commandline) if you feel strongly about it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants