Skip to content

Python: Consolidate tooling helper fixes - #9706

Merged
Eduard van Valkenburg (eavanvalkenburg) merged 1 commit into
microsoft:mainfrom
eavanvalkenburg:consolidate-helper-fixes
Oct 26, 2026
Merged

Eduard van Valkenburg (eavanvalkenburg) merged 1 commit into
microsoft:mainfrom
eavanvalkenburg:consolidate-helper-fixes

Conversation

@eavanvalkenburg

Copy link
Copy Markdown
Member

Motivation & Context

Three small repository helpers have compatibility or Markdown-rendering behavior that does not match their existing contracts: the dependency wrapper rejects its hidden legacy --project selector, Markdown --no-glob mode still interprets metacharacters, and integration trend tables split parameterized test names containing pipes into extra columns.

This consolidates the useful behavior from three now-closed PRs into one deliberately minimal replacement, without adding a test harness or expanding workflow collection.

Description & Review Guide

  • What are the major changes? Validate the shared dependency selector destination after argument parsing so either -P/--package or the hidden --project alias satisfies it; escape literal Markdown paths before passing them to glob.glob in --no-glob mode; escape pipes only in displayed short test names when building integration trend Markdown tables.
  • What is the impact of these changes? Existing compatibility and rendering behavior is restored without changing ordinary glob expansion, dependency resolution/delegation, report history keys, workflow files, or test infrastructure.
  • What do you want reviewers to focus on? The patch is limited to 4 insertions and 3 deletions across the three existing helpers. Focused direct regression cases and unchanged controls passed. Targeted pinned Ruff lint passed with ruff check --no-fix --select E4,E7,E9,F,I, range-format checks passed for each edited region, and git diff --check passed. Validation is intentionally lightweight because these scripts are excluded from the workspace-wide Ruff surface and have no existing appropriate regression modules.

Related Issue

N/A - trivial change. These are narrow corrections to existing helper contracts whose desired behavior is already explicit. This consolidated replacement supersedes #9674, #9691, and #9692 while intentionally keeping implementation and validation lightweight. No competing open PR was found.

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: Copilot assisted with implementation, focused validation, and this PR description.

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 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.

🟢 Approval recommended

The three fixes are narrowly scoped, preserve surrounding behavior, and have no identified blocking issues.

No open issues 🎉

What changed in this PR

This PR consolidates three small fixes to existing Python repository helpers, restoring compatibility and Markdown behavior without changing workflows or test infrastructure.

Changes:

  • Allow the hidden --project alias to satisfy the required dependency package selector.
  • Treat Markdown paths literally in --no-glob mode.
  • Escape pipes in displayed test names while preserving report identifiers and history data.
File Description
python/​scripts/​integration_test_report/​aggregate.py Escape test-name pipes to preserve Markdown table columns.
python/​scripts/​dependencies/​add_dependency_to_project.py Validate the shared selector after parsing so the legacy alias works.
python/​scripts/​check_md_code_blocks.py Escape glob metacharacters when selecting literal Markdown paths.

Review effort: Balanced

@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: No findings
Scope: full PR (1 commit(s)): c23e77ce90bd
Model: gpt-5.6-sol

Overview

The PR narrowly restores three helper contracts: literal Markdown paths no longer expand metacharacters, the hidden dependency selector alias reaches the shared destination, and displayed test names escape table delimiters without changing persisted result keys. Existing validation and resolution guards constrain the changes, and no Critical, High, or Medium defect was established.

Reviewed the supplied pull-request change set across correctness, security/reliability, architecture, and failure behavior.
No publishable findings remained after source verification for this scope.

Merged via the queue into microsoft:main with commit eeeb67a Oct 26, 2026
59 checks passed
@eavanvalkenburg
Eduard van Valkenburg (eavanvalkenburg) deleted the consolidate-helper-fixes branch October 26, 2026 13:37

This branch was previously deployed

1 inactive deployment
github-app-auth — c23e77ce Deployed Oct 26, 2026 by eavanvalkenburg via team_check #7494
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

python Usage: [Issues, PRs], Target: Python

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants