Skip to content

Commit cc77ba4

Browse files
committed
update docstring examples to use builder.build() instead of builder.push()
1 parent 49ff2c2 commit cc77ba4

4 files changed

Lines changed: 8 additions & 4 deletions

File tree

src/runloop_api_client/sdk/async_.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -782,7 +782,8 @@ class AsyncScenarioOps:
782782
... .with_problem_statement("Fix the bug")
783783
... .add_test_command_scorer("tests", test_command="pytest")
784784
... )
785-
>>> scenario = await builder.push()
785+
>>> params = builder.build()
786+
>>> scenario = await runloop.scenario.create(**params) # equivalent to builder.push()
786787
"""
787788

788789
def __init__(self, client: AsyncRunloop) -> None:

src/runloop_api_client/sdk/async_scenario_builder.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,8 @@ class AsyncScenarioBuilder:
3838
... .with_problem_statement("Fix the bug in main.py")
3939
... .add_test_command_scorer("tests", test_command="pytest")
4040
... )
41-
>>> scenario = await builder.push()
41+
>>> params = builder.build()
42+
>>> scenario = await runloop.scenario.create(**params) # equivalent to builder.push()
4243
"""
4344

4445
def __init__(self, name: str, client: AsyncRunloop) -> None:

src/runloop_api_client/sdk/scenario_builder.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,8 @@ class ScenarioBuilder:
3838
... .with_problem_statement("Fix the bug in main.py")
3939
... .add_test_command_scorer("tests", test_command="pytest")
4040
... )
41-
>>> scenario = builder.push()
41+
>>> params = builder.build()
42+
>>> scenario = runloop.scenario.create(**params) # equivalent to builder.push()
4243
"""
4344

4445
def __init__(self, name: str, client: Runloop) -> None:

src/runloop_api_client/sdk/sync.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -803,7 +803,8 @@ class ScenarioOps:
803803
... .with_problem_statement("Fix the bug")
804804
... .add_test_command_scorer("tests", test_command="pytest")
805805
... )
806-
>>> scenario = builder.push()
806+
>>> params = builder.build()
807+
>>> scenario = runloop.scenario.create(**params) # equivalent to builder.push()
807808
"""
808809

809810
def __init__(self, client: Runloop) -> None:

0 commit comments

Comments
 (0)