Summary
The weekly dependency update PR #478 bumped the latest AgentScope matrix pin from agentscope==1.0.20 to agentscope==2.0.0. The current Braintrust AgentScope integration tests no longer run against 2.0.0 because several AgentScope APIs used by our integration tests and auto-instrumentation smoke script were removed or moved.
For PR #478, we restored the existing agentscope latest cassettes rather than committing a broken or partial re-record. This issue tracks adding explicit support for AgentScope 2.0.
Reproduction
On PR #478 / branch deps/weekly-update-2026-06-01, run:
cd py
nox -s "test_agentscope(latest)" -- --vcr-record=all
Observed with agentscope==2.0.0:
ImportError: cannot import name 'ReActAgent' from 'agentscope.agent'
ModuleNotFoundError: No module named 'agentscope.pipeline'
ImportError: cannot import name 'execute_python_code' from 'agentscope.tool'
ImportError: cannot import name 'AgentBase' from 'agentscope.agent'
Affected test/script locations:
py/src/braintrust/integrations/agentscope/test_agentscope.py
_make_agent() imports ReActAgent from agentscope.agent
- sequential pipeline test imports
sequential_pipeline from agentscope.pipeline
- tool-use test imports
Toolkit / execute_python_code from agentscope.tool
py/src/braintrust/integrations/auto_test_scripts/test_auto_agentscope.py
- imports
AgentBase and ReActAgent from agentscope.agent
Investigation plan
-
Review the AgentScope 2.0 migration guide / changelog and identify replacements for:
agentscope.agent.AgentBase
agentscope.agent.ReActAgent
agentscope.pipeline.sequential_pipeline
agentscope.tool.execute_python_code
-
Inspect AgentScope 2.0 package structure locally, e.g.:
cd py
nox -s "test_agentscope(latest)" -- --disable-vcr -k non_vcr_or_import_probe
# or use the nox-created env / a scratch env to inspect:
python - <<'PY'
import agentscope, pkgutil
print(agentscope.__version__)
print([m.name for m in pkgutil.iter_modules(agentscope.__path__)])
PY
-
Decide whether the Braintrust integration needs version-gated code paths:
- keep AgentScope 1.x behavior working for the existing
1.0.0 matrix entry
- add AgentScope 2.x wrappers / instrumentation paths where APIs have changed
-
Update tests to cover both versions in the nox matrix:
- keep existing 1.x cassettes
- re-record
py/src/braintrust/integrations/agentscope/cassettes/latest/ once 2.0 support is implemented
-
Verify:
cd py
nox -s "test_agentscope(latest)"
nox -s "test_agentscope(1.0.0)"
Notes
This is a major dependency bump (1.0.20 -> 2.0.0), so API breakage is expected. The immediate failure is at import time before cassette playback/recording can meaningfully validate provider response shape.
Summary
The weekly dependency update PR #478 bumped the latest AgentScope matrix pin from
agentscope==1.0.20toagentscope==2.0.0. The current Braintrust AgentScope integration tests no longer run against 2.0.0 because several AgentScope APIs used by our integration tests and auto-instrumentation smoke script were removed or moved.For PR #478, we restored the existing
agentscopelatest cassettes rather than committing a broken or partial re-record. This issue tracks adding explicit support for AgentScope 2.0.Reproduction
On PR #478 / branch
deps/weekly-update-2026-06-01, run:Observed with
agentscope==2.0.0:Affected test/script locations:
py/src/braintrust/integrations/agentscope/test_agentscope.py_make_agent()importsReActAgentfromagentscope.agentsequential_pipelinefromagentscope.pipelineToolkit/execute_python_codefromagentscope.toolpy/src/braintrust/integrations/auto_test_scripts/test_auto_agentscope.pyAgentBaseandReActAgentfromagentscope.agentInvestigation plan
Review the AgentScope 2.0 migration guide / changelog and identify replacements for:
agentscope.agent.AgentBaseagentscope.agent.ReActAgentagentscope.pipeline.sequential_pipelineagentscope.tool.execute_python_codeInspect AgentScope 2.0 package structure locally, e.g.:
Decide whether the Braintrust integration needs version-gated code paths:
1.0.0matrix entryUpdate tests to cover both versions in the nox matrix:
py/src/braintrust/integrations/agentscope/cassettes/latest/once 2.0 support is implementedVerify:
Notes
This is a major dependency bump (
1.0.20 -> 2.0.0), so API breakage is expected. The immediate failure is at import time before cassette playback/recording can meaningfully validate provider response shape.