[or-cvs] r20503: {torflow} Demote a common ERROR line due to socks timeout. (torflow/trunk/NetworkScanners/BwAuthority)

mikeperry at seul.org mikeperry at seul.org
Tue Sep 8 19:33:43 UTC 2009


Author: mikeperry
Date: 2009-09-08 15:33:43 -0400 (Tue, 08 Sep 2009)
New Revision: 20503

Modified:
   torflow/trunk/NetworkScanners/BwAuthority/bwauthority.py
Log:

Demote a common ERROR line due to socks timeout.                                



Modified: torflow/trunk/NetworkScanners/BwAuthority/bwauthority.py
===================================================================
--- torflow/trunk/NetworkScanners/BwAuthority/bwauthority.py	2009-09-08 19:31:53 UTC (rev 20502)
+++ torflow/trunk/NetworkScanners/BwAuthority/bwauthority.py	2009-09-08 19:33:43 UTC (rev 20503)
@@ -118,6 +118,13 @@
     return 0
   except KeyboardInterrupt:
     raise KeyboardInterrupt
+  except socks.Socks5Error, e:
+    if e.value[0] == 6:
+      plog("NOTICE", "Tor timed out our SOCKS stream request.")
+    else:
+      plog('ERROR', 'An unknown HTTP error occured')
+      traceback.print_exc()
+    return 0
   except:
     plog('ERROR', 'An unknown HTTP error occured')
     traceback.print_exc()
@@ -264,8 +271,8 @@
                 max_fetch_time, sleep_start, sleep_stop, slice_num,
                 min_streams, sql_file)
 
-      # XXX: Temporary for debugging memory leak..
-      TorUtil.dump_class_ref_counts(referrer_depth=1)
+      # For debugging memory leak..
+      #TorUtil.dump_class_ref_counts(referrer_depth=1)
 
       # TODO: Change pathlen to 3 and kill exit+ConserveExit restrictions
       # And record circ failure rates..



More information about the tor-commits mailing list