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

Fix TypeError and address Ralph's comment about supressing the exception reason. #3

Merged
merged 2 commits into from
Aug 5, 2016
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 4 additions & 2 deletions bugwarrior/command.py
Original file line number Diff line number Diff line change
Expand Up @@ -29,16 +29,18 @@ def _get_section_name(flavor):
return 'general'


def _try_load_config(main_section, interactive):
def _try_load_config(main_section, interactive=False):
try:
return load_config(main_section, interactive)
except IOError:
# Our standard logging configuration depends on the bugwarrior
# configuration file which just failed to load.
logging.basicConfig()

exc_info = sys.exc_info()
log.critical("Could not load configuration. "
"Maybe you have not created a configuration file.")
"Maybe you have not created a configuration file.",
exc_info=(exc_info[0], exc_info[1], None))
sys.exit(1)


Expand Down