{"id":23037168,"url":"https://github.com/fonttools/py-zopfli","last_synced_at":"2026-04-06T03:36:40.666Z","repository":{"id":43411790,"uuid":"79144052","full_name":"fonttools/py-zopfli","owner":"fonttools","description":"Python bindings to zopfli","archived":false,"fork":false,"pushed_at":"2024-10-18T15:23:47.000Z","size":167,"stargazers_count":12,"open_issues_count":4,"forks_count":9,"subscribers_count":5,"default_branch":"master","last_synced_at":"2025-03-30T00:11:08.024Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/fonttools.png","metadata":{"files":{"readme":"README.rst","changelog":null,"contributing":null,"funding":null,"license":"COPYING","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2017-01-16T17:55:54.000Z","updated_at":"2024-10-18T15:19:51.000Z","dependencies_parsed_at":"2024-01-22T04:08:52.718Z","dependency_job_id":"238a3b63-a4ec-49ca-8433-066e7b193e09","html_url":"https://github.com/fonttools/py-zopfli","commit_stats":{"total_commits":99,"total_committers":6,"mean_commits":16.5,"dds":0.6363636363636364,"last_synced_commit":"3545f04a70d8f3c7d938b884ed616c92c2dbc354"},"previous_names":["obp/zopfli","obp/py-zopfli"],"tags_count":18,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fonttools%2Fpy-zopfli","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fonttools%2Fpy-zopfli/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fonttools%2Fpy-zopfli/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fonttools%2Fpy-zopfli/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/fonttools","download_url":"https://codeload.github.com/fonttools/py-zopfli/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247419861,"owners_count":20936012,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-12-15T17:29:34.763Z","updated_at":"2026-04-06T03:36:40.658Z","avatar_url":"https://github.com/fonttools.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"|Build Status|\n\nPYZOPFLI\n========\n\ncPython bindings for\n`zopfli \u003chttp://googledevelopers.blogspot.com/2013/02/compress-data-more-densely-with-zopfli.html\u003e`__.\n\nIt requires Python 3.10 or greater.\n\nUSAGE\n=====\n\npyzopfli is a straight forward wrapper around zopfli's ZlibCompress method.\n\n::\n\n    from zopfli.zlib import compress\n    from zlib import decompress\n    s = 'Hello World'\n    print decompress(compress(s))\n\npyzopfli also wraps GzipCompress, but the API point does not try to\nmimic the gzip module.\n\n::\n\n    from zopfli.gzip import compress \n    from StringIO import StringIO\n    from gzip import GzipFile\n    print GzipFile(fileobj=StringIO(compress(\"Hello World!\"))).read()\n\nBoth zopfli.zlib.compress and zopfli.gzip.compress support the following\nkeyword arguments. All values should be integers; boolean parmaters are\ntreated as expected, 0 and \u003e0 as false and true.\n\n-  *verbose* dumps zopfli debugging data to stderr\n\n-  *numiterations* Maximum amount of times to rerun forward and backward\n   pass to optimize LZ77 compression cost. Good values: 10, 15 for small\n   files, 5 for files over several MB in size or it will be too slow.\n\n-  *blocksplitting* If true, splits the data in multiple deflate blocks\n   with optimal choice for the block boundaries. Block splitting gives\n   better compression. Default: true (1).\n\n-  *blocksplittinglast* If true, chooses the optimal block split points\n   only after doing the iterative LZ77 compression. If false, chooses\n   the block split points first, then does iterative LZ77 on each\n   individual block. Depending on the file, either first or last gives\n   the best compression. Default: false (0).\n\n-  *blocksplittingmax* Maximum amount of blocks to split into (0 for\n   unlimited, but this can give extreme results that hurt compression on\n   some files). Default value: 15.\n\nTODO\n====\n\n-  Stop reading the entire file into memory and support streaming\n\n-  Monkey patch zlib and gzip so code with an overly tight binding can\n   be easily modified to use zopfli.\n\n.. |Build Status| image:: https://github.com/fonttools/py-zopfli/actions/workflows/ci.yml/badge.svg?branch=master\n   :target: https://github.com/fonttools/py-zopfli/actions/workflows/ci.yml\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffonttools%2Fpy-zopfli","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ffonttools%2Fpy-zopfli","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffonttools%2Fpy-zopfli/lists"}