Skip to content
New issue

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

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

Already on GitHub? Sign in to your account

Make exception messages more consistent. #3205

Merged
merged 1 commit into from Oct 5, 2016

Conversation

bangerth
Copy link
Member

@bangerth bangerth commented Oct 5, 2016

In particular, change the following two things: (i) Say 'Additional information'
instead of 'Additional Information' because the rest of the text is also
capitalized in the common way. (ii) Indent the actual (additional) error text
by four characters, just like the other additional pieces of information.

The result is that errors now look like this:

--------------------------------------------------------
An error occurred in line <710> of file </home/fac/f/bangerth/p/deal.II/1/install/examples/step-6/step-6.cc> in function
    int main()
The violated condition was:
    false
Additional information:
    abcdef

Stacktrace:
-----------
#0  ./step-6: main
--------------------------------------------------------

This is a follow-up to #3189.

In particular, change the following two things: (i) Say 'Additional information'
instead of 'Additional Information' because the rest of the text is also
capitalized in the common way. (ii) Indent the actual (additional) error text
by four characters, just like the other additional pieces of information.

The result is that errors now look like this:

--------------------------------------------------------
An error occurred in line <710> of file </home/fac/f/bangerth/p/deal.II/1/install/examples/step-6/step-6.cc> in function
    int main()
The violated condition was:
    false
Additional information:
    abcdef

Stacktrace:
-----------
#0  ./step-6: main
--------------------------------------------------------
@tjhei
Copy link
Member

tjhei commented Oct 5, 2016

Indent the actual (additional) error text
by four characters, just like the other additional pieces of information.

You are only indenting the first line of the additional output though. Wouldn't this look somewhat weird if the additional information wraps over more than one line? (I don't care too much about this so if you feel strongly about it...)

@bangerth
Copy link
Member Author

bangerth commented Oct 5, 2016

Yes, only the first line. It's not quite straightforward to indent all lines because we have no control (at this point) over how these lines are formatted.

Let's try this out, and if we find that it looks awkward I'll think of something else.

@tamiko tamiko merged commit 55698fd into dealii:master Oct 5, 2016
@bangerth bangerth deleted the fix-error-message-2 branch October 6, 2016 02:49
@bangerth bangerth mentioned this pull request Oct 6, 2016
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.

None yet

4 participants