Std.Async: Unix domain stream sockets (listen, connect, accept, peer credentials)
I maintainer di solito rispondono entro 1 giorno
Nessuno ha ancora preso questa issue.
Valutazione
- Difficoltà
- 5/5
- Tempo stimato
- Più di una settimana
- Idoneità per principianti
- 35/100
- Tipo di issue
- Funzionalità
- Chiarezza
- Specificata chiaramente
- Stato di attività
- Attiva
- Ambito
- backend
Direzione di ricerca
Read the Std.Async and Std.Internal.UV socket implementations and RFC #13638, which the issue identifies as the proposed Pipe wrapper. Trace how uv_pipe_t supports binding, connecting, listening, accepting, and peer credentials across the stated platforms. Done means the requested server and client APIs, including receive selectors and credentials, are available; arbitrary SCM_RIGHTS transfer is out of scope.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
Description
Std.Async has TCP and UDP sockets but no Unix domain sockets. Local servers commonly need them: a Wayland compositor, a daemon's control socket, a socket behind a login proxy. Two Lean projects, Aether (github.com/Verilean/aether) and lean-tea (github.com/Verilean/lean-tea), each carry their own C binding for socket(AF_UNIX) / bind / listen / accept / connect.
What they need:
- Listen on a path, with the socket's file mode set before
listen, so no client connects through a looser mode. Replacing a stale socket file at the path is a common convenience. - Connect to a path.
- Accept, recv and send with the same API as
Std.Async.TCP.Socket.Client, includingrecvSelector. - The peer's credentials (
SO_PEERCREDon Linux,getpeereidon BSD/macOS): uid, and pid where available.
libuv's uv_pipe_t already provides 1–3 (uv_pipe_bind, uv_pipe_connect, uv_listen, uv_accept, and uv_pipe_chmod; on Windows, named pipes). RFC #13638 proposes a Pipe wrapper around uv_pipe_t for anonymous and named pipes; this request is for its socket server/client side.
Out of scope, for completeness: passing arbitrary file descriptors with SCM_RIGHTS (Wayland sends shared-memory fds this way). libuv only passes its own handles over IPC pipes, so we do not expect this in Std.Async.
Steps to Reproduce
Search Std.Internal.UV and Std.Async in v4.36.0 for AF_UNIX or uv_pipe: there is none.
Expected behavior: a Std.Async Unix-socket (or Pipe) server and client.
Actual behavior: projects write and maintain C bindings and, because those block, run one dedicated task per connection.
Versions
Lean 4.36.0 (x86_64-unknown-linux-gnu), also checked against v4.37.0-rc1.
Impact
Add 👍 to issues you consider important. If others benefit from the changes in this issue, please add 👍 to it.
- Lingua principale
- Lean
- Stelle
- 10.3k
- Fork
- 1.1k
- Merge medio
- 16h 45m
- PR unite (30g)
- 361
Preparare l'ambiente
- Nessun Dockerfile né file Docker Compose
- Ha un modello di pull request
- Leggi la guida per i contributori
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di leanprover/lean4
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 68/100
leanprover/lean4#16876 · 1 commento ·
I maintainer di solito rispondono entro 1 giorno
-
bug
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
leanprover/lean4#16842 ·
I maintainer di solito rispondono entro 1 giorno
-
bug
Difficoltà 2/5 1-3 ore Idoneità per principianti 72/100
leanprover/lean4#16841 ·
I maintainer di solito rispondono entro 1 giorno
-
bug
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 82/100
leanprover/lean4#16840 ·
I maintainer di solito rispondono entro 1 giorno
-
doc: stray "public" in Bool and HEq documentationForse di nuovo libera Una pull request per questa issue è stata chiusa senza essere unita. Aperta
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 72/100
leanprover/lean4#16825 ·
I maintainer di solito rispondono entro 1 giorno
Tutte le issue di leanprover/lean4
Issue simili
-
Thai project names become 'project', 'project-2'… (slug keeps ASCII only)Forse già presa @mastel2 l’ha presa oggi. Aperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 72/100
storytold/craft-anything#2538 ·
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 70/100
compiler-explorer/compiler-explorer#9738 ·
I maintainer di solito rispondono entro 2 giorni
-
Difficoltà 1/5 1-3 ore Idoneità per principianti 88/100
I maintainer di solito rispondono entro 3 giorni
-
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 88/100
openfoodfacts/openfoodfacts-python#573 ·
I maintainer di solito rispondono entro 2 giorni
-
Rasterio reads over HTTPS do not send the Earthdata token and return 500 "HTTP response code: 404"Apertacredentials rasterio
Difficoltà 2/5 1-3 ore Idoneità per principianti 76/100
developmentseed/titiler-cmr#359 ·
I maintainer di solito rispondono entro 1 giorno