← Back to Pull requests

Fix Python 3.14 warnings for v1 environment paths #5739

Closed
unknown closed this pull request without merging on Nov 10, 2026 17:49 UTC
View on GitHub
unknown unknown commented on Nov 10, 2026 17:30 UTC
Author

Summary

Python 3.14 warns when v1 Environment converts a pure path to a file URI. Apps that treat warnings as errors can fail while setting a working directory or writable root.

The executor now encodes those paths without the deprecated call on Python 3.12 and later. It keeps the existing URI format for POSIX, drive, and UNC paths. Older Python versions retain their existing encoding.

Test plan

  • Reproduced the failure with Python 3.14 deprecation warnings treated as errors.

  • Checked working directories and writable roots for spaces, special characters, Unicode, and existing file URIs.

  • Verified Unicode drive and UNC paths under a real Python 3.11 ASCII locale.

  • Passed repository formatting, lint, type checking, and the released v0 API contract check.

  • Passed distribution and Classic/v1 import checks with a rebuilt test wheel containing this commit's Python source.

  • Passed 7,977 parallel tests and 65 serial tests on Python 3.13.16.

  • Confirmed the writable-root and drive URI outputs on the target and PR commits under Python 3.12.3 and 3.13.16.

  • Used Python 3.13.16 for the full local run after reproducing the Python 3.14.8 native tool schema failure on the unchanged target. The focused Python 3.14 path and native tests passed.
  • Checks

  • Added v1 path regression tests.

  • Completed the full SDK test run locally.

  • Completed independent review.
  • Diff: 175 lines (+131 / -44) across 2 files Reviewer: mangeshraut712 Review duration: 19m
    All Vouch review confidence checks passed
    Residual risk 0.14 = Change Risk (0.35) × (1 − Review Confidence (0.60)). Review depth and reviewer attention state are adequate.
    Model 1 · Change Risk (XGBoost)
    Score: 0.35 · 175 lines diff across 2 files
    0.35
    Model 2 · Review Depth (DistilBERT)
    Depth Score: 0.17 · 1 substantive comment(s)
    0.17
    Model 3 · Review Timing & Attention
    Session adequacy: 100% · Reviewer familiarity: 35%
    60%
    Bedrock Claude 3 · Risk Narration
    (disconnected)
    Groq
    Groq Risk Narration
    AWS Bedrock is currently disconnected. Generate high-confidence PR triage narration on-demand using Groq.
    Model 1 · Change Risk Attribution
    SHAP Weights
    Diff Size diff_size
    0.309
    Shallow Review Depth shallow_review_depth
    0.289
    Real PR Conversation Timeline
    1 comments
    "Review active on #5739"
    general weight: 0.35
    Assignees
    Unassigned
    Labels
    risk: low confidence: 60.5% reviewed
    Vouch Risk Breakdown
    AI-powered review risk analysis
    Change Risk
    Change Risk · Model 1 (XGBoost)
    Predicted defect probability (0.00–1.00) based on diff churn, modified sensitive files, and author risk history.
    Score: 35.4% (MEDIUM) · Higher = larger blast radius
    35.4%
    Review Confidence
    Review Confidence · Models 2 & 3
    Scrutiny score (0.00–1.00) combining DistilBERT semantic review depth with reviewer familiarity and session dwell time.
    Score: 60.5% · Lower = rushed or shallow review
    60.5%
    Residual Risk
    Residual Risk · Core Equation
    Residual = Change × (1 − Confidence)
    Unmitigated risk surviving review. ≥ 0.65 triggers an automated re-queue to protect production.
    Score: 14.0% · Safe to merge
    14.0%