Label forkserver child as `subint_forkserver`
Follow-up to 72d1b901 (was prev commit adding `debug_mode` for
`subint_forkserver`): that commit wired the runtime-side
`subint_forkserver` SpawnSpec-recv gate in `Actor._from_parent`, but the
`subint_forkserver_proc` child-target was still passing
`spawn_method='trio'` to `_trio_main` — so `Actor.pformat()` / log lines
would report the subactor as plain `'trio'` instead of the actual
parent-side spawn mechanism. Flip the label to `'subint_forkserver'`.
(this patch was generated in some part by [`claude-code`][claude-code-gh])
[claude-code-gh]: https://github.com/anthropics/claude-code
parent
72d1b9016a
commit
4425023500
|
|
@ -655,12 +655,16 @@ async def subint_forkserver_proc(
|
||||||
loglevel=loglevel,
|
loglevel=loglevel,
|
||||||
parent_addr=parent_addr,
|
parent_addr=parent_addr,
|
||||||
infect_asyncio=infect_asyncio,
|
infect_asyncio=infect_asyncio,
|
||||||
# NOTE, from the child-side runtime's POV it's
|
# The child's runtime is trio-native (uses
|
||||||
# a regular trio actor — it uses `_trio_main`,
|
# `_trio_main` + receives `SpawnSpec` over IPC),
|
||||||
# receives `SpawnSpec` over IPC, etc. The
|
# but label it with the actual parent-side spawn
|
||||||
# `subint_forkserver` name is a property of HOW
|
# mechanism so `Actor.pformat()` / log lines
|
||||||
# the parent spawned, not of what the child is.
|
# reflect reality. Downstream runtime gates that
|
||||||
spawn_method='trio',
|
# key on `_spawn_method` group `subint_forkserver`
|
||||||
|
# alongside `trio`/`subint` where the SpawnSpec
|
||||||
|
# IPC handshake is concerned — see
|
||||||
|
# `runtime._runtime.Actor._from_parent()`.
|
||||||
|
spawn_method='subint_forkserver',
|
||||||
)
|
)
|
||||||
return 0
|
return 0
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue