Skip to content

fix(v1-api): pass required config to DensePoseHead — green main CI#910

Merged
ruvnet merged 1 commit into
mainfrom
fix/v1-pose-service-densepose-config
Jun 2, 2026
Merged

fix(v1-api): pass required config to DensePoseHead — green main CI#910
ruvnet merged 1 commit into
mainfrom
fix/v1-pose-service-densepose-config

Conversation

@ruvnet
Copy link
Copy Markdown
Owner

@ruvnet ruvnet commented Jun 2, 2026

Problem

The Continuous Integration workflow (Performance Tests + API Documentation jobs) has been failing on main (every commit checked, #886→HEAD). Root cause is in the v1 Python API startup:

TypeError: DensePoseHead.__init__() missing 1 required positional argument: 'config'
  src.services.pose_service._initialize_models
uvicorn.error: Application startup failed. Exiting.

pose_service.py called DensePoseHead() with no args at two sites, but DensePoseHead.__init__ requires a config dict.

Fix

Pass a config: input_channels=256 (matches ModalityTranslationNetwork's output), num_body_parts=24 (DensePose standard), num_uv_coordinates=2. Both call sites fixed.

Verification

Locally: DensePoseHead(config) (423,211 params) and ModalityTranslationNetwork(config) both construct + eval() — the startup TypeError is cleared, so the API service initializes.

🤖 Generated with claude-flow

The "Continuous Integration" workflow (Performance Tests + API
Documentation jobs) has failed on every main commit since the API start
path was exercised: pose_service._initialize_models() called
`DensePoseHead()` with no args, but DensePoseHead.__init__ requires a
config dict → "TypeError: DensePoseHead.__init__() missing 1 required
positional argument: 'config'" → uvicorn "Application startup failed".

Pass a config: input_channels=256 (matches the modality translator's
output), num_body_parts=24 (DensePose standard), num_uv_coordinates=2.
Both call sites (with/without pose_model_path) fixed.

Verified locally: DensePoseHead(config) + ModalityTranslationNetwork(config)
both construct + eval, clearing the startup TypeError.
@ruvnet ruvnet merged commit 4d205a0 into main Jun 2, 2026
20 checks passed
sincalaway pushed a commit to sincalaway/RuView that referenced this pull request Jun 2, 2026
After the DensePoseHead startup fix (ruvnet#910), the v1 API starts, but the
Performance Tests load-hit the pose endpoints which error "requires real
CSI data" (no hardware in CI, mock_pose_data defaults False), and the
API-docs job imports the app the same way. Set MOCK_POSE_DATA=true on both
jobs so they exercise the mock path. Verified: the env var maps to
settings.mock_pose_data=True (pydantic, no env_prefix).

(Note: Performance Tests is continue-on-error so this is cleanup, not a
run-blocker; the run-level red on main has been transient Docker Hub pull
timeouts on Tests/docker-build, which are infra flakes that pass on re-run.)
pull Bot pushed a commit to jw5812018/RuView that referenced this pull request Jun 2, 2026
Two more latent v1-API CI bugs surfaced once ruvnet#910/ruvnet#911 let the jobs reach
their later steps:

- API Documentation: openapi generation now succeeds (psutil fix), but the
  gh-pages deploy failed with HTTP 403 — the job had no `permissions` block
  and GITHUB_TOKEN is read-only by default. Add `permissions: contents:
  write`, and make the deploy `continue-on-error` (the openapi generation is
  the real validation; Pages may be disabled).
- Performance Tests: ran `locust -f tests/performance/locustfile.py`, but
  there is no locustfile — the suite is pytest (test_api_throughput.py,
  test_frame_budget.py, test_inference_speed.py). Run pytest instead, with
  working-directory: archive/v1 and MOCK_POSE_DATA=true.

ci.yml validated as well-formed YAML.
ruvnet added a commit that referenced this pull request Jun 2, 2026
…#914)

The Performance Tests job collected 26 items then aborted with
`ModuleNotFoundError: No module named 'src'` on test_frame_budget.py,
which does `from src.core.csi_processor import CSIProcessor`. The bare
`pytest` console script does not put the cwd (archive/v1) on sys.path;
`python -m pytest` does. pytest aborts the whole session on a collection
error, so this one import masked the entire (otherwise mock-based,
self-contained) perf suite.

Verified locally: bare-script path reproduces the exact error; `-m`
resolves it and test_frame_budget.py passes 3/3. The other two files
(test_api_throughput.py mock server, test_inference_speed.py MockPoseModel
+psutil) are fully self-contained — no test hits the running server.

Closes the last red job in the v1-API CI chain (#910/#911/#913).
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant