Skip to content

Fix x86_64-pc-windows-gnu build - #8411

Merged
youknowone merged 1 commit into
RustPython:mainfrom
joshuamegnauth54:fix-x86_64-pc-windows-gnu
Jul 30, 2026
Merged

Fix x86_64-pc-windows-gnu build#8411
youknowone merged 1 commit into
RustPython:mainfrom
joshuamegnauth54:fix-x86_64-pc-windows-gnu

Conversation

@joshuamegnauth54

@joshuamegnauth54 joshuamegnauth54 commented Jul 29, 2026

Copy link
Copy Markdown
Contributor

A few functions were improperly gated to MSVC. Those functions call windows-sys so they're not MSVC.

Summary

  • Fixes a build error for the x86_64-pc-windows-gnu target

Summary by CodeRabbit

  • New Features
    • Expanded Windows time zone support beyond MSVC, enabling the time-zone information API on additional Windows targets (excluding WASM).
  • CI
    • Broadened build verification by adding an x86_64-pc-windows-gnu target to the CI cargo check matrix.
    • Updated the Linux dependency installer to optionally install the MinGW-w64 toolchain needed for that target.

@coderabbitai

coderabbitai Bot commented Jul 29, 2026

Copy link
Copy Markdown
Contributor

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yml

Review profile: CHILL

Plan: Pro Plus

Run ID: 038c688e-0f61-4e02-9785-61fafe450c71

📥 Commits

Reviewing files that changed from the base of the PR and between ff49322 and e60043b.

📒 Files selected for processing (4)
  • .github/actions/install-linux-deps/action.yml
  • .github/workflows/ci.yaml
  • crates/host_env/src/time.rs
  • crates/vm/src/stdlib/time.rs

📝 Walkthrough

Walkthrough

Windows time zone support now compiles for non-MSVC Windows targets beyond MSVC. The VM helper uses the broader gate, and CI adds Windows GNU target coverage with MinGW dependency installation.

Changes

Windows time zone support

Layer / File(s) Summary
Broaden Windows compilation gates
crates/host_env/src/time.rs, crates/vm/src/stdlib/time.rs
Windows time zone types, name decoding, and the VM helper are included on Windows targets beyond MSVC, while wasm32 remains excluded where applicable.
Add Windows GNU CI coverage
.github/workflows/ci.yaml, .github/actions/install-linux-deps/action.yml
The cargo_check matrix adds x86_64-pc-windows-gnu, and the Linux dependency action conditionally installs MinGW-w64 GCC for that target.

Estimated code review effort: 1 (Trivial) | ~5 minutes

Possibly related PRs

Suggested labels: z-ca-2026

Suggested reviewers: 2jiyong, youknowone

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly matches the main change: enabling the x86_64-pc-windows-gnu build by fixing Windows-specific gating.
Docstring Coverage ✅ Passed Docstring coverage is 100.00% which is sufficient. The required threshold is 80.00%.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@joshuamegnauth54
joshuamegnauth54 marked this pull request as ready for review July 29, 2026 19:11

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

TYSM!!!
can you please add it as a target at the cargo-check step so it won't break again?

@joshuamegnauth54
joshuamegnauth54 force-pushed the fix-x86_64-pc-windows-gnu branch from 483896e to cc8e5f9 Compare July 29, 2026 23:19

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

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In @.github/workflows/ci.yaml:
- Around line 201-204: Update the workflow’s install-linux-deps invocation to
forward the matrix gcc-mingw-w64-x86-64 dependency key, and extend the local
action’s declared inputs and installation handling if needed so the MinGW
compiler is installed for the x86_64-pc-windows-gnu target.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yml

Review profile: CHILL

Plan: Pro Plus

Run ID: 4a173935-6de4-492a-a79a-65fa049a6465

📥 Commits

Reviewing files that changed from the base of the PR and between 483896e and cc8e5f9.

📒 Files selected for processing (3)
  • .github/workflows/ci.yaml
  • crates/host_env/src/time.rs
  • crates/vm/src/stdlib/time.rs

Comment thread .github/workflows/ci.yaml
@joshuamegnauth54
joshuamegnauth54 force-pushed the fix-x86_64-pc-windows-gnu branch from cc8e5f9 to ff49322 Compare July 29, 2026 23:34
A few functions were improperly gated to MSVC. Those functions call
`windows-sys` so they're not MSVC.
@joshuamegnauth54
joshuamegnauth54 force-pushed the fix-x86_64-pc-windows-gnu branch from ff49322 to e60043b Compare July 30, 2026 00:04

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

ty<3

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

Thank you! adding a CI is great idea

@youknowone
youknowone merged commit 1e34770 into RustPython:main Jul 30, 2026
27 checks passed
@joshuamegnauth54
joshuamegnauth54 deleted the fix-x86_64-pc-windows-gnu branch July 30, 2026 16:21
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