{"record":{"id":"72bc47078b0622da","repo":"zylon-ai/private-gpt","slug":"anthropic-dependency-not-found-in-pyproject-file","errorCode":null,"errorMessage":"anthropic dependency not found in {PYPROJECT_FILE}","messagePattern":"anthropic dependency not found in (.+?)","errorType":"exception","errorClass":"RuntimeError","httpStatus":null,"severity":"error","filePath":"scripts/update_claude_specs.py","lineNumber":71,"sourceCode":"        source,\n        flags=re.MULTILINE,\n    )\n    if count == 0:\n        raise RuntimeError(\n            f\"OPENAPI_SPEC_URL assignment not found in {OPENAPI_TEST_FILE}\"\n        )\n    OPENAPI_TEST_FILE.write_text(updated, encoding=\"utf-8\")\n\n\ndef update_anthropic_version(new_version: str) -> None:\n    source = PYPROJECT_FILE.read_text(encoding=\"utf-8\")\n    updated, count = re.subn(\n        r'\"anthropic>=[\\d.]+\"',\n        f'\"anthropic>={new_version}\"',\n        source,\n    )\n    if count == 0:\n        raise RuntimeError(f\"anthropic dependency not found in {PYPROJECT_FILE}\")\n    PYPROJECT_FILE.write_text(updated, encoding=\"utf-8\")\n\n\ndef sync_lock_file() -> None:\n    print(\"\\nRunning uv lock ...\")\n    subprocess.run([\"uv\", \"lock\"], check=True, cwd=ROOT)\n\n\ndef main() -> None:\n    changed = False\n\n    # --- OpenAPI spec URL ---\n    print(f\"Fetching OpenAPI spec URL from {ANTHROPIC_STATS_URL} ...\")\n    latest_url = fetch_openapi_spec_url()\n    pinned_url = current_openapi_spec_url()\n\n    if pinned_url == latest_url:\n        print(\"  OpenAPI spec URL already up to date.\")","sourceCodeStart":53,"sourceCodeEnd":89,"githubUrl":"https://github.com/zylon-ai/private-gpt/blob/4a030776a31a901ad80b1bf4d7faa2c1a367efbb/scripts/update_claude_specs.py#L53-L89","documentation":"Error \"anthropic dependency not found in {PYPROJECT_FILE}\" thrown in zylon-ai/private-gpt.","triggerScenarios":"Raised by update_claude_specs.py when the anthropic dependency entry is not found in pyproject.toml.","commonSituations":"The anthropic dependency was removed, renamed, or moved to another group in pyproject.toml; restore it or update the script to match the new layout.","solutions":["Add the anthropic dependency to pyproject.toml before running the update script.","Check that PYPROJECT_FILE points to the correct pyproject.toml path.","Verify the dependency is listed under the expected dependency group/section the script searches."],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"4a030776a31a901ad80b1bf4d7faa2c1a367efbb","analyzedAt":"2026-08-15T03:51:26.951Z","schemaVersion":2},"datasetVersion":"2026-08-15T22:17:37.221Z"}