@buherator Ooo that silly XSSI prefix! Their frontend just skips it, I don't see a better way for httpx:
async call(e, s, i, r)
{
// [...]
const a = `${!0 === this.insecure ? "http:" : "https:"}//${this.host}/prpc/${e}/${s}`,
l = this._requestOptions(i, r),
c = await this.fetchImpl(a, l);
// [...]
const u = ")]}'",
h = await c.text();
if (d !== t.OK)
throw new n(d, h);
if (!h.startsWith(u))
throw new o(c.status, "Response body does not start with XSSI prefix: )]}'");
return JSON.parse(h.substr(u.length))
}
@buherator Same in other internal code like https://chromium.googlesource.com/infra/infra/+/0a1e0b989cc9133aa62f8448382b0e9d022d41a6/appengine/monorail/sitewide/usercommits.py#102 so I don't think there's a header you can set to avoid it.