Skip to content

.NET/Python: [BREAKING] Clarify docker params usage and rename param - #9453

Merged
Eduard van Valkenburg (eavanvalkenburg) merged 3 commits into
microsoft:mainfrom
westey-m:docker-switch-to-unsafe-param
Oct 16, 2026
Merged

Eduard van Valkenburg (eavanvalkenburg) merged 3 commits into
microsoft:mainfrom
westey-m:docker-switch-to-unsafe-param

Conversation

@westey-m

@westey-m westey (westey-m) commented Oct 16, 2026 •

Copy link
Copy Markdown
Collaborator

Motivation & Context

Description & Review Guide

Improve instructions around how to use docker params and rename param

  • What are the major changes?
  • What is the impact of these changes?
  • What do you want reviewers to focus on?

Related Issue

Fixes #

AI Assistance

  • No material AI assistance was used.
  • This is an AI-assisted contribution. I reviewed, understood, and verified all submitted content and accept responsibility for it.

AI assistance details:

Contribution Checklist

  • The code builds clean without any errors or warnings
  • All unit tests pass, and I have added new tests where possible
  • The PR follows the Contribution Guidelines
  • This PR links to an agreed issue with no competing open PR, or the Related Issue section documents a trivial-change or repository-automation exception.
  • This is not a breaking change. If it is a breaking change, add the breaking change label (or add "[BREAKING]" to the title prefix, before or after any language prefix) — a workflow keeps the label and title prefix in sync automatically.

Copilot AI balanced review requested due to automatic review settings October 16, 2026 10:01
@agent-framework-automation agent-framework-automation Bot added documentation Usage: [Issues, PRs], Target: documentation in the code base and learn docs python Usage: [Issues, PRs], Target: Python .NET Usage: [Issues, PRs], Target: .Net labels Oct 16, 2026
@github-actions github-actions Bot changed the title Clarify docker params usage and rename param Python: Clarify docker params usage and rename param Oct 16, 2026
@github-actions github-actions Bot changed the title Clarify docker params usage and rename param .NET: Clarify docker params usage and rename param Oct 16, 2026

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟡 Changes recommended

Both public API renames break existing callers despite the non-breaking declaration.

2 open findings
What changed in this PR

Clarifies trusted Docker configuration for the Python and .NET shell tools and explicitly names unsafe options.

Changes:

  • Renames extra-run options and documents their isolation risks.
  • Replaces Python flag blocking with token validation and snapshots caller-owned arguments.
  • Adds validation, snapshot, and argument-forwarding tests.
File Description
python/​packages/​tools/​tests/​test_docker_shell_tool.py Updates validation and forwarding tests.
python/​packages/​tools/​README.md Explains trusted configuration and isolation risks.
python/​packages/​tools/​agent_framework_tools/​shell/​_docker.py Renames options and replaces flag blocking.
dotnet/​tests/​Microsoft.Agents.AI.Tools.Shell.UnitTests/​DockerShellExecutorTests.cs Tests validation, snapshots, forwarding, and descriptions.
dotnet/​src/​Microsoft.Agents.AI.Tools.Shell/​ShellExecutor.cs Qualifies default isolation guarantees.
dotnet/​src/​Microsoft.Agents.AI.Tools.Shell/​DockerShellExecutorOptions.cs Renames and documents unsafe options.
dotnet/​src/​Microsoft.Agents.AI.Tools.Shell/​DockerShellExecutor.cs Snapshots and validates options; clarifies isolation descriptions.

🧠 Review effort: Balanced


💡 Add a code-review agent skill for context-aware, tailored reviews. Learn more in the docs.

Comment thread python/packages/tools/agent_framework_tools/shell/_docker.py

@github-actions github-actions Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

MAF Automated Review — Iteration 1

Result: Findings reported
Scope: full PR (1 commit(s)): fdc245c4e1c2
Model: gpt-5.6-sol

Overview

The PR makes unrestricted Docker arguments an explicitly unsafe, developer-controlled configuration surface and adds input snapshots, token-shape validation, warnings, and coverage for both execution modes. Default isolation and the model-facing command boundary remain intact. However, both renamed options were already shipped publicly, and removing their old names without compatibility aliases breaks existing .NET and Python consumers during upgrade.

Reviewed the supplied pull-request change set across correctness, security/reliability, architecture, and failure behavior.
2 verified findings remained after source verification (2 medium) across 2 files. Details are attached to the affected lines below.

Affected areas: dotnet/src/Microsoft.Agents.AI.Tools.Shell/DockerShellExecutorOptions.cs, python/packages/tools/agent_framework_tools/shell/_docker.py

Comment thread python/packages/tools/agent_framework_tools/shell/_docker.py

@baywet Vincent Biret (baywet) left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

only looked at dotnet part

@westey-m westey (westey-m) changed the title .NET: Clarify docker params usage and rename param .NET/Python: [BREAKING] Clarify docker params usage and rename param Oct 16, 2026
Merged via the queue into microsoft:main with commit ba4f6b3 Oct 16, 2026
55 checks passed

This branch was successfully deployed

1 active deployment
github-app-auth — 7e667fc3 Deployed Oct 16, 2026 by westey-m via add_label #25606
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentation Usage: [Issues, PRs], Target: documentation in the code base and learn docs .NET Usage: [Issues, PRs], Target: .Net python Usage: [Issues, PRs], Target: Python

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants