Use environment defaults for client async config#632
Conversation
Signed-off-by: Sheldon <neooosky@gmail.com>
|
|
Performance
✓ No regressions detected |
santoshkumarradha
left a comment
There was a problem hiding this comment.
Thanks for the fix. This brings AgentFieldClient in line with Agent by picking up async defaults from the environment, and the regression tests cover both the env-backed default path and the explicit override path.
I also approved the first-time contributor workflow runs so CI is now moving.
📊 Coverage gateThresholds from
✅ Gate passedNo surface regressed past the allowed threshold and the aggregate stayed above the floor. |
📐 Patch coverage gateThreshold: 80% on lines this PR touches vs
✅ Patch gate passedEvery surface whose lines were touched by this PR has patch coverage at or above the threshold. |
|
Thanks for updating this branch. The code and required test checks look good on my side. The remaining blocker is still the CLA check. Once that clears, this should be in good shape to merge. |
…t async config (#714) AgentFieldClient constructed its default async_config with AsyncConfig(), ignoring AGENTFIELD_ASYNC_* environment overrides that Agent already honors. Initialize the default from AsyncConfig.from_environment() so client-level async behavior can be tuned via env vars, while preserving any explicitly passed async_config unchanged. Adds regression coverage for both paths. Fixes #621. Supersedes #632 (original change by liuzemei / neooosky); re-authored here so it can land without the outstanding CLA signature. Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Fixes #621
Summary
AgentFieldClientwithAsyncConfig.from_environment()when no explicit async config is providedasync_configinstances unchangedTests
uv run --extra dev pytest tests/test_async_config.py -quv run --extra dev pytest tests/test_client_unit.py tests/test_client_auth.py tests/test_async_config.py -q