Skip to content

Param-a-lama-ding-dong

Compare
Choose a tag to compare
@cicdw cicdw released this 08 Feb 02:12
· 50 commits to main since this release
c8986ed

What's Changed

This release contains a lot! In particular, users can now specify parameters on a per-schedule basis. This is useful for flows with multiple schedules, for example:

from prefect import flow
from prefect.schedules import Cron

@flow
def send_email(to: str, message: str = "Stop goofing off!"):
    print(f"Sending email to {to} with message: {message}")

send_email.serve(
  name="my-flow",
  schedules=[
    Cron(
      "0 8 * * *",
      parameters={"to": "jim.halpert@dundermifflin.com"}
    ),
    Cron(
      "5 8 * * *",
      parameters={
        "to": "dwight.schrute@dundermifflin.com",
        "message": "Stop goofing off! You're assistant _to_ the regional manager!"
      }
    )
  ]
)

See the documentation for more details.

Enhancements ➕➕

  • Update deployments PATCH endpoint to make more targeted updates with slugs by @desertaxle in #17027
  • Update deployment SDK to use slugs by @desertaxle in #17043
  • Update the SDK to use PATCH /deployments/{id} endpoint for existing deployments by @desertaxle in #17050
  • Add database migration that adds parameter fields to deployment schedules by @cicdw in #16947
  • Add non-public implementation of parametrized schedules by @cicdw in #16951
  • Allow definition of per-schedule parameter overrides via prefect.yaml by @desertaxle in #16963
  • Allow definition of per-schedule parameters via .serve and .deploy by @desertaxle in #16965
  • Use retry logic of underlying prefect client properly by @cicdw in #16992
  • Remove some log noise in pause and abort handling by @cicdw in #17014
  • Allow for updating a deployment's parameter openapi schema by @cicdw in #17016
  • Allow for pull step updates on deployments by @cicdw in #17045

Bug Fixes 🐞

Integrations & Dependencies 🤝

Development & Tidiness 🧹

Documentation 📓

New Contributors

Full Changelog: 3.1.15...3.2.0