Add Python Hello Cities sample for Durable Functions#312
Open
hhunter-ms wants to merge 1 commit into
Open
Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
Adds a new Python “Hello Cities” Durable Functions sample that demonstrates common orchestration patterns against the Durable Task Scheduler (DTS) backend, aligning the Python samples with the existing “Hello Cities” quickstarts in other languages.
Changes:
- Added a Python v2 programming model Durable Functions app (
DFApp) implementing function chaining and fan-out/fan-in orchestrations. - Added DTS emulator-ready configuration (
host.jsonusingazureManagedprovider andlocal.settings.jsonwith local connection string). - Added sample documentation (
README.md), dependencies (requirements.txt), and a local.gitignore.
Reviewed changes
Copilot reviewed 6 out of 6 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
| samples/durable-functions/python/hello-cities/function_app.py | Implements the two orchestrations, one activity, and two HTTP starters using DFApp. |
| samples/durable-functions/python/hello-cities/host.json | Configures Durable extension to use DTS (azureManaged) with the emulator connection name. |
| samples/durable-functions/python/hello-cities/local.settings.json | Provides local emulator settings and required Functions runtime values. |
| samples/durable-functions/python/hello-cities/requirements.txt | Declares the Azure Functions + Durable Functions Python dependencies. |
| samples/durable-functions/python/hello-cities/README.md | Documents prerequisites and how to run/trigger both orchestrations locally. |
| samples/durable-functions/python/hello-cities/.gitignore | Ignores local virtualenv and Python cache artifacts for the sample directory. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Adds a Python Hello Cities quickstart sample under
samples/durable-functions/python/hello-cities/to match the existing Hello Cities samples in other languages (C#, Java, JavaScript, TypeScript).What's included
say_hellosequentially for Tokyo, Seattle, and Londonsay_helloin parallel for 5 citiesfunction_app.pyusingDFApp(Python v2 programming model)host.jsonconfigured withazureManagedstorage provider for Durable Task Schedulerlocal.settings.jsonwith emulator connection stringrequirements.txtwithazure-functionsandazure-functions-durableREADME.mdwith prerequisites and quick run instructionsTesting
Both orchestrations tested locally against the DTS emulator and returned successful results:
["Hello Tokyo!", "Hello Seattle!", "Hello London!"]["Hello Tokyo!", "Hello Seattle!", "Hello London!", "Hello Paris!", "Hello Berlin!"]