Switch to unified view
a/scripts/trac_export.py | b/scripts/trac_export.py | ||
---|---|---|---|
... |
... |
||
197 | try: |
197 | try: |
198 | f = self.csvopen(url) |
198 | f = self.csvopen(url) |
199 | except urllib2.HTTPError, e: |
199 | except urllib2.HTTPError, e: |
200 | if 'emulated' in e.msg: |
200 | if 'emulated' in e.msg: |
201 | body = e.fp.read() |
201 | body = e.fp.read() |
202 | if 'beyond the number of pages in the query' in body: |
202 | if 'beyond the number of pages in the query' in body or 'Log in with a SourceForge account' in body: |
203 | raise StopIteration |
203 | raise StopIteration |
204 | raise |
204 | raise |
205 | reader = csv.reader(f) |
205 | reader = csv.reader(f) |
206 | cols = reader.next() |
206 | cols = reader.next() |
207 | for r in reader: |
207 | for r in reader: |