<feed xmlns='http://www.w3.org/2005/Atom'>
<title>luasocket/docs, branch feat/sse</title>
<subtitle>A mirror of https://github.com/lunarmodules/luasocket.git
</subtitle>
<id>https://git.lua4.win/luasocket/atom?h=feat%2Fsse</id>
<link rel='self' href='https://git.lua4.win/luasocket/atom?h=feat%2Fsse'/>
<link rel='alternate' type='text/html' href='https://git.lua4.win/luasocket/'/>
<updated>2026-09-01T05:54:16+00:00</updated>
<entry>
<title>Address PR review: pass raw socket to headers callback, use ok/err return convention</title>
<updated>2026-09-01T05:54:16+00:00</updated>
<author>
<name>Thijs Schreijer</name>
<email>thijs@thijsschreijer.nl</email>
</author>
<published>2026-09-01T05:54:16+00:00</published>
<link rel='alternate' type='text/html' href='https://git.lua4.win/luasocket/commit/?id=0a4fa559e44ed3e77f723092feab977539b8aab0'/>
<id>urn:sha1:0a4fa559e44ed3e77f723092feab977539b8aab0</id>
<content type='text'>
Rename response_headers to headers_callback, pass the raw connection as a
4th argument (for use cases like WebSocket upgrade handoff), and switch its
return contract to the idiomatic ok/err shape used elsewhere in this file:
truthy ok continues (optionally swapping in a new sink), falsy ok closes the
connection and propagates the callback's error via socket.protect instead of
faking a success return.

Claude-Session: https://claude.ai/code/session_01S4imKCU4hxDg96DXj9hxSB
</content>
</entry>
<entry>
<title>Add Lua 5.5 support (#473)</title>
<updated>2026-08-31T15:21:20+00:00</updated>
<author>
<name>Caleb Maclennan</name>
<email>caleb@alerque.com</email>
</author>
<published>2026-08-31T15:21:20+00:00</published>
<link rel='alternate' type='text/html' href='https://git.lua4.win/luasocket/commit/?id=fa9b35a0cf11bc856cbd8bffbef5ad6fb3e62a93'/>
<id>urn:sha1:fa9b35a0cf11bc856cbd8bffbef5ad6fb3e62a93</id>
<content type='text'>
</content>
</entry>
<entry>
<title>Merge pull request #472 from lunarmodules/feat/url-hosttype</title>
<updated>2026-08-31T08:08:19+00:00</updated>
<author>
<name>Caleb Maclennan</name>
<email>caleb@alerque.com</email>
</author>
<published>2026-08-31T08:08:19+00:00</published>
<link rel='alternate' type='text/html' href='https://git.lua4.win/luasocket/commit/?id=8e00f02f24d8618fcbff42c93a7ee512f694cc2f'/>
<id>urn:sha1:8e00f02f24d8618fcbff42c93a7ee512f694cc2f</id>
<content type='text'>
feat(url): classify host as name/ipv4/ipv6 in parse and build</content>
</entry>
<entry>
<title>Merge pull request #470 from lunarmodules/header-canon</title>
<updated>2026-08-31T08:03:24+00:00</updated>
<author>
<name>Caleb Maclennan</name>
<email>caleb@alerque.com</email>
</author>
<published>2026-08-31T08:03:24+00:00</published>
<link rel='alternate' type='text/html' href='https://git.lua4.win/luasocket/commit/?id=5afe174eeffc7f3e3b9ef80b5871237620c68415'/>
<id>urn:sha1:5afe174eeffc7f3e3b9ef80b5871237620c68415</id>
<content type='text'>
feat(headers): dynamically create cononicalized headers</content>
</entry>
<entry>
<title>Merge pull request #463 from lunarmodules/feat/receive-limit</title>
<updated>2026-08-31T07:57:58+00:00</updated>
<author>
<name>Caleb Maclennan</name>
<email>caleb@alerque.com</email>
</author>
<published>2026-08-31T07:57:58+00:00</published>
<link rel='alternate' type='text/html' href='https://git.lua4.win/luasocket/commit/?id=8f18ce95bb38c7f5c4bef5b3684cf1b0df1fc266'/>
<id>urn:sha1:8f18ce95bb38c7f5c4bef5b3684cf1b0df1fc266</id>
<content type='text'>
feat(receive): add maxsize argument to bound memory usage</content>
</entry>
<entry>
<title>chore(docs): add docs for SO_EXCLUSIVEADDRUSE and others</title>
<updated>2026-08-31T07:52:00+00:00</updated>
<author>
<name>Thijs Schreijer</name>
<email>thijs@thijsschreijer.nl</email>
</author>
<published>2026-08-30T13:58:20+00:00</published>
<link rel='alternate' type='text/html' href='https://git.lua4.win/luasocket/commit/?id=a9a1e25fdec1faba0237a554027a0f717f132c51'/>
<id>urn:sha1:a9a1e25fdec1faba0237a554027a0f717f132c51</id>
<content type='text'>
Adds docs for the option, but also adds the docs for other
options present in the code but missing from the docs.
</content>
</entry>
<entry>
<title>feat(url): classify host as name/ipv4/ipv6 in parse and build</title>
<updated>2026-08-30T13:34:15+00:00</updated>
<author>
<name>Thijs Schreijer</name>
<email>thijs@thijsschreijer.nl</email>
</author>
<published>2026-08-30T13:34:15+00:00</published>
<link rel='alternate' type='text/html' href='https://git.lua4.win/luasocket/commit/?id=6fe110be47c0fc34bc9dce6d377ce9b48ab27c2e'/>
<id>urn:sha1:6fe110be47c0fc34bc9dce6d377ce9b48ab27c2e</id>
<content type='text'>
parse() now sets hosttype ("name"/"ipv4"/"ipv6") plus a matching
hostname/ipv4/ipv6 field alongside host. build() accepts those same
fields when host is absent, erroring if more than one is set.

classify_host is exported for standalone use; it classifies by shape
(colon present -&gt; ipv6, dotted-quad shape -&gt; ipv4) rather than
validating the address.
</content>
</entry>
<entry>
<title>feat(headers): dynamically create cononicalized headers</title>
<updated>2026-08-29T17:43:26+00:00</updated>
<author>
<name>Thijs Schreijer</name>
<email>thijs@thijsschreijer.nl</email>
</author>
<published>2026-08-29T17:39:35+00:00</published>
<link rel='alternate' type='text/html' href='https://git.lua4.win/luasocket/commit/?id=a63fa963b7bd01f1b470bea7c5a2ed326ff760e6'/>
<id>urn:sha1:a63fa963b7bd01f1b470bea7c5a2ed326ff760e6</id>
<content type='text'>
Instead of a static list dynamically add entries in proper casing.
Also allowing to add non-standard ones through `setcanonic`.

closes #442
fixes #440
</content>
</entry>
<entry>
<title>chore(docs): some cleanup</title>
<updated>2026-08-17T05:39:55+00:00</updated>
<author>
<name>Thijs Schreijer</name>
<email>thijs@thijsschreijer.nl</email>
</author>
<published>2026-08-17T05:39:55+00:00</published>
<link rel='alternate' type='text/html' href='https://git.lua4.win/luasocket/commit/?id=e912d157b242e661dca37d0a8269202dda974ba7'/>
<id>urn:sha1:e912d157b242e661dca37d0a8269202dda974ba7</id>
<content type='text'>
</content>
</entry>
<entry>
<title>feat(receive): add maxsize argument to bound memory usage</title>
<updated>2026-07-30T20:06:04+00:00</updated>
<author>
<name>Thijs Schreijer</name>
<email>thijs@thijsschreijer.nl</email>
</author>
<published>2026-07-30T17:22:17+00:00</published>
<link rel='alternate' type='text/html' href='https://git.lua4.win/luasocket/commit/?id=73b0780321acb14bab6707006f5136ea9998951d'/>
<id>urn:sha1:73b0780321acb14bab6707006f5136ea9998951d</id>
<content type='text'>
client:receive("*l") and receive("*a") are unbounded: a peer that never
sends a newline, or never closes, makes LuaSocket buffer until the
process runs out of memory (e.g. src/http.lua reading response headers
in a loop). Add an optional maxsize argument that caps the payload a
single call may accumulate, including prefix.

- Hoist all argument validation ahead of timeout_markstart() so bad
  calls (maxsize &lt; 1, #prefix &gt;= maxsize, numeric pattern &gt; maxsize)
  raise before any I/O and leave the socket untouched.
- recvline/recvall take a budget and return a new internal
  BUF_OVERSIZED code, surfaced to Lua as the "oversized" error
  alongside "timeout"/"closed", with the partial held in the 3rd
  return value.
- recvraw is left untouched: argument checks make the cap unreachable
  for numeric patterns.
- Preserve three invariants: a timeout partial is always shorter than
  maxsize (safe to retry as prefix), completion beats the cap for *a,
  and no bytes are lost or skipped on overflow.
- tcp.c, unixstream.c and serial.c all share this code path unchanged.

Adds test coverage (argument errors, *l/*a boundaries, timeout/close
at the cap, the drain idiom, numeric patterns, unix-stream mirror) and
documents the new argument, error, and recovery idioms in docs/tcp.html.
</content>
</entry>
</feed>
