-
Notifications
You must be signed in to change notification settings - Fork 139
refactor: mv durabletask-python into sdk #963
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
sicoyle
wants to merge
22
commits into
dapr:main
Choose a base branch
from
sicoyle:refactor/mv-dt-here
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
Show all changes
22 commits
Select commit
Hold shift + click to select a range
fd0ac06
refactor: mv durabletask-python into sdk
sicoyle ca44c94
fix: address copilot feedback
sicoyle 6c3f4c7
fix: address more copilot feedback
sicoyle 3ddb0e8
fix: grab latest from alberts dt pr
sicoyle c37697d
style: uv run ruff format
sicoyle f861543
Merge branch 'main' into refactor/mv-dt-here
sicoyle c4472ca
fix: update for build and give dt same version setup as other pkgs
sicoyle a9bec3f
fix: updates for build
sicoyle 7dcf7c4
fix: update for some build issues
sicoyle c8dfbb2
fix: final fixes for build
sicoyle 2ac5969
fix: updates for build
sicoyle 21068e1
fix: final fixes for build
sicoyle 516fbe4
fix: update for tests
sicoyle 59fcbfb
fix: updates for test imports
sicoyle ed0c3fe
fix: 3.14 timing failure fix
sicoyle 79c84e1
fix: address rest of copilot feedback
sicoyle 7299487
fix: fixes for failures in build
sicoyle 7fb1d02
Merge branch 'main' into refactor/mv-dt-here
sicoyle 204759c
fix: correct port for test
sicoyle 236f982
fix: update tox for tests
sicoyle 1dd2527
fix(ci): pin to 1.17 as min so qs's quit failing on me
sicoyle 943a6e6
Merge branch 'main' into refactor/mv-dt-here
sicoyle File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
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
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
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,73 @@ | ||
| # This workflow will install Python dependencies, run tests and lint with a variety of Python versions | ||
| # For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-python | ||
|
|
||
| name: DurableTask Python Build Validation | ||
|
|
||
| on: | ||
| push: | ||
| branches: [ "main" ] | ||
| tags: ["v*"] | ||
| pull_request: | ||
| branches: [ "main" ] | ||
|
|
||
| jobs: | ||
| build: | ||
|
|
||
| runs-on: ubuntu-latest | ||
| strategy: | ||
| fail-fast: false | ||
| matrix: | ||
| python-version: ["3.10", "3.11", "3.12", "3.13", "3.14"] | ||
|
|
||
| steps: | ||
| - uses: actions/checkout@v4 | ||
| - name: Set up Python ${{ matrix.python-version }} | ||
| uses: actions/setup-python@v5 | ||
| with: | ||
| python-version: ${{ matrix.python-version }} | ||
| - name: Install dependencies | ||
| run: | | ||
| python -m pip install --upgrade pip | ||
| pip install -e durabletask[dev] | ||
| - name: Lint with ruff | ||
| run: | | ||
| ruff check durabletask/ durabletask_tests/ | ||
| - name: Pytest unit tests | ||
| run: | | ||
| pytest -m "not e2e" durabletask_tests/ | ||
| # Sidecar for running e2e tests requires Go SDK | ||
| - name: Install Go SDK | ||
| uses: actions/setup-go@v5 | ||
| with: | ||
| go-version: 'stable' | ||
| # Install and run the durabletask-go sidecar for running e2e tests | ||
| - name: Pytest e2e tests | ||
| run: | | ||
| # TODO: use dapr run instead of durabletask-go as it provides a more reliable sidecar behavior for e2e tests | ||
| go install github.com/dapr/durabletask-go@main | ||
| durabletask-go --port 4001 & | ||
| pytest -m e2e durabletask_tests/ | ||
| - name: Run examples | ||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I think this should happen as part of the |
||
| run: | | ||
| pip install mechanical-markdown | ||
| cd durabletask_examples | ||
| durabletask-go --port 4001 & | ||
| mm.py README.md | ||
| publish: | ||
| needs: build | ||
| if: startswith(github.ref, 'refs/tags/v') | ||
| runs-on: ubuntu-latest | ||
| env: | ||
| TWINE_USERNAME: "__token__" | ||
| steps: | ||
| - uses: actions/checkout@v4 | ||
| with: | ||
| fetch-depth: 0 | ||
| - name: Set up Python 3.11 | ||
| uses: actions/setup-python@v5 | ||
| with: | ||
| python-version: 3.11 | ||
| - name: Install dependencies | ||
| run: | | ||
| python -m pip install --upgrade pip | ||
| pip install setuptools wheel twine build | ||
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
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
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,86 @@ | ||
| # Changelog | ||
|
|
||
| All notable changes to this project will be documented in this file. | ||
|
|
||
| The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), | ||
| and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). | ||
|
|
||
| ## v0.3.0 | ||
|
|
||
| ### New | ||
|
|
||
| - Added `ConcurrencyOptions` class for fine-grained concurrency control with separate limits for activities and orchestrations. The thread pool worker count can also be configured. | ||
|
|
||
| ### Fixed | ||
|
|
||
| - Fixed an issue where a worker could not recover after its connection was interrupted or severed | ||
|
|
||
| ## v0.2.1 | ||
|
|
||
| ### New | ||
|
|
||
| - Added `set_custom_status` orchestrator API ([#31](https://github.com/microsoft/durabletask-python/pull/31)) - contributed by [@famarting](https://github.com/famarting) | ||
| - Added `purge_orchestration` client API ([#34](https://github.com/microsoft/durabletask-python/pull/34)) - contributed by [@famarting](https://github.com/famarting) | ||
|
|
||
| ### Changes | ||
|
|
||
| - Protos are compiled with gRPC 1.62.3 / protobuf 3.25.X instead of the latest release. This ensures compatibility with a wider range of grpcio versions for better compatibility with other packages / libraries ([#36](https://github.com/microsoft/durabletask-python/pull/36)) - by [@berndverst](https://github.com/berndverst) | ||
| - Http and grpc protocols and their secure variants are stripped from the host name parameter if provided. Secure mode is enabled if the protocol provided is https or grpcs ([#38](https://github.com/microsoft/durabletask-python/pull/38) - by [@berndverst)(https://github.com/berndverst) | ||
| - Improve ProtoGen by downloading proto file directly instead of using submodule ([#39](https://github.com/microsoft/durabletask-python/pull/39) - by [@berndverst](https://github.com/berndverst) | ||
|
|
||
| ### Updates | ||
|
|
||
| - Updated `durabletask-protobuf` submodule reference to latest | ||
|
|
||
| ## v0.1.1a1 | ||
|
|
||
| ### New | ||
|
|
||
| - Add recursive flag in terminate_orchestration to support cascade terminate ([#27](https://github.com/microsoft/durabletask-python/pull/27)) - contributed by [@shivamkm07](https://github.com/shivamkm07) | ||
|
|
||
| ## v0.1.0 | ||
|
|
||
| ### New | ||
|
|
||
| - Retry policies for activities and sub-orchestrations ([#11](https://github.com/microsoft/durabletask-python/pull/11)) - contributed by [@DeepanshuA](https://github.com/DeepanshuA) | ||
|
|
||
| ### Fixed | ||
|
|
||
| - Fix try/except in orchestrator functions not being handled correctly ([#21](https://github.com/microsoft/durabletask-python/pull/21)) - by [@cgillum](https://github.com/cgillum) | ||
| - Updated `durabletask-protobuf` submodule reference to latest distributed tracing commit - by [@cgillum](https://github.com/cgillum) | ||
|
|
||
| ## v0.1.0a5 | ||
|
|
||
| ### New | ||
|
|
||
| - Adds support for secure channels ([#18](https://github.com/microsoft/durabletask-python/pull/18)) - contributed by [@elena-kolevska](https://github.com/elena-kolevska) | ||
|
|
||
| ### Fixed | ||
|
|
||
| - Fix zero argument values sent to activities as None ([#13](https://github.com/microsoft/durabletask-python/pull/13)) - contributed by [@DeepanshuA](https://github.com/DeepanshuA) | ||
|
|
||
| ## v0.1.0a3 | ||
|
|
||
| ### New | ||
|
|
||
| - Add gRPC metadata option ([#16](https://github.com/microsoft/durabletask-python/pull/16)) - contributed by [@DeepanshuA](https://github.com/DeepanshuA) | ||
|
|
||
| ### Changes | ||
|
|
||
| - Removed Python 3.7 support due to EOL ([#14](https://github.com/microsoft/durabletask-python/pull/14)) - contributed by [@berndverst](https://github.com/berndverst) | ||
|
|
||
| ## v0.1.0a2 | ||
|
|
||
| ### New | ||
|
|
||
| - Continue-as-new ([#9](https://github.com/microsoft/durabletask-python/pull/9)) | ||
| - Support for Python 3.7+ ([#10](https://github.com/microsoft/durabletask-python/pull/10)) - contributed by [@DeepanshuA](https://github.com/DeepanshuA) | ||
|
|
||
| ## v0.1.0a1 | ||
|
|
||
| Initial release, which includes the following features: | ||
|
|
||
| - Orchestrations and activities | ||
| - Durable timers | ||
| - Sub-orchestrations | ||
| - Suspend, resume, and terminate client operations |
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,21 @@ | ||
| MIT License | ||
|
|
||
| Copyright (c) Microsoft Corporation. | ||
|
|
||
| Permission is hereby granted, free of charge, to any person obtaining a copy | ||
| of this software and associated documentation files (the "Software"), to deal | ||
| in the Software without restriction, including without limitation the rights | ||
| to use, copy, modify, merge, publish, distribute, sublicense, and/or sell | ||
| copies of the Software, and to permit persons to whom the Software is | ||
| furnished to do so, subject to the following conditions: | ||
|
|
||
| The above copyright notice and this permission notice shall be included in all | ||
| copies or substantial portions of the Software. | ||
|
|
||
| THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR | ||
| IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, | ||
| FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE | ||
| AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER | ||
| LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, | ||
| OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE | ||
| SOFTWARE |
Oops, something went wrong.
Oops, something went wrong.
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.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Shouldn't durabletask be tested in the same steps as everything else?