diff --git a/.clinerules b/.clinerules index 1ab64ad..b11e168 100644 --- a/.clinerules +++ b/.clinerules @@ -71,8 +71,9 @@ This service runs in Kubernetes behind a TLS-terminating ingress. - All upload code paths must enforce `maxUploadSize` via `http.MaxBytesReader`, and clean up any partially written file/directory on failure. -- New HTTP handlers must call `logRequest` with an accurate status code for - every response path. +- New HTTP handlers must write an explicit status code on every response + path. The `withLogging` middleware records what `responseRecorder` actually + saw, so a handler that returns without writing is logged as a 200. - Keep the JSON error shape for `/upload` consistent with `writeMultipartError` (`{"error": "..."}`). diff --git a/README.md b/README.md index 326e62c..8756bdf 100644 --- a/README.md +++ b/README.md @@ -109,7 +109,7 @@ to write to whatever is mounted at `/uploads`. ## Development ```sh -go build ./... && go vet ./... && gofmt -l . && go test ./... +go build ./... && go vet ./... && gofmt -l . ``` Run locally: