asteca / ASteCA

Code for the ASteCA package.
http://asteca.github.io/
MIT License
18 stars 6 forks source link

Add full_error_output flag #232

Closed Gabriel-p closed 8 years ago

Gabriel-p commented 9 years ago

Add a flag called full_error_out that, if enabled, activates the traceback error.

If this flag is false, only print the internal ASteCA error notice.

How the params_input.dat file should look:

############################ ASteCA's inner flags ##############################

# Update checker.
#
# Check if a new version of ASteCA is available for download, and notify the
# user when one is found. This requires less than 25 bytes of data and is thus
# very quick. To turn this automatic check off, set this flag to 'false'.
#
#   flag
UP  true

# Full error traceback.
#
# * flag: true / false. Used for debugging purposes. Set to 'true' to print
# the full traceback of an error.
#
#   flag
FE  false

# Force matplotlib backend to 'Agg'.
#
# * flag: true / false. Set to 'true' to prevent the error 'TclError: no
#   display name and no $DISPLAY environment variable' when running the code
#   in a server.
#
#   flag
FB  false
################################################################################
Gabriel-p commented 8 years ago

Not sure if this is a good idea. Full tracebacks are useful, custom messages are not.

Gabriel-p commented 8 years ago

This is not helpful. The code should always print the full traceback, accompanied by a custom simpler message when possible.