Repository navigation
fix(sdk,perfbench): licensing open race, httpx retry buffering, perfbench -count (D-0621, D-1112, D-0606) - #952
Conversation
|
Rebased onto current origin/main (head a557bb2). The gate log from the host was only a zsh glob error ( |
…nt>1 does not panic (D-0606)
…and check the descriptor, closing the Lstat/Open swap race (D-1112)
… inferred length on the clone only (D-0621)
|
Rebased onto origin/main (head 0b8cba7, force-with-lease). The gate output "Host key verification failed." is an ssh host-key error on the gate host, not a test failure, so no code change was needed for it. On the rebased tree: the root module |
Rows
D-0606 (fixed)
tools/perfbench:TestABRefusesEmptyMetricsandTestMixedUnitsFailTheRunregistered global scenarios inside the test body, so-count>1panicked "registered twice" (the second one also panicked once the first was fixed). Both now register ininit(), like the existingfakeScenario.D-1112 (fixed)
sdk/go/licensing:readTokenFiledidLstatthenos.Open. On unix it now opens withO_NOFOLLOW|O_NONBLOCKand checksf.Stat().Mode().IsRegular()on the descriptor, so a FIFO or symlink swapped in after the check is rejected without blocking. Non-unix keeps Lstat+Open plus the descriptor check (best effort). TestTestEntitlementSwapRaceRejectedswaps a FIFO or symlink in via a nil-in-production seam; on the old code it fails (FIFO blocks the reader, symlink is accepted), on the new code it passes.D-0621 (fixed)
sdk/go/httpx: buffering a hand-built reader body now (a) errors when an explicitContentLength > 0differs from the buffered length, (b) sets the inferred length on the per-attempt clone, not the caller's request, (c) skips inference whenTraileris set so the request stays chunked and trailers go out. Three new tests fail on the old code and pass now. The optional "make buffering honour ctx" was not done; the stalled-body hang is pre-existing and was rated out of scope in the row.D-0134 (BLOCKED, no change) The duplicate spellings are deliberate deprecation aliases generated from the canon (
cmd/commands/canon_moves_gen.go,Since v1.5.0, RemovalAt v1.6.0), and the row routespromote-envto P7-DEPL-15. Retiring them is a release-timed removal / product decision, not a local fix.D-0072 (BLOCKED, no change) Renaming
sdk/ts-sdk(npm@nself/sdk, published) means a package rename and publish decision; the CI diff check againstplugins-proneeds a cross-repo checkout of a private repo, i.e. a token/secret and a CI decision.Commands run
go test -race -count=3 ./tools/perfbench/...ok (panicked before)cd sdk/go && go vet ./licensing/ ./httpx/;go test -race -count=1 ./licensing/... ./httpx/;go test -tags nself_testkeys ./licensing/...okcd sdk/go && go test -count=1 ./...and rootgo build ./...: no failuresGOOS=windows go vet ./licensing/ok