Releases: cortexm/uhttp-client
Releases · cortexm/uhttp-client
Release list
v2.3.0
Features
- Streaming event mode —
HttpClient(event_mode=True)makeswait()/process_events()returnEVENT_*constants, mirroring uhttp-server'sHttpConnection. AfterEVENT_HEADERSchoose body delivery:accept_body(),accept_body_streaming(),accept_body_to_file(),accept_ndjson(); read viaread_buffer()/read_record()/response. - Chunked transfer encoding — response decoding (works in classic blocking mode too).
- Read-until-close streaming —
request(stream=True)for responses withoutContent-Length/chunked (MJPEG, SSE). - NDJSON streaming —
accept_ndjson()+read_record(), sharing the JSON decode/error path withHttpResponse.json(). Expect: 100-continue—request(expect_continue=True)waits for server confirmation before sending the body.- Fully non-blocking — TCP connect, SSL handshake and HTTP I/O all via
select()(for slow links: 4G modems, ESP32 PPP).
Fixes
- Windows: non-blocking would-block handling (
EWOULDBLOCKdiffers fromEAGAIN),BlockingIOError, non-blocking connect via the select except-set. - MicroPython:
EWOULDBLOCK/EINPROGRESS/ENOENThandling,recv()returningNoneon SSL would-block, missingsocket.getsockopt. - SSL +
select()edge cases.
Internal
- Version derived from git tag (
setuptools-scm). - Pluggable
_BodyReaderframing strategy (Length / Chunked / EOF). - CI integration tests against a local HTTP server and ESP32 MicroPython hardware.
v2.2.1 - CLI tool
added cli-tool uhttp:
- it is similar to curl but simpler, uses uhttp.client module
bugfixes:
- correct processing _ssl.SSLWantReadError and _ssl.SSLWantWriteError
v2.2.0
first release after separating https://github.com/pavelrevak/uhttp
- fixed tests