Question: I have dumped a packet bytes from wireshark and try to use the python to uncompress it. here is the code.

```
st="78DAE3E266E42CA92C4865616404000B0D01E8"
print(st)
d=zlib.decompressobj();
d.decompress(st)

```

and that errors 

```
Traceback (most recent call last):
File "C:\Documents and Settings\Administrator\Desktop\fu.py", line 6, in <module>
d.decompress(st)
zlib.error: Error -3 while decompressing: unknown compression method

```

I have also try to use the `lzma` and `gzip`( just change the decompressobj parameter) , not work.

But when I use the `Flex AIR` to uncompress the bytes is ok.

The uncompress result from AIR is `0a0b010974797065040101`

How can I solve this problem in python ?

Answer: 
I've tried to uncompress the compressed string and compress the uncompressed string, but I get very different values than you have. I highly doubt that the string is in fact a zipped string.
maybe you should convert string to hex first

```
st="78DAE3E266E42CA92C4865616404000B0D01E8"
print(st)
hex_  = st.decode("hex")
d=zlib.decompressobj();
d.decompress(hex_)

```