Exception caught is assumed to have strerror attribute

Bug #1277187 reported by Brad Crittenden
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Juju Charm Tools
Triaged
High
Unassigned

Bug Description

When running charm-proof -b on something that is not recognized to be a bundle, the exception is raised but then not processed by an error in the exception handling when e.strerror does not exist.

An absurd example

[trunk]bac@trusty64:~/projects/juju-quickstart$ charm-proof -b ~/.emacs
Traceback (most recent call last):
  File "/usr/bin/charm-proof", line 9, in <module>
    load_entry_point('charm-tools==1.2.8', 'console_scripts', 'charm-proof')()
  File "/usr/lib/python2.7/dist-packages/charmtools/proof.py", line 63, in main
    args.debug)
  File "/usr/lib/python2.7/dist-packages/charmtools/proof.py", line 54, in proof
    return ["FATAL: %s" % e.strerror], 200
AttributeError: 'exceptions.Exception' object has no attribute 'strerror'

It was raising the 'Not a bundle' exception, which can be found in e.message.

Marco Ceppi (marcoceppi)
Changed in charm-tools:
milestone: none → 1.3.1
importance: Undecided → High
status: New → Triaged
Marco Ceppi (marcoceppi)
Changed in charm-tools:
milestone: 1.3.1 → 1.3.2
Marco Ceppi (marcoceppi)
Changed in charm-tools:
milestone: 1.3.2 → 1.3.3
Marco Ceppi (marcoceppi)
Changed in charm-tools:
milestone: 1.3.3 → 1.3.4
Marco Ceppi (marcoceppi)
Changed in charm-tools:
milestone: 1.3.4 → none
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.