fix: send stable user-agent from the Python SDK#4
Conversation
Greptile SummaryThis PR fixes a Cloudflare 1010 error that was blocking Python SDK calls from fresh controllers by centralizing version metadata into a new Confidence Score: 5/5Safe to merge — fixes a concrete production outage with a small, well-tested, backwards-compatible change. The change is minimal and surgical: one new module, two one-line header additions, and two new tests that directly verify the fix. No public API surface changes, version is consistent, and the root cause (missing User-Agent blocked by Cloudflare 1010) is directly addressed. End-to-end validation was reported as 14/14 passing. No files require special attention. Important Files Changed
Reviews (1): Last reviewed commit: "fix: send stable user agent from python ..." | Re-trigger Greptile |
Summary
User-Agentfrom both the sync urllib client and async httpx clientWhy
Hosted SDK calls from a fresh controller were getting blocked by Cloudflare with error 1010 because the stdlib urllib client was not sending an explicit user agent.
Validation
cd /Users/openclaw/projects/delega-python && PYTHONPATH=src python3 -m unittest/root/work/delega-tests/sdk/sdk-hosted.sh-> 14/14 pass