Romain Lefebvre
11/14/2025, 4:06 PMMarvin
11/14/2025, 4:06 PMMarvin
11/14/2025, 4:10 PMprefect deploy or flow.from_source(...).deploy(name=...) with the same flow and deployment name will upsert the deployment—i.e., update it and create a new deployment version rather than making a duplicate.
- Versioning: Each update creates a new version you can view (and roll back to) in the UI.
- Schedules: On upsert, Prefect clears any future scheduled runs for that deployment and re-creates them based on the new config.
- Parameter (inputs) changes: The deployment’s parameter schema is updated. If enforce_parameter_schema is true (default), runs that don’t match the new schema will fail validation. Update default parameters in the deployment if needed.
If you actually want a second deployment to coexist, just give it a different deployment name.
Refs:
- Deployments overview: Concepts: Deployments
- Versioning behavior: How-to: Deployment versioning
- API upsert semantics: Create deployment API (upsert behavior)
Quick follow-up: when you say “change the inputs,” are you changing the flow function’s parameter list/annotations, or just the default parameters saved on the deployment? This affects whether you’ll want to adjust the deployment’s saved parameters too.