Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions src/openhuman/voice/dictation_listener.rs
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,11 @@ use tokio::sync::broadcast;
use tokio::task::JoinHandle;

use crate::openhuman::config::Config;
// Only `start_rdev_listener` (non-macOS) touches the hotkey module — its
// `ActivationMode`, `HotkeyEvent`, and `parse_hotkey`/`start_listener` fns — so
// gate the import to the same cfg to avoid unused-import warnings on macOS.
#[cfg(not(target_os = "macos"))]
use crate::openhuman::voice::hotkey::{self, ActivationMode, HotkeyEvent};

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Duplicate of #4736 — one should be closed. This import is functionally identical to the one added by PR #4736; the only difference is spelling: here it's use crate::openhuman::voice::hotkey::{self, ActivationMode, HotkeyEvent};, in #4736 it's use super::hotkey::{...}. Both resolve to the same module and both carry the same #[cfg(not(target_os = "macos"))] gate, so exactly one of these PRs should land and the other be closed. Two points favor this PR as the canonical one: it was opened first (08:42Z vs 11:42Z), and the crate::… spelling matches the adjacent use crate::openhuman::config::Config; on line 15. Otherwise the fix is correct — every reference to these symbols (lines 140–182) lives inside the non-macOS start_rdev_listener, so the cfg gate matches usage exactly. Maintainer call.


const LOG_PREFIX: &str = "[dictation_listener]";

Expand Down
Loading