Skip to content

fix(ci): repair main required gates - fr007 test compile fixes + pin rust 1.96.0 - #631

Merged
KooshaPari merged 1 commit into
mainfrom
fix/ci-gate-main
Aug 2, 2026
Merged

fix(ci): repair main required gates - fr007 test compile fixes + pin rust 1.96.0#631
KooshaPari merged 1 commit into
mainfrom
fix/ci-gate-main

Conversation

@KooshaPari

@KooshaPari KooshaPari commented Aug 2, 2026

Copy link
Copy Markdown
Owner

User description

Summary

Branch protection on main requires ci / lint and ci / test (from the #629 ci-gate workflow). Both are currently failing on main:

  • ci/test: cargo check --workspace --all-targets fails with 3 compile errors in tests/fr007_ipc_monitoring_report_{gate_host_watch,pool_status}.rs:
    • E0252 duplicate use sharecli::runtime::ProcState; import
    • E0308 state: ProcState::default() but the field is String on current main
    • E0560/E0063 nonexistent log_location field / missing thread_count field (canonical struct at crates/sharecli-ipc/src/handler.rs:179)
  • ci/lint: cargo fmt --check drifts because rust-toolchain.toml pins floating stable and rustfmt.toml uses unstable options (group_imports, indent_style) that only nightly honors. The runner's newer stable rustfmt disagrees with the committed formatting.

Fix (FR-007 CI gate repair):

  • Fix both fr007 test files: remove duplicate ProcState import, use state: "Unknown".into(), replace log_location with thread_count: None matching the canonical struct.
  • Normalize workspace formatting with the pinned toolchain (10 files).
  • Pin rust-toolchain.toml to 1.96.0 for deterministic rustfmt/rustc in CI.

Test plan

  • ci / lint (cargo fmt --check) passes on this PR
  • ci / test (cargo check --workspace --all-targets) passes on this PR
  • Both required contexts green -> subsequent PRs satisfy branch protection

CodeAnt-AI Description

Restore deterministic CI checks and fix monitoring report test compatibility

What Changed

  • Fix FR-007 monitoring report tests to match the current process status fields and remove duplicate imports
  • Pin CI to Rust 1.96.0 so formatting and compilation checks use a consistent toolchain
  • Normalize Rust formatting across the affected source and test files

Impact

✅ Passing required CI gates
✅ Reliable monitoring report validation
✅ Consistent builds across CI runs

💡 Usage Guide

Checking Your Pull Request

Every time you make a pull request, our system automatically looks through it. We check for security issues, mistakes in how you're setting up your infrastructure, and common code problems. We do this to make sure your changes are solid and won't cause any trouble later.

Talking to CodeAnt AI

Got a question or need a hand with something in your pull request? You can easily get in touch with CodeAnt AI right here. Just type the following in a comment on your pull request, and replace "Your question here" with whatever you want to ask:

@codeant-ai ask: Your question here

This lets you have a chat with CodeAnt AI about your pull request, making it easier to understand and improve your code.

Example

@codeant-ai ask: Can you suggest a safer alternative to storing this secret?

Preserve Org Learnings with CodeAnt

You can record team preferences so CodeAnt AI applies them in future reviews. Reply directly to the specific CodeAnt AI suggestion (in the same thread) and replace "Your feedback here" with your input:

@codeant-ai: Your feedback here

This helps CodeAnt AI learn and adapt to your team's coding style and standards.

Example

@codeant-ai: Do not flag unused imports.

Retrigger review

Ask CodeAnt AI to review the PR again, by typing:

@codeant-ai: review

Check Your Repository Health

To analyze the health of your code repository, visit our dashboard at https://app.codeant.ai. This tool helps you identify potential issues and areas for improvement in your codebase, ensuring your repository maintains high standards of code health.

Copilot AI review requested due to automatic review settings August 2, 2026 20:17
@gemini-code-assist

Copy link
Copy Markdown

Caution

The consumer version of Gemini Code Assist on GitHub has been sunset. All code review activity has officially ceased.

@codeant-ai

codeant-ai Bot commented Aug 2, 2026

Copy link
Copy Markdown

🤖 CodeAnt AI — Review Status

Status Commit Started (UTC) Finished (UTC)
✅ Reviewed your PR 0c18503 Aug 02, 2026 · 20:17 20:20

@codeant-ai

codeant-ai Bot commented Aug 2, 2026

Copy link
Copy Markdown

Thanks for using CodeAnt! 🎉

We're free for open-source projects. if you're enjoying it, help us grow by sharing.

Share on X ·
Reddit ·
LinkedIn

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

@coderabbitai

coderabbitai Bot commented Aug 2, 2026

Copy link
Copy Markdown

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: ASSERTIVE

Plan: Pro Plus

Run ID: 42f3cd53-625e-419b-a163-1cf45ba0c20c

📥 Commits

Reviewing files that changed from the base of the PR and between 7379c0a and 0c18503.

📒 Files selected for processing (11)
  • crates/sharecli-fuse/build.rs
  • crates/sharecli-fuse/src/backend.rs
  • crates/sharecli-fuse/src/bin/mfmount-probe.rs
  • crates/sharecli-fuse/src/lib.rs
  • crates/sharecli-fuse/src/session_registry.rs
  • crates/sharecli-ipc/src/handler.rs
  • crates/sharecli-ipc/src/log_buffer.rs
  • rust-toolchain.toml
  • tests/c09_l81_stop_force_confirm.rs
  • tests/fr007_ipc_monitoring_report_gate_host_watch.rs
  • tests/fr007_ipc_monitoring_report_pool_status.rs
📜 Recent review details
⏰ Context from checks skipped due to timeout. (21)
  • GitHub Check: FR reference in PR body
  • GitHub Check: semgrep-cloud-platform/scan
  • GitHub Check: Rust
  • GitHub Check: Unit Tests
  • GitHub Check: test
  • GitHub Check: cargo bench (soft)
  • GitHub Check: Reproducible build (L52)
  • GitHub Check: cargo bench (gate)
  • GitHub Check: dashboard keyboard Tab-cycle
  • GitHub Check: hyperfine healthz (soft)
  • GitHub Check: linux_native (ubuntu-24.04)
  • GitHub Check: windows_winfsp (windows-latest)
  • GitHub Check: healthz soak (soft)
  • GitHub Check: dashboard PNG hard diff
  • GitHub Check: live pool probe (soft)
  • GitHub Check: coverage
  • GitHub Check: healthz load burst (soft)
  • GitHub Check: Offline check after fetch (soft)
  • GitHub Check: Kilo Code Review
  • GitHub Check: Summary
  • GitHub Check: windows_winfsp (windows-latest)
⚠️ CI failures not shown inline (2)

GitHub Actions: Trunk Check / 0_Lint & Format.txt: fix(ci): repair main required gates - fr007 test compile fixes + pin rust 1.96.0

Conclusion: failure

View job details

##[group]Run cat >>$GITHUB_ENV <<EOF
 �[36;1mcat >>$GITHUB_ENV <<EOF�[0m
 �[36;1mGITHUB_***REDACTED_SECRET_ASSIGNMENT***
 �[36;1mTRUNK_LAUNCHER_QUIET=false�[0m
 �[36;1mEOF�[0m
 �[36;1m�[0m
 �[36;1m# First arg is field to fetch, second arg is default value or empty�[0m
 �[36;1mpayload() {�[0m
 �[36;1m  if [ $# -lt 2 ]; then�[0m
 �[36;1m    DEFAULT_VALUE=empty�[0m
 �[36;1m  else�[0m
 �[36;1m    DEFAULT_VALUE=\"$2\"�[0m
 �[36;1m  fi�[0m
 �[36;1m  if command -v jq >/dev/null; then�[0m
 �[36;1m    jq -r ".inputs.payload | fromjson | .$1 // ${DEFAULT_VALUE}" ${TEST_GITHUB_EVENT_PATH:-${GITHUB_EVENT_PATH}}�[0m
 �[36;1m  else�[0m
 �[36;1m    echo "::error::jq not installed on system!"�[0m

GitHub Actions: Trunk Check / Lint & Format: fix(ci): repair main required gates - fr007 test compile fixes + pin rust 1.96.0

Conclusion: failure

View job details

##[group]Run cat >>$GITHUB_ENV <<EOF
 �[36;1mcat >>$GITHUB_ENV <<EOF�[0m
 �[36;1mGITHUB_***REDACTED_SECRET_ASSIGNMENT***
 �[36;1mTRUNK_LAUNCHER_QUIET=false�[0m
 �[36;1mEOF�[0m
 �[36;1m�[0m
 �[36;1m# First arg is field to fetch, second arg is default value or empty�[0m
 �[36;1mpayload() {�[0m
 �[36;1m  if [ $# -lt 2 ]; then�[0m
 �[36;1m    DEFAULT_VALUE=empty�[0m
 �[36;1m  else�[0m
 �[36;1m    DEFAULT_VALUE=\"$2\"�[0m
 �[36;1m  fi�[0m
 �[36;1m  if command -v jq >/dev/null; then�[0m
 �[36;1m    jq -r ".inputs.payload | fromjson | .$1 // ${DEFAULT_VALUE}" ${TEST_GITHUB_EVENT_PATH:-${GITHUB_EVENT_PATH}}�[0m
 �[36;1m  else�[0m
 �[36;1m    echo "::error::jq not installed on system!"�[0m
🧰 Additional context used
📓 Path-based instructions (4)
**/*

📄 CodeRabbit inference engine (CLAUDE.md)

Use UTF-8 encoding for all text files; do not use Windows-1252 smart quotes or other special characters.

Files:

  • crates/sharecli-fuse/build.rs
  • crates/sharecli-fuse/src/lib.rs
  • rust-toolchain.toml
  • crates/sharecli-fuse/src/bin/mfmount-probe.rs
  • crates/sharecli-fuse/src/backend.rs
  • crates/sharecli-ipc/src/log_buffer.rs
  • crates/sharecli-fuse/src/session_registry.rs
  • tests/c09_l81_stop_force_confirm.rs
  • tests/fr007_ipc_monitoring_report_pool_status.rs
  • crates/sharecli-ipc/src/handler.rs
  • tests/fr007_ipc_monitoring_report_gate_host_watch.rs
**/*.rs

📄 CodeRabbit inference engine (CLAUDE.md)

Use Rust for the project and validate Rust changes with Cargo build, Cargo test, and Cargo clippy.

**/*.rs: This project uses Rust edition 2021; follow Rust conventions and language-appropriate error handling.
Never use unwrap or expect in production Rust code.
Log all errors with structured logging.
Use PascalCase for types, snake_case for functions, methods, and modules, and SCREAMING_SNAKE_CASE for constants.
Process-pool tests must use appropriate platform gates such as #[cfg(unix)] and #[cfg(windows)] where platform behavior differs.

Files:

  • crates/sharecli-fuse/build.rs
  • crates/sharecli-fuse/src/lib.rs
  • crates/sharecli-fuse/src/bin/mfmount-probe.rs
  • crates/sharecli-fuse/src/backend.rs
  • crates/sharecli-ipc/src/log_buffer.rs
  • crates/sharecli-fuse/src/session_registry.rs
  • tests/c09_l81_stop_force_confirm.rs
  • tests/fr007_ipc_monitoring_report_pool_status.rs
  • crates/sharecli-ipc/src/handler.rs
  • tests/fr007_ipc_monitoring_report_gate_host_watch.rs
**/*.{rs,toml}

📄 CodeRabbit inference engine (AGENTS.md)

Keep the project compatible with the pinned stable toolchain defined by rust-toolchain.toml, and ensure code is clean under rustfmt and clippy with warnings denied.

Files:

  • crates/sharecli-fuse/build.rs
  • crates/sharecli-fuse/src/lib.rs
  • rust-toolchain.toml
  • crates/sharecli-fuse/src/bin/mfmount-probe.rs
  • crates/sharecli-fuse/src/backend.rs
  • crates/sharecli-ipc/src/log_buffer.rs
  • crates/sharecli-fuse/src/session_registry.rs
  • tests/c09_l81_stop_force_confirm.rs
  • tests/fr007_ipc_monitoring_report_pool_status.rs
  • crates/sharecli-ipc/src/handler.rs
  • tests/fr007_ipc_monitoring_report_gate_host_watch.rs
tests/**/*.rs

📄 CodeRabbit inference engine (AGENTS.md)

Maintain acceptance and integration tests for the documented functional requirements, including tests/fr001_*.rs and tests/integration_cli.rs.

Files:

  • tests/c09_l81_stop_force_confirm.rs
  • tests/fr007_ipc_monitoring_report_pool_status.rs
  • tests/fr007_ipc_monitoring_report_gate_host_watch.rs
🔇 Additional comments (14)
crates/sharecli-fuse/build.rs (1)

4-6: LGTM!

crates/sharecli-fuse/src/backend.rs (1)

68-72: LGTM!

crates/sharecli-fuse/src/bin/mfmount-probe.rs (2)

52-52: LGTM!


70-72: LGTM!

crates/sharecli-fuse/src/lib.rs (1)

1014-1025: LGTM!

crates/sharecli-fuse/src/session_registry.rs (1)

646-649: LGTM!

crates/sharecli-ipc/src/handler.rs (1)

555-556: LGTM!

crates/sharecli-ipc/src/log_buffer.rs (3)

99-100: LGTM!


191-191: LGTM!


265-265: LGTM!

rust-toolchain.toml (1)

2-2: LGTM!

tests/fr007_ipc_monitoring_report_gate_host_watch.rs (1)

70-70: LGTM!

Also applies to: 106-110

tests/fr007_ipc_monitoring_report_pool_status.rs (1)

70-70: LGTM!

Also applies to: 106-110

tests/c09_l81_stop_force_confirm.rs (1)

59-62: LGTM!


📝 Walkthrough

Summary

This PR repairs the ci / lint and ci / test gates.

  • Updates two FR-007 IPC monitoring fixtures to the current process-entry schema.
  • Removes obsolete ProcState imports.
  • Replaces log_location with thread_count: None.
  • Pins Rust to 1.96.0.
  • Applies formatting updates across 10 files.
  • Preserves runtime behavior in the formatting-only changes.

Must Fix

None identified from the provided changes.

Should Fix

None identified.

Consider

Run cargo fmt --check, cargo clippy --workspace -- -D warnings, and cargo test --workspace in CI to confirm the gate repair.

Approve / Request Changes

Approve.

Walkthrough

The pull request reformats FUSE, IPC, and test code, pins the Rust toolchain to 1.96.0, and updates monitoring-report fixtures to match the current process-entry schema.

Changes

Maintenance updates

Layer / File(s) Summary
FUSE formatting updates
crates/sharecli-fuse/...
Reformats linker directives, version parsing, diagnostics, mount errors, and mount-option assertions without changing behavior.
IPC formatting updates
crates/sharecli-ipc/...
Reformats command-line error handling and log-buffer expressions without changing behavior.
Toolchain and test fixture alignment
rust-toolchain.toml, tests/...
Pins the toolchain to 1.96.0 and updates monitoring fixtures to use string state values and thread_count.
Test assertion formatting
tests/c09_l81_stop_force_confirm.rs
Reformats the existing quit output assertion without changing its condition or failure message.

Estimated code review effort: 2 (Simple) | ~10 minutes

Possibly related PRs

Suggested reviewers: copilot

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Description check ⚠️ Warning The description explains the changes and test plan but omits required Linked Issues, Implementation Notes, Risk & Rollout, and completed testing evidence. Add the missing required sections and provide completed test results, risk and rollout details, rollback plan, and linked issue references.
✅ Passed checks (4 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly identifies the CI gate repair, FR-007 test fixes, and Rust 1.96.0 pinning.
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 💡 1
🛠️ Fix failing CI checks 💡
  • Create stacked PR
  • Commit on current branch
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch fix/ci-gate-main
✨ Simplify code
  • Create PR with simplified code
  • Commit simplified code in branch fix/ci-gate-main

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.

@codeant-ai codeant-ai Bot added the size:M This PR changes 30-99 lines, ignoring generated files label Aug 2, 2026
@sonarqubecloud

sonarqubecloud Bot commented Aug 2, 2026

Copy link
Copy Markdown

@github-actions

github-actions Bot commented Aug 2, 2026

Copy link
Copy Markdown

Quality Gate Report

❌ Unit Tests: FAILED
⏭️ E2E Tests: SKIPPED (no e2e directory)
⏭️ Integration Tests: SKIPPED (no integration directory)
✅ FR Annotations: VALID

@KooshaPari
KooshaPari merged commit 9442846 into main Aug 2, 2026
42 of 62 checks passed
@KooshaPari
KooshaPari deleted the fix/ci-gate-main branch August 2, 2026 20:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size:M This PR changes 30-99 lines, ignoring generated files

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants