Skip to content

YC (S26) | Open Computer History | Continuously record your company computer work, map your workflows, help you find work worth automating, and power your agents' context

fix app build

Louis Beaumontfac2066e46a1
diff --git a/examples/apps/screenpipe-app-tauri/src-tauri/Cargo.toml b/examples/apps/screenpipe-app-tauri/src-tauri/Cargo.toml
index ceb5179fe..86d6570ca 100644
--- a/examples/apps/screenpipe-app-tauri/src-tauri/Cargo.toml
+++ b/examples/apps/screenpipe-app-tauri/src-tauri/Cargo.toml
@@ -1,6 +1,6 @@
[package]
name = "screenpipe-app"
-version = "0.1.78"
+version = "0.1.79"
description = ""
authors = ["you"]
license = ""
diff --git a/screenpipe-audio/src/stt.rs b/screenpipe-audio/src/stt.rs
index 16c25d3da..a28567d11 100644
--- a/screenpipe-audio/src/stt.rs
+++ b/screenpipe-audio/src/stt.rs
@@ -8,6 +8,8 @@ use candle::{Device, IndexOp, Tensor};
use candle_nn::{ops::softmax, VarBuilder};
use hf_hub::{api::sync::Api, Repo, RepoType};
use log::{debug, error, info};
+#[cfg(target_os = "macos")]
+use objc::rc::autoreleasepool;
use rand::{distributions::Distribution, SeedableRng};
use tokenizers::Tokenizer;
use tokio::sync::mpsc::{unbounded_channel, UnboundedReceiver, UnboundedSender};
@@ -753,9 +755,6 @@ pub async fn create_whisper_channel(
.expect("Time went backwards")
.as_secs();
- #[cfg(target_os = "macos")]
- use objc::{rc::autoreleasepool};
-
let transcription_result = if cfg!(target_os = "macos") {
#[cfg(target_os = "macos")]
{
@@ -779,6 +778,11 @@ pub async fn create_whisper_channel(
}
})
}
+ #[cfg(not(target_os = "macos"))]
+ {
+ // This will be used for non-macOS platforms when compiling for macOS
+ unreachable!("This code should not be reached on non-macOS platforms")
+ }
} else {
match stt(&input.path, &whisper_model, audio_transcription_engine.clone()) {
Ok(transcription) => TranscriptionResult {