Problem
PR #323 moved async retries into a custom HTTPX transport:
httpx.AsyncClient(
headers={"User-Agent": _build_user_agent()},
transport=MlbAsyncRetryTransport(),
)
HTTPX only auto-loads environment proxies when transport is None. Passing a custom transport can therefore bypass HTTP_PROXY, HTTPS_PROXY, ALL_PROXY, and NO_PROXY for library-created async clients.
Before #323, the library-created client was effectively:
httpx.AsyncClient(
headers={"User-Agent": _build_user_agent()},
)
so normal environment proxy handling remained available.
Example
export HTTPS_PROXY=http://proxy.example.com:8080
from mlbstatsapi import AsyncMlb
async with AsyncMlb() as mlb:
team = await mlb.get_team(133)
Expected: the request follows HTTPX's normal environment proxy behavior.
Acceptance criteria
Problem
PR #323 moved async retries into a custom HTTPX transport:
HTTPX only auto-loads environment proxies when
transport is None. Passing a custom transport can therefore bypassHTTP_PROXY,HTTPS_PROXY,ALL_PROXY, andNO_PROXYfor library-created async clients.Before #323, the library-created client was effectively:
so normal environment proxy handling remained available.
Example
export HTTPS_PROXY=http://proxy.example.com:8080Expected: the request follows HTTPX's normal environment proxy behavior.
Acceptance criteria
AsyncMlborAsyncMlbDataAdapterconstructor signatures.