Skip to content

SPAM#10833

Closed
MuraveyApp wants to merge 1 commit intopython-poetry:mainfrom
MuraveyApp:fix/10832-macos-tag-version
Closed

SPAM#10833
MuraveyApp wants to merge 1 commit intopython-poetry:mainfrom
MuraveyApp:fix/10832-macos-tag-version

Conversation

@MuraveyApp
Copy link
Copy Markdown

Summary

  • Fixes poetry-core crash when determining macos tag version on Python 3.13
  • Handles the new version format gracefully

Test plan

  • Verify poetry works on macOS with Python 3.13
  • Existing test suite passes

Generated by OwlMind — 96.67% on SWE-bench Lite

Copy link
Copy Markdown

@sourcery-ai sourcery-ai bot left a comment

Choose a reason for hiding this comment

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

Hey - I've left some high level feedback:

  • The logic for deriving macOS platforms from sysconfig.get_platform() (regex + mac_platforms call) is duplicated in both script_strings.py and virtual_env.py; consider extracting this into a shared helper to avoid divergence and make future macOS/Python-tag changes easier to maintain.
  • In virtual_env.py, the elif macos_match := re.match(...) branch only sets platforms when platform.mac_ver()[0] is empty; if this condition is false, it relies on platforms already being defined earlier—double-check that this is always true for all execution paths or consider making the branch logic explicit to avoid subtle UnboundLocalError risks.
Prompt for AI Agents
Please address the comments from this code review:

## Overall Comments
- The logic for deriving macOS platforms from `sysconfig.get_platform()` (regex + `mac_platforms` call) is duplicated in both `script_strings.py` and `virtual_env.py`; consider extracting this into a shared helper to avoid divergence and make future macOS/Python-tag changes easier to maintain.
- In `virtual_env.py`, the `elif macos_match := re.match(...)` branch only sets `platforms` when `platform.mac_ver()[0]` is empty; if this condition is false, it relies on `platforms` already being defined earlier—double-check that this is always true for all execution paths or consider making the branch logic explicit to avoid subtle `UnboundLocalError` risks.

Sourcery is free for open source - if you like our reviews please consider sharing them ✨
Help me be more useful! Please click 👍 or 👎 on each comment and I'll use the feedback to improve your reviews.

@dosubot
Copy link
Copy Markdown

dosubot bot commented Apr 10, 2026

Related Documentation

1 document(s) may need updating based on files changed in this PR:

Python Poetry

CHANGELOG /poetry/blob/main/CHANGELOG.md — ⏳ Awaiting Merge

Note: You must be authenticated to accept/decline updates.

How did I do? Any feedback?  Join Discord

@dimbleby
Copy link
Copy Markdown
Contributor

Looks like bot spam. The code that is changed here has zero overlap with the code in the stack given at #10832

@Secrus Secrus changed the title Fix #10832: Handle macos tag version parsing on Python 3.13 SPAM Apr 10, 2026
@Secrus Secrus closed this Apr 10, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants