summaryrefslogtreecommitdiff
path: root/doc/tips/googledriveannex/comment_7_3a645a0cd1e4c939b7a4b8a97a0e9b03._comment
blob: 970a5e7b5dc6672af47961ac7e7c89f3ef84eb0a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
[[!comment format=mdwn
 username="http://joeyh.name/"
 ip="209.250.56.54"
 subject="comment 7"
 date="2014-10-06T15:23:59Z"
 content="""
Hugo, I didn't write this code, but it looks to me like you could work around the problem by changing line 207 of lib/CommonFunctions.py:

<pre>
diff --git a/lib/CommonFunctions.py b/lib/CommonFunctions.py
index 050b93e..083f5d6 100644
--- a/lib/CommonFunctions.py
+++ b/lib/CommonFunctions.py
@@ -204,7 +204,7 @@ def fetchPage(params={}):
         if get(\"progress\"):
             data = False
             tdata = \"\"
-            totalsize = int(con.headers['content-length'])
+            totalsize = 0
             chunksize = totalsize / 100
             if chunksize < 4096:
                 chunksize = 4096
</pre>

Probably the API used to return a content-length header, and no longer does, or doesn't do so reliably. It does not seem to be used for anything too important -- this change will break git-annex's progress display a little bit, perhaps.
"""]]