Skip to content

fix(relay,video): unbreak the Windows platform build - #6821

Merged
kixelated merged 2 commits into
mainfrom
fix/windows-platform-lints
Oct 26, 2026
Merged

kixelated merged 2 commits into
mainfrom
fix/windows-platform-lints

Conversation

@kixelated

@kixelated kixelated commented Oct 25, 2026 •

Copy link
Copy Markdown
Collaborator

Nightly's Platform Windows job fails on main (run):

warning: this lint expectation is unfulfilled
   --> rs\moq-relay\src\relay.rs:871:10
error: warnings are denied by `build.warnings` configuration
  • moq-relay: the module-wide #[expect(clippy::disallowed_methods)] on relay::tests is only fulfilled by the #[cfg(unix)] signal test's Instant::now() and the stun-gated test's tokio::time::timeout, so a Windows build without stun reports it unfulfilled. Moved onto those two tests.
  • moq-video: the same job warned about code compiled on Windows with no caller there (non-fatal only because the platform cargo check does not deny warnings). Gated each to its users:
    • I420::from_bgra: PipeWire only.
    • pump::Read::Idle: only X11 returns it.
    • Applied::new's dead-code allowance now matches the backend gates (NVENC and VA-API are Linux-only, VideoToolbox is apple); a default-feature Windows build failed -D warnings on it.

The relay and from_bgra fixes mirror the ones in moq-dev/moq#6805, written against current main (#6805's relay change misses the stun test, which the all-features clippy shape catches).

Impact

No public API or wire impact.

Checks

  • Cross cargo clippy --target x86_64-pc-windows-msvc -- -D warnings for moq-video (default, --no-default-features, capture, capture,render). moq-relay does not cross-build here (ring and aws-lc-sys need an MSVC C toolchain); covered by the Platform dispatch below.
  • Linux: just check; clippy -D warnings for moq-relay (default, all features) and moq-video (default, no default, capture, capture,pipewire); relay::tests with all features.
  • Platform dispatch on this branch: https://github.com/moq-dev/moq/actions/runs/40244813741

(Written by Claude Opus 5.5)

🤖 Generated with Claude Code

The relay's module-wide clippy::disallowed_methods expectation is only
fulfilled by the Unix-only signal test, so Windows reports it unfulfilled
and the denied-warnings test build fails. Move it onto that test.

moq-video compiled code on Windows that nothing there calls:
I420::from_bgra (only PipeWire uses it), pump::Read::Idle (only X11
returns it), and Applied::new under default features (NVENC and VA-API
backends are Linux-only). Gate each to where it is used.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@coderabbitai

coderabbitai Bot commented Oct 25, 2026 •

Copy link
Copy Markdown
Contributor

Review in Change Stack →

No actionable comments were generated in the recent review.

Recent review info
Run configuration
  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: Organization UI
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 0f4720f5-fd23-462e-9f92-3037c6b1d13a
Commits

Reviewing files that changed from the base of the PR and between 011402e and ec14978.

Files selected for processing: 4
  • rs/moq-relay/src/relay.rs
  • rs/moq-video/src/capture/pump.rs
  • rs/moq-video/src/encode/encoder.rs
  • rs/moq-video/src/frame.rs

Included review availability: This review used your included allowance. Your plan provides up to 4 included reviews per hour; 1 remain after this review.

Walkthrough

The changes update Clippy expectation placement in a relay test and adjust platform-specific compilation conditions in video capture, encoding, and frame conversion code.

Priority: Normal

Merge Risk: Minimal · up to ec149

No actionable merge-blocking risk was found.

Pre-merge checks: Passed 4 · Failed 1

Failed Failed checks: 1 warning

Check name Status Explanation Resolution
Docstring Coverage Warning Docstring coverage is 66.67% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 6 functions across 4 files. Write docstrings for the functions missing them to satisfy the coverage threshold.
Passed Passed checks: 4 passed
Check name Status Explanation
Description check Passed The description clearly explains the Windows build warnings and the platform-specific fixes in the changeset.
Title check Passed The title clearly and concisely identifies the relay and video changes that restore the Windows platform build.
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
✨ Simplify code
  • Commit to this branch
  • Create a new PR
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Warning

Some tools did not complete. Review the errors below.

🔧 Clippy (1.99.0)

Clippy execution timed out

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.

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Oct 25, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-10-25T22:51:25.950813Z 910417e PR opened
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@kixelated kixelated left a comment

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

Automated review by review (OpenAI)

Reviewed commit: 910417e

No actionable bugs found. The narrower lint expectation is attached to the Unix-only test that actually reads Instant::now(), and the video cfg changes match the existing PipeWire/X11 callers and platform-gated encoder backends. This is a suitably small build fix rather than a broad warning suppression; no runtime or wire change is needed.

Verification: static inspection of the diff, surrounding tests, caller sites, backend gates and the apple alias. I did not run Clippy, cross-compilation, tests or the platform workflow.

The module-wide expectation also covered the stun-gated test's
tokio::time::timeout, so the all-features shape now needs its own
allowance. Also take rustfmt's spacing on the gated match arm.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

@kixelated kixelated left a comment

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

Automated review by review (OpenAI)

Reviewed commit: ec14978

No actionable bugs found in the update since 910417e. The STUN test also calls the explicitly disallowed tokio::time::timeout; its new function-scoped expectation correctly restores that feature-enabled lint shape without restoring the overly broad module expectation. My earlier review missed this second caller. Keeping both exemptions with their gated tests is the right direction; the pump change is formatting-only.

Verification: static comparison and inspection of the test and crate Clippy configuration. I did not run Clippy, builds or tests.

@kixelated
kixelated added this pull request to the merge queue Oct 26, 2026
Merged via the queue into main with commit 74c9116 Oct 26, 2026
13 checks passed
@kixelated
kixelated deleted the fix/windows-platform-lints branch October 26, 2026 01:10
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.

1 participant