Restore friendly error messages

Use --verbose if you really want a full traceback with your 'you made a
typo in an package ID' messages.

It would be better to do this based on exception types (i.e. our own
exceptions - MetadataException, BuildException, VCSException) would not
print a traceback, but unexpected exceptions would. But the types are
not available at the 'fdroid' level currently.
This commit is contained in:
Ciaran Gultnieks 2014-05-20 22:14:19 +01:00
parent 6391f204e1
commit e29da6b023
3 changed files with 12 additions and 4 deletions

View file

@ -907,7 +907,7 @@ class BuildException(Exception):
return ret
def __str__(self):
ret = repr(self.value)
ret = self.value
if self.detail:
ret += "\n==== detail begin ====\n%s\n==== detail end ====" % self.detail.strip()
return ret
@ -918,7 +918,7 @@ class VCSException(Exception):
self.value = value
def __str__(self):
return repr(self.value)
return self.value
# Get the specified source library.