diff mercurial/httprepo.py @ 2336:f77edcffb837

http: print better error if exception happens.
author Vadim Gelfer <vadim.gelfer@gmail.com>
date Mon, 22 May 2006 09:00:24 -0700
parents ce67fa312f61
children 3f24bc5dee81
line wrap: on
line diff
--- a/mercurial/httprepo.py
+++ b/mercurial/httprepo.py
@@ -106,7 +106,9 @@ class httprepository(remoterepository):
         try:
             resp = urllib2.urlopen(cu)
         except httplib.HTTPException, inst:
-            raise IOError(None, _('http error while sending %s command') % cmd)
+            self.ui.debug(_('http error while sending %s command\n') % cmd)
+            self.ui.print_exc()
+            raise IOError(None, inst)
         proto = resp.headers['content-type']
 
         # accept old "text/plain" and "application/hg-changegroup" for now