fix(docs): point removed-doc services at live WSDL (closes #463)#464
Conversation
Yandex removed the human-readable doc pages for DynamicTextAdTargets, DynamicFeedAdTargets, SmartAdTargets and VCards in September 2025 — the /ru/ and /en/ pages now 404 and the services are gone from the docs navigation (confirmed via browser; the services are absent from the "Основные объекты" menu). The services themselves stay live. - RESOURCE_MAPPING_V5: repoint the 4 `docs` URLs at their WSDL endpoints (api.direct.yandex.com/v5/<service>?wsdl), the only authoritative source still served, with a comment explaining the Sep-2025 removal. - check_all_docs_urls.py: validate ?wsdl/.wsdl URLs as real WSDL (XML + wsdl:definitions) instead of the 30 KB HTML-page threshold, so preflight passes on the smaller XML payloads. The `docs` field is preflight-only (never used at runtime — requests build from `resource`), so this has no functional impact. Full suite green (2035 passed); `check_all_docs_urls.py` reports all URLs canonical. Closes #463 Co-Authored-By: Claude Opus 4.8 (1M context) <[email protected]>
|
@claude review. Focus on critical issues: bugs, security vulnerabilities, logical errors, data loss risks, performance problems. Do NOT nitpick style, naming conventions, minor formatting, or subjective preferences — only flag issues that could break functionality or cause real harm in production. |
|
Claude finished @axisrow's task in 2m 49s —— View job Review: PR #464 — repoint removed-doc services at live WSDL
The core fix is correct: the 4 doc pages are genuinely 404, the WSDL endpoints are the only authoritative source still served, and they live inside the registry so the "no URL literals outside the registry" invariant is respected. The WSDL-validation branch in Two issues, both low severity (neither blocks CI or the documented preflight), plus one note. 1. The PR's "never read at runtime / zero functional impact" claim is incorrect
docs_url = get_docs_url(command.name or "") # cli.py:316
if docs_url:
docs_line = f"\b\nDocumentation: {docs_url}"So This is not a functional break — the old doc URLs are dead 404s, so a live WSDL link is strictly better than a broken one — but the stated rationale is wrong, and there is a real user-facing help-text change. Worth correcting the PR description so reviewers/release notes reflect that 2.
|
After #463 repointed 4 services' `docs` at WSDL endpoints, audit_v5's _v5_per_method_url derived malformed URLs (`…?wsdl/get`) for them, emitting false docs_unreachable findings for every method. Now a WSDL base (`?wsdl`/`.wsdl`) is audited as one __group__ target instead of deriving per-method URLs. Regression test added. Addresses review note on PR #464. Co-Authored-By: Claude Opus 4.8 (1M context) <[email protected]>
|
@claude review. Focus on critical issues: bugs, security vulnerabilities, logical errors, data loss risks, performance problems. Do NOT nitpick style, naming conventions, minor formatting, or subjective preferences — only flag issues that could break functionality or cause real harm in production. |
|
Claude finished @axisrow's task in 1m 49s —— View job Review: PR #464 — repoint removed-doc services at live WSDL
This revision resolves both findings from the prior review: the PR body now correctly states the I confirmed the only runtime consumer of Verified specifics:
One non-blocking observation (low severity)
if url.rstrip("/").endswith("?wsdl") or url.endswith(".wsdl"):
if ("wsdl:definitions" in lower or "<definitions" in lower) and len(body) >= 3072:
return ("OK", f"GET {resp.status_code}, valid WSDL, {len(body)} bytes")
return ("SMALL", f"WSDL markers/size insufficient ({len(body)} bytes)")Verdict: ✅ Correctly fixes #463 and addresses the prior review. Safe to merge. The size-floor note is optional hardening, not a blocker. |
WSDL preflight validation passed on marker presence alone; a truncated body containing <definitions would have reported OK. Add the same 3 KB floor wsdl_coverage.fetch_wsdl uses (CLAUDE.md freshness guard) so a partial WSDL reports SMALL. Real Yandex WSDLs are 14-21 KB. Addresses non-blocking review note on PR #464. Co-Authored-By: Claude Opus 4.8 (1M context) <[email protected]>
|
@claude review. Focus on critical issues: bugs, security vulnerabilities, logical errors, data loss risks, performance problems. Do NOT nitpick style, naming conventions, minor formatting, or subjective preferences — only flag issues that could break functionality or cause real harm in production. |
|
Claude finished @axisrow's task in 1m 19s —— View job Review: PR #464 — repoint removed-doc services at live WSDL
This is the third pass. Both prior findings (the misleading "zero functional impact" claim and the malformed I re-verified the points that could plausibly still break:
Non-blocking observations (no action required)
Verdict: ✅ Correctly fixes #463 and incorporates all prior review feedback. No blocking issues. Recommend merge. Note: I could not run the test suite locally (sandbox blocked |
…#547) The tapi-yandex-direct 2026.5.29 vendor update (1ee8c2a) silently reverted the #464 fix: it restored the dead `…/dev/direct/doc/ru/<service>` HTML doc URLs for dynamicads, dynamicfeedadtargets, smartadtargets and vcards. Yandex removed those pages in September 2025 — they now 404, so preflight (check_all_docs_urls.py) failed. The vendor sync is rm -rf + cp -R from the fork, which overwrote the manual edit. - resource_mapping.py: restore the 4 `docs` URLs to their live WSDL endpoints (api.direct.yandex.com/v5/<service>?wsdl), matching b15498e exactly. - test_audit_wire_shape.py: add an offline regression guard (test_removed_doc_services_pin_wsdl_url) that fails in CI before the network preflight if any of the 4 reverts to an HTML doc page. - CHANGELOG: document the regression and re-fix. The fork itself is fixed in a separate PR so the next vendor update no longer re-introduces the dead URLs. Preflight now reports all URLs canonical; full suite green (2181 passed). Co-authored-by: axisrow <[email protected]> Co-authored-by: Claude Opus 4.8 (1M context) <[email protected]>
Summary
Fixes the 4 stale
RESOURCE_MAPPING_V5docs URLs that hard-failed the release preflight (dynamicads,dynamicfeedadtargets,smartadtargets,vcards).Root cause (confirmed via browser): Yandex removed the human-readable doc pages for these services around September 2025. Both the
/ru/and/en/pages now 404, and the services are gone from the docs navigation ("Основные объекты" menu no longer lists them;ref-v5/<svc>/<svc>.htmlredirects to a 404/default). This is a deletion, not a slug move — which is why no canonical replacement page exists.The services themselves remain live — their WSDL endpoints return HTTP 200:
Change
RESOURCE_MAPPING_V5: repoint the 4docsURLs at their WSDL endpoints — the only authoritative source Yandex still serves for them — with a comment explaining the Sep-2025 removal.check_all_docs_urls.py: validate?wsdl/.wsdlURLs as real WSDL (XML +wsdl:definitions) rather than the 30 KB HTML-page threshold (WSDL payloads are 14–21 KB).audit_wire_shape.py: treat a WSDLdocsbase as a single__group__target instead of deriving per-method URLs (which would produce malformed…?wsdl/get). Regression test added.Functional impact (corrected)
The
docsfield is read at runtime:_register_command(cli.py:316) callsget_docs_url(...)and appendsDocumentation: <url>to each group's--helpepilog. So after this change,direct dynamicads|dynamicfeedadtargets|smartadtargets|vcards --helpprint a WSDL link instead of the old (now-dead 404) doc URL. This is a strict improvement — a live WSDL link beats a broken page — but it is a real user-facing help-text change, not "zero impact" as an earlier draft of this description claimed.Why WSDL and not a doc page
Investigated thoroughly: the doc pages are gone on every language/host; the WSDL is the only live, authoritative description still served. WSDL does not contain links to doc pages, so there is nothing else to point at.
Note
Preflight now depends on
api.direct.yandex.com/v5/<svc>?wsdlbeing publicly fetchable without a token (holds today; flagged for awareness — if Yandex ever gates WSDL behind auth, preflight would need adjusting).Testing
python scripts/check_all_docs_urls.py→ all URLs canonical (the 4 now reportvalid WSDL).ruff check .clean.Closes #463
🤖 Generated with Claude Code