Repository navigation
D-43840 Support abort signal in container python plugin - #23
tgreblicki-notch wants to merge 1 commit into
Conversation
support SIGABRT for aborting tasks, update unit tests and docs
|
| CVE | Package | Version | Fix |
|---|---|---|---|
| CVE-2026-97689 | urllib3 |
2.7.0 |
2.8.0 |
| CVE-2026-97687 | urllib3 |
2.7.0 |
2.8.0 |
🟡 Medium · 3 findings
| CVE | Package | Version | Fix |
|---|---|---|---|
| CVE-2026-49264 | oauthlib |
3.3.1 |
4.0.0 |
| CVE-2026-49265 | oauthlib |
3.3.1 |
4.0.0 |
| CVE-2026-97688 | urllib3 |
2.7.0 |
2.8.0 |
View full analysis in Upwind Console
Scan completed in 15s
Scan history (1 scan)
| Commit | Scanned at | New | Resolved | Net |
|---|---|---|---|---|
458c4f3 < |
2026-10-06 14:21 UTC | +5 | 0 | +5 |
Last scanned: 458c4f3 · 2026-10-06 14:21 UTC
|
| Commit | Scanned at | New | Resolved | Net |
|---|---|---|---|---|
458c4f3 < |
2026-10-06 14:21 UTC | 0 | 0 | 0 |
Last scanned: 458c4f3 · 2026-10-06 14:21 UTC
|
| File | Line | Type | Value |
|---|---|---|---|
tests/release/integration/test_wrapper_k8s.py |
79 | generic-api-key | inpu••••cret |
🔶 PII · 1 finding
| File | Line | Type | Value |
|---|---|---|---|
pyproject.toml |
8 | py••••@digital.ai |
A secret that has been pushed remains in the repository's history even after the line is removed.
Scan completed in 3s.
Scan history (1 scan)
| Commit | Scanned at | New | Resolved | Net |
|---|---|---|---|---|
458c4f3 < |
2026-10-06 14:21 UTC | +2 | 0 | +2 |
Last scanned: 458c4f3 · 2026-10-06 14:21 UTC
There was a problem hiding this comment.
Copilot review overview
🟡 Changes recommended
Signal/reporting races and worker-thread exit semantics can prevent reliable abort completion or produce incorrect results.
Review effort: Balanced
Findings: 1
Open (3)
What changed in this PR
Adds abort-signal support and worker-thread task execution to the Python integration SDK.
Changes:
- Adds cooperative abort state and updated abort semantics.
- Handles SIGABRT/SIGTERM while tasks run in worker threads.
- Adds documentation and abort-focused tests.
| File | Description |
|---|---|
digitalai/release/integration/base_task.py |
Adds abort state and context initialization. |
digitalai/release/integration/wrapper.py |
Adds threaded execution, signal handling, and guarded reporting. |
tests/release/integration/test_base_task.py |
Tests new abort behavior. |
tests/release/integration/test_wrapper_abort.py |
Tests signal and threading behavior. |
tests/release/integration/blocking_task.py |
Provides the blocking-task fixture. |
docs/examples.md |
Documents cooperative cancellation. |
docs/classes/base_task.md |
Updates the BaseTask API reference. |
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
| # the task finishes normally (worker thread's completion path) or is aborted | ||
| # (main thread's signal handler). Reset at the start of each execute_task() | ||
| # call so daemon-mode iterations each get a fresh guard. | ||
| _report_lock = threading.Lock() |
| except Exception: | ||
| dai_logger.error("Unexpected error occurred.", exc_info=True) |
| # Give the task time to enter its blocking sleep(30) call. | ||
| time.sleep(1.0) | ||
| start = time.monotonic() | ||
| proc.send_signal(signal.SIGABRT) |


Adds support for abort signal in python sdk.
It also add worker thread for task execution to enable abort of blocking task executions.
https://www7.v1host.com/V1Production/defect.mvc/Summary?oidToken=Defect%3A3648730