Commit 79ad8e2
committed
Add link about Python 2 GZip workaround [ci skip]
Lest we or others wonder what this workaround is doing. Link back to the
PR comment for details.
TL;DR - GZip on Python 2 (and Python pre-3.5) determines the number of
bytes included via `len`, which is needed for the GZip footer. This will
be incorrect if the data is not flattened and using a single byte type.
Hence we cast to `uint8` here to satisfy this constraint. On Python 3.5+
this is not needed as it casts the data to a `memoryview` and accesses
the `nbytes` attribute to determine this.
ref: #128 (comment)1 parent df60e2f commit 79ad8e2
1 file changed
+1
-0
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
29 | 29 | | |
30 | 30 | | |
31 | 31 | | |
| 32 | + | |
32 | 33 | | |
33 | 34 | | |
34 | 35 | | |
| |||
0 commit comments