MCPcopy Create free account
hub / github.com/apify/crawlee-python / compress_gzip

Function compress_gzip

tests/unit/_utils/test_sitemap.py:69–71  ·  view source on GitHub ↗

Compress a string using gzip.

(data: str)

Source from the content-addressed store, hash-verified

67
68
69def compress_gzip(data: str) -> bytes:
70 """Compress a string using gzip."""
71 return gzip.compress(data.encode())
72
73
74def encode_base64(data: bytes) -> str:

Calls

no outgoing calls

Tested by

no test coverage detected