SourceForge: pypt-offline/pypt-offline: changeset 393:2c77c95b70a7
We could get errors with the old lib where it wants a number, but sometimes fails to get one forest
authorRitesh Raj Sarraf <rrs@researchut.com>
Thu Jun 04 14:32:13 2009 +0530 (5 months ago)
branchforest
changeset 3932c77c95b70a7
parent 3928a87abfb9f75
child 39471cdf354553e
We could get errors with the old lib where it wants a number, but sometimes fails to get one
debianbts.py
     1.1 --- a/debianbts.py	Thu Jun 04 14:31:42 2009 +0530
     1.2 +++ b/debianbts.py	Thu Jun 04 14:32:13 2009 +0530
     1.3 @@ -852,7 +852,11 @@
     1.4  
     1.5  def get_report(number, system='debian', mirrors=None,
     1.6                 http_proxy='', archived=False, followups=False):
     1.7 -    number = int(number)
     1.8 +
     1.9 +    try:
    1.10 +            number = int(number)
    1.11 +    except ValueError:
    1.12 +            sys.stderr.write("%s couldn't be convered to integer.\nPlease report a bug" % (number) )
    1.13      if SYSTEMS[system].get('cgiroot'):
    1.14          result = get_cgi_report(number, system, http_proxy, archived,
    1.15                                  followups)