[ https://issues.apache.org/jira/browse/AVRO-386?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12828982#action_12828982 ]
Philip Zeyliger commented on AVRO-386: -------------------------------------- You're totally right about the default value. I've been burned by leaving mutable things as default arguments in python (because they bind once), so I tend to use None, but strings are immutable in python, so, voila. I've fixed it. I neglected to answer: bq. Line 285: comment on what the argument of "-15" means to zlib.decompress It turns zlib into "raw" mode (that's negative) and indicates the window size (that's the maximum, 15). {quote} (from zlib.h on my system) windowBits can also be -8..-15 for raw inflate. In this case, -windowBits determines the window size. inflate() will then process raw deflate data, not looking for a zlib or gzip header, not generating a check value, and not looking for any check values for comparison at the end of the stream. This is for use with other formats that use the deflate compressed data format such as zip. Those formats provide their own check values. If a custom format is developed using the raw deflate format for compressed data, it is recommended that a check value such as an adler32 or a crc32 be applied to the uncompressed data as is done in the zlib, gzip, and zip formats. For most applications, the zlib format should be used as is. Note that comments above on the use in deflateInit2() applies to the magnitude of windowBits. {quote} > Python implementation of compression > ------------------------------------ > > Key: AVRO-386 > URL: https://issues.apache.org/jira/browse/AVRO-386 > Project: Avro > Issue Type: Improvement > Components: python > Affects Versions: 1.3.0 > Reporter: Philip Zeyliger > Assignee: Philip Zeyliger > Attachments: AVRO-386.patch.txt, AVRO-386.patch.txt > > > AVRO-135 introduced compression. AVRO-368 changed some metadata keys. The > patch to follow adds this functionality to the python implementation. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.