Updated routines-build/routines/local-mac/wordpress_draft_qa/ with a dedicated featured_media_metadata_audit.py read-only audit. The workflow now explicitly flags any WordPress page or post with visible hero/body imagery in content while featured_media / _thumbnail_id remains 0, outputs exact IDs and slugs, and explains that custom heroes do not satisfy featured-image metadata.
Wired the audit into run.py after the inlink workbook steps. Updated the routine CLAUDE.md output and QA sections so future runs expect the new report and the 2026-05-18 six-page regression check.
Added test_featured_media_metadata_audit.py with focused coverage for custom hero detection, zero featured-media flagging, and the six repaired IDs from 2026-05-18.
python3 -m unittest routines-build/routines/local-mac/wordpress_draft_qa/test_featured_media_metadata_audit.py: 3 tests passed.python3 -m py_compile routines-build/routines/local-mac/wordpress_draft_qa/run.py routines-build/routines/local-mac/wordpress_draft_qa/featured_media_metadata_audit.py routines-build/routines/local-mac/wordpress_draft_qa/test_featured_media_metadata_audit.py: passed.python3 routines-build/routines/local-mac/wordpress_draft_qa/featured_media_metadata_audit.py: generated report under outputs/wordpress-draft-readiness-2026-05-19/.The report checked 607 WordPress posts/pages with status publish, draft, or pending using read-only DB access plus wp post url verification.
Current visible-image plus featured_media=0 findings:
66759, slug resources, type page, status publish, evidence body image present.66834, slug questions-to-ask-personal-injury-lawyer, type post, status publish, evidence body image present.The report explains: custom hero/body imagery does not satisfy featured-image metadata. WordPress, social previews, schema consumers, and REST clients read featured_media / _thumbnail_id separately.
Six-page 2026-05-18 regression check:
37, slug thank-you, featured_media 43769.66759, slug resources, featured_media 0.63417, slug motorcycle-accident-lawyer, no current page/post match found in the current scoped query.66783, slug kentucky, featured_media 0.63356, slug abogado-lexington, featured_media 44739.