Skip to content

Instantly share code, notes, and snippets.

View haelmj's full-sized avatar
🏠
Working from home

Michael Ndon haelmj

🏠
Working from home
View GitHub Profile
@haelmj
haelmj / chunked_server_test.py
Created April 27, 2021 16:27 — forked from josiahcarlson/chunked_server_test.py
Use some standard Python libraries to implement a chunked-transfer encoding web server with partially-working gzip support
'''
chunked_server_test.py
Copyright August 3, 2012
Released into the public domain
This implements a chunked server using Python threads and the built-in
BaseHTTPServer module. Enable gzip compression at your own peril - web
browsers seem to have issues, though wget, curl, Python's urllib2, my own
async_http library, and other command-line tools have no problems.