Repository navigation
docs(connectors): update_resource_acl Python samples use keyword fields, not request= (OSS-118) - #407
adityamishra-hydradb wants to merge 4 commits into
Conversation
…ate_resource_acl (OSS-118) hydradb-sdk 2.1.8 removed the request dict from ConnectorsClient.update_resource_acl, so the Python samples raised TypeError. Use the keyword fields, drop the stale request note in sdks.mdx, raise the Python install floor and the test pin to 2.1.8, and give the test fake a typed response for the resource PATCH. Co-Authored-By: Claude Opus 5.5 <[email protected]> Signed-off-by: adityamishra-hydradb <[email protected]>
|
@hydra-mira-review review |
|
Preview deployment for your docs. Learn more about Mintlify Previews.
💡 Tip: Enable Automations to automatically generate PRs for you. |
|
/devin review |
Mira score 5/5 · 🟢 Good to merge
Python users get connector update examples aligned with SDK version How this PR works · 3 changes, 3 low riskPython connector examples fail before sending a request with the current SDK. They pass a 1. Require Python SDK 2.1.8 for the documented examples · 🟢 low risk ·
|
✅ Mintlify HygieneNo issues found. |
2.1.8 parses every response into a model with required fields, so the empty canned bodies for discover, configure, connector update, provider list, metadata schema and database status failed to parse. Fill in the required fields (all declared in the checked-in spec). Co-Authored-By: Claude Opus 5.5 <[email protected]> Signed-off-by: adityamishra-hydradb <[email protected]>
|
@hydra-mira-review review |
|
/devin review |
…-sdk 2.1.8 requires Co-Authored-By: Claude Opus 5.5 <[email protected]> Signed-off-by: adityamishra-hydradb <[email protected]>
|
@hydra-mira-review review |
|
/devin review |
Co-Authored-By: Claude Opus 5.5 <[email protected]> Signed-off-by: adityamishra-hydradb <[email protected]>
|
@hydra-mira-review review |
|
/devin review |
For humans
The Python samples for
client.connectors.update_resource_aclpassedrequest={...}.hydradb-sdk2.1.8 (the latest) has norequestargument, so every sample raised:This PR changes the samples to the keyword fields that 2.1.8 takes:
acl=[...]andcustom_instructions="...".essentials/v2/connectors.mdx: 3 calls (set an instruction, clear it, restrict a channel).api-reference/v2/endpoint/update-connector-resource.mdx: the request example, plus one note: 2.1.7 and earlier take onerequestdict.api-reference/v2/sdks.mdx: remove the stale "a connector resource update'srequest" note. The Python install line now asks for>=2.1.8.snippets/cookbook-setup.mdx: same install floor.scripts/requirements-test.txt: the examples test now runs against 2.1.8, the SDK users get today. With 2.1.7 the test passed the broken samples.scripts/test_docs_examples.py: the fake API returns a typed body forPATCH /connectors/{id}/resources/{resource_id}. 2.1.8 parses that response into a model, and an empty{}fails the parse.A grep over every non-archive page finds no other
request=.Overlap: none with open PRs. PR 400 (spec sync) and PR 372 touch other lines of the same files.
For agents
update_resource_acl(self, id, resource_id, *, request: Dict[str, Any], request_options=None). 2.1.8:update_resource_acl(self, id, resource_id, *, acl=OMIT, custom_instructions=OMIT, request_options=None).validatejob onmainis red before this PR (app_knowledge examples, staleopenapi.json). PR 400 fixes that. The pin bump makes the 2.1.8 drift visible in the same job: 4 cookbooks that sendapp_knowledgenow fail too, because 2.1.8 removed that argument (see Proof, section 3).Proof
A = base
main@484c1ce/ B = this PR @2567536Audit re-run on 2026-12-04 (03:00 to 03:20 UTC) on the current head. Node 24.11.0 (the
.node-versionpin), Python 3.12, clean venvs with thescripts/requirements-test.txtpackages. Raw outputs:~/hydradb/dogfood/proof/mintlify-docs-407/.1. A/B on the real repro: the changed samples on prod
Command:
python -I scripts/run_samples.py <A|B>(each sample as written on the page;connector_idis a UUID that does not exist, because the test org has no connector). File:samples-prod.txt. The script also records the request body that went on the wire.hydradb-sdk2.1.8 (latest on PyPI)connectors.mdxL421, set an instructionTypeError: … unexpected keyword argument 'request', no request sent404 connector not found(ridd8cbf0d5-e7e2-4c0d-9783-dcad144650ad)connectors.mdxL428, clear the instructionTypeError(same)404(ridb7cf808d-e3ff-44f5-a553-a519c1a3dce7)connectors.mdxL580, restrict a channelTypeError(same)404(ridd8fde980-f3ac-4487-9b60-d2601eabd1c8)update-connector-resource.mdxL12TypeError(same)404(rid5146ac02-f633-4ef7-b3d9-42edb2b675da)The 200 path is not run on prod (no connector in the test org). The body that B sends is byte-for-byte the body that the A text sends with SDK 2.1.7, for example
{"acl":["[email protected]"]}and{"custom_instructions":""}. The docs test fake also checks the body against the spec (section 2).2. Regression: the CI
validatestepsCommand:
docs-ci.sh <venv>runs the CI steps in order:verify_v2_public_contract.py,test_v2_schema_types,test_docs_consistency.py,unittest discover -s scripts -p 'test_*.py',verify_agents_endpoints.py,generate_llms_index.py --check,pnpm mintlify validate,pnpm mintlify broken-links. Filesci-A-484c1ce-sdk2.1.7.txt,ci-A-484c1ce-sdk2.1.8.txt,ci-B-2567536-sdk2.1.8.txt.unittest discover -s scripts(43 tests)request=blocks + the endpoint exampleTypeError)verify_agents_endpoints.py,generate_llms_index.py --checkvalidateis red onmaintoo (CI run on484c1ce, jobvalidate: failure). The 12 failures on A areapp_knowledgesamples and the staleopenapi.json(PR 400). B keeps those 12 (11 subtests plus the summary subtest) and adds 4 cookbooks (chief-of-staff,competitive-intelligence,glean,personal-assistant):TypeError: unexpected keyword argument 'app_knowledge'. That is the 2.1.8 pin making a real break visible. Those cookbooks also fail for users on the latest SDK today. This PR does not change them.3. Smoke: build and links
pnpm mintlify validatepnpm mintlify broken-linksrequest=in non-archive.mdxhygiene, Mintlify link-rot, deployment25675364. Stress
N/A: a docs change. Nothing touches load, limits or batching.
5. Edge cases
TypeErroron 2.1.8{"custom_instructions":""}(404 as expected)TypeError(…custom_instructions/acl). The page now says 2.1.8 or later, and the install lines say>=2.1.8🤖 Generated with Claude Code