<@ULVA73B9P> please provide a python sample of usi...
# ask-marvin
b
@Marvin please provide a python sample of using
parameters
with
DeploymentRunner
m
As it seems there's no direct excerpt related to using
parameters
with
DeploymentRunner
, I would suggest checking out the documentation and source code for the
DeploymentRunner
class in Prefect 2.x for the most accurate and up-to-date examples. Here's a conceptual example of how you might use
parameters
with
DeploymentRunner
, taking note that this is a generic example and might not reflect the latest changes in Prefect 2.x:
Copy code
python
from prefect.deployments import Deployment
from prefect.engine.runner import DeploymentRunner

# Create your deployment using the required details
deployment = Deployment.build_from_flow(
    flow=my_flow,
    name="example-deployment",
    parameters={"example_param": "value"},  # Here's how you define parameters for the flow
    # ... more settings for the deployment
)

# Create a DeploymentRunner
runner = DeploymentRunner(deployment=deployment)

# Run the deployment with parameters, if needed to override
run_info = runner.run(parameters={"example_param": "new_value"})
Please check the Prefect documentation or contact Prefect support for assistance on using
DeploymentRunner
with
parameters
. If it's a common use case, there should likely be GitHub issues, examples in the documentation, or threads in the Prefect community discussing it.