Outdated depency to deprecated win11 library
@rkusa With the latest Win11 update I get the following error when I use windows as backend:
dcs_grpc::server: Error in TTS transmission from Lua: status: Internal, message: "Calling WinRT API failed with error code -2147024894: Das System kann die angegebene Datei nicht finden.", details: [], metadata: MetadataMap { headers: {} }
Looking where this is created, I see that this is coming from: tts\src\win.rs line 107.
I think it simply means that an expected library cannot be found.
Playing around with RUST builds it seems there are a lot of outdated dependencies, i.e.
Unchanged crypto-mac v0.11.0 (available: v0.11.1) Unchanged mlua v0.9.9 (available: v0.10.5) Unchanged prost v0.12.6 (available: v0.13.5) Unchanged prost-types v0.12.6 (available: v0.13.5) Unchanged thiserror v1.0.69 (available: v2.0.12) Unchanged tonic v0.11.0 (available: v0.13.1) Unchanged tonic-build v0.11.0 (available: v0.13.1) Unchanged tonic-middleware v0.1.4 (available: v0.3.0) Unchanged windows v0.56.0 (available: v0.61.1)
Where I guess the last one is the culprit, as described in the Cargo.toml for tts:
[target.'cfg(target_os = "windows")'.dependencies.windows] version = "0.56" features = [ "Foundation", "Foundation_Collections", "Storage_Streams", "Media_SpeechSynthesis", ]
Changing that to say 0.61.1 fails to compile the server, bc the method doesn't exist any more
Compiling dcs-grpc-tts v0.8.1 (E:\Projects\rust-server\tts) error[E0599]: no method namedSynthesizeSsmlToStreamAsyncfound for structSpeechSynthesizerin the current scope --> tts\src\win.rs:88:10 | 87 | let stream = synth | __________________- 88 | | .SynthesizeSsmlToStreamAsync(&HSTRING::from(&format!( | | -^^^^^^^^^^^^^^^^^^^^^^^^^^^ method not found inSpeechSynthesizer`
| |_________|
|
error[E0277]: windows_future::bindings::IAsyncOperation<u32> is not a future
--> tts\src\win.rs:95:32
|
95 | rd.LoadAsync(size as u32)?.await?;
| -^^^^^
| ||
| |windows_future::bindings::IAsyncOperation<u32> is not a future
| help: remove the .await
|
= help: the trait Future is not implemented for windows_future::bindings::IAsyncOperation<u32>
= note: windows_future::bindings::IAsyncOperationIntoFuture to be awaited
= note: required for windows_future::bindings::IAsyncOperation<u32> to implement IntoFuture `
Personally I have no clue about Rust and what updates are needed, is this something that you or your colleague can tackle pls? Appreciated!
gRPC Angels,
With also my eternal thanks for what you've created, I arrive with a THIRST for this solution, also!
I am building a massive script VERY much dependent on this awesome tech to get our AI voices working (there are many like it but this one is mine) and we've been enthralled - absolutely ecstatic -that you've brought this to the world.
However, I am brainwreaked and get about 2 days a month with any capacity, so about a year into getting this wonderful system working (DCS, GRPC, SRS, MOOSE and More!) I am emotionally destroyed at this suddenly being broken again!
Blame and spite to Windows - not you lot! <3
And of course this enormous script I'm on (to get my brain back together) is once again stuck in the mud, PITIFULLY on this same issue: Making Gold out of Lead! (you peeps amaze me).
I just wanted to be here to press my support for this request. I need my work back :o
Gladly I didn't sit in silence, bricking my head on this: We have a few lads here scratching their heads on this one! Phew! <3 Applevangelist and Ciribob and the rest have been amazingly accessible and ready to hear issues and tackle them. They were able to stay my horses and pinpoint the issue. Thankful for those that can be wiser, and hold a hand before you sink.
Again, just pressing mad support for a fix, and mad respect to all the devs!
ANYTHING I can do (constant or 3rdParty testing?) let me know.
Eagerly standing by for the win.
Carry on!
@Applevangelist can you check if the steps described in the response of the following thread fix it? https://learn.microsoft.com/en-au/answers/questions/230849/windows-media-speechsynthesis-speechsynthesizer-co ?
In particular:
- Find your language in Language (Settings > Time & Language), click Options, click Download button under Speech to enable the Speech feature for the language.
- Open Speech (Settings > Time & Language), click Add voices under Manage voices, select needed language to Add.
Edit: should probably be installed for English (seeing that your OS is German)
@rkusa Yes that is installed and enabled, and yes it worked prior without issues.
Thanks for confirming, I'll try to reproduce it on my W11 installation and get back to you.
I am afraid that I cannot reproduce the issue. My W11 installation is up to date, except for the following preview update:
Is this the update that broke it for you?
I went ahead and updated all dependencies anyway (#281; already merged into main).
Danke Marcus, sehr nett! Ich teste morgen und gebe Bescheid
Thanks Marcus. Compiles locally well, but doesn't even run:
Line 590: 2025-06-09 09:25:08.932 INFO [GRPC-Hook] (Main): Initializing ...
Line 591: 2025-06-09 09:25:08.932 INFO [GRPC-Hook] (Main): Checking optional config at `Config/dcs-grpc.lua` ...
Line 592: 2025-06-09 09:25:08.932 INFO [GRPC-Hook] (Main): `Config/dcs-grpc.lua` successfully read
Line 593: 2025-06-09 09:25:08.932 INFO [GRPC-Hook] (Main): Initialized ...
Line 594: 2025-06-09 09:25:08.932 INFO APP (Main): Loaded C:\Users\post\Saved Games\DCS\Scripts\Hooks\DCS-gRPC.lua
Line 909: 2025-06-09 09:27:00.455 INFO SCRIPTING (Main): [GRPC] Checking optional config at `Config/dcs-grpc.lua` ...
Line 910: 2025-06-09 09:27:00.456 INFO SCRIPTING (Main): [GRPC] `Config/dcs-grpc.lua` successfully read
Line 911: 2025-06-09 09:27:00.573 ERROR Lua::Config (Main): load error Scripts/MissionScripting.lua:error loading module 'dcs_grpc' from file 'C:\Users\post\Saved Games\DCS\Mods\tech\DCS-gRPC\dcs_grpc.dll':
Line 1199: 2025-06-09 09:27:10.542 INFO [GRPC-Hook] (Main): mission loaded, setting up gRPC listener ...
Line 1200: 2025-06-09 09:27:10.543 ERROR [GRPC-Hook] (Main): Failed to set up gRPC listener: error loading module 'dcs_grpc' from file 'C:\Users\post\Saved Games\DCS\Mods\tech\DCS-gRPC\dcs_grpc.dll':
Die angegebene Prozedur wurde nicht gefunden.
Addendum: It's working if I build it without the hot-reload feature with cargo build -r
Your dll doesn't work for me either. No idea why. I've attached a dll compiled from main that works for me.
As said compiled without hotreload it works no issues
Looks like I didn't read all of your comment. Does this also fix the W11 TTS for you?
Yes it does :)