Open do5tj80 opened 8 months ago
Same here with 4.0.0 and 4.0.1 - they don't work But issues in 3.0.5, too:
`
sayit.0 | 2024-06-07 19:42:50.903 | error | Cannot play file: Error: Cannot upload file "tts.userfiles/Doorbell.mp3" to state: Error: ENOENT: no such file or directory, open 'tts.userfiles/Doorbell.mp3' |
---|---|---|---|
sayit.0 | 2024-06-07 19:42:50.898 | error | Cannot write file: TypeError [ERR_INVALID_ARG_TYPE]: The "data" argument must be of type string or an instance of Buffer, TypedArray, or DataView. Received an instance of Object |
sayit.0 | 2024-06-07 19:42:48.896 | error | Cannot write file: TypeError [ERR_INVALID_ARG_TYPE]: The "data" argument must be of type string or an instance of Buffer, TypedArray, or DataView. Received an instance of Object |
host.lue-linux | 2024-06-07 19:42:39.467 | warn | instance system.adapter.sayit.0 terminated due to SIGABRT |
host.lue-linux | 2024-06-07 19:42:39.467 | error | Caught by controller[0]: 6: MDNSService.self.watcher.callback (/opt/iobroker/node_modules/mdns/lib/mdns_service.js:18:40) |
host.lue-linux | 2024-06-07 19:42:39.467 | error | Caught by controller[0]: 5: on_resolver_done (/opt/iobroker/node_modules/mdns/lib/resolver_sequence_tasks.js:33:11) |
host.lue-linux | 2024-06-07 19:42:39.467 | error | Caught by controller[0]: 4: next (/opt/iobroker/node_modules/mdns/lib/browser.js:109:21) |
host.lue-linux | 2024-06-07 19:42:39.467 | error | Caught by controller[0]: 3: getaddrinfo (/opt/iobroker/node_modules/mdns/lib/resolver_sequence_tasks.js:152:14) |
host.lue-linux | 2024-06-07 19:42:39.466 | error | Caught by controller[0]: 2: /opt/iobroker/node_modules/mdns/lib/resolver_sequence_tasks.js:153:7 |
host.lue-linux | 2024-06-07 19:42:39.466 | error | Caught by controller[0]: 1: getaddrinfo_0_11 (/opt/iobroker/node_modules/mdns/lib/resolver_sequence_tasks.js:117:21) |
host.lue-linux | 2024-06-07 19:42:39.466 | error | Caught by controller[0]: ----- JavaScript stack trace ----- |
host.lue-linux | 2024-06-07 19:42:39.466 | error | Caught by controller[0]: 6: 0x1963df6 [io.sayit.0] |
host.lue-linux | 2024-06-07 19:42:39.466 | error | Caught by controller[0]: 5: 0xf58be5 v8::internal::Builtin_HandleApiCall(int, unsigned long, v8::internal::Isolate) [io.sayit.0] |
host.lue-linux | 2024-06-07 19:42:39.466 | error | Caught by controller[0]: 4: 0xf5871d [io.sayit.0] |
host.lue-linux | 2024-06-07 19:42:39.466 | error | Caught by controller[0]: 3: 0xf57eaf v8::internal::FunctionCallbackArguments::Call(v8::internal::CallHandlerInfo) [io.sayit.0] |
host.lue-linux | 2024-06-07 19:42:39.466 | error | Caught by controller[0]: 2: 0xbe98aa [io.sayit.0] |
host.lue-linux | 2024-06-07 19:42:39.466 | error | Caught by controller[0]: 1: 0xcbc127 node::Assert(node::AssertionInfo const&) [io.sayit.0] |
host.lue-linux | 2024-06-07 19:42:39.466 | error | Caught by controller[0]: ----- Native stack trace ----- |
host.lue-linux | 2024-06-07 19:42:39.466 | error | Caught by controller[0]: # Assertion failed: args[4]->IsUint32() |
host.lue-linux | 2024-06-07 19:42:39.466 | error | Caught by controller[0]: # io.sayit.0[7765]: void node::cares_wrap::{anonymous}::GetAddrInfo(const v8::FunctionCallbackInfo |
host.lue-linux | 2024-06-07 19:42:39.466 | error | Caught by controller[0]: WARNING For more information see http://0pointer.de/blog/projects/avahi-compat.html |
host.lue-linux | 2024-06-07 19:42:39.466 | error | Caught by controller[0]: WARNING Please fix your application to use the native API of Avahi! |
host.lue-linux | 2024-06-07 19:42:39.465 | error | Caught by controller[0]: WARNING The program 'node' called 'DNSServiceRegister()' which is not supported (or only supported partially) in the Apple Bonjour compatibility layer of Avahi. |
host.lue-linux | 2024-06-07 19:42:39.465 | error | Caught by controller[0]: WARNING For more information see http://0pointer.de/blog/projects/avahi-compat.html |
host.lue-linux | 2024-06-07 19:42:39.465 | error | Caught by controller[0]: WARNING Please fix your application to use the native API of Avahi! |
host.lue-linux | 2024-06-07 19:42:39.465 | error | Caught by controller[0]: WARNING The program 'node' uses the Apple Bonjour compatibility layer of Avahi. |
`
Cannot reproduce it. Can you test it with v4.0.2?
With 4.04 it works now THX! But I'm still not able to play mp3s. Code:
Cannot play file: Error: Cannot upload file "/opt/iobroker/iobroker-data/files/sayit.0/tts.userfiles/Gong.mp3" to state: Error: ENOENT: no such file or directory, open '/opt/iobroker/iobroker-data/files/sayit.0/tts.userfiles/Gong.mp3'
And error commented in 1st post from do5tj80 here still exists.
But I'll try and test it again later.
Cannot upload file
What is your code/blockly to play the file?
Issues only with mp3.
Testet with a)
sendTo("sayit.0", "say", { text: '/opt/iobroker/iobroker-data/files/sayit.0/tts.userfiles/Gong.mp3' })
b)
setState('sayit.0.tts.text' /* Text to speech */, '/opt/iobroker/iobroker-data/files/sayit.0/tts.userfiles/Gong.mp3')
c)
Set Value in "Objects" manually
a) and b) both set value in "objects" correctly
Only Text --> no problem
This Popup appears in the Adapter Settings, if I try to play a custom sound:
Cannot play: EncodingError: Failed to execute 'decodeAudioData' on 'BaseAudioContext': Unable to decode audio data
sayit.0/tts.userfiles/Gong.mp3
What Type do you have?
Browser with vis-2.0
/opt/iobroker/iobroker-data/files/sayit.0/tts.userfiles/Gong.mp3
It is not suggested to access state files from disk: /opt/iobroker/iobroker-data/files/sayit.0/tts.userfiles/Gong.mp3
But as far as I know the file name should be gong.mp3
and not Gong.mp3
.
I added the possibility to play files directly from states: sayit.0/tts.userfiles/gong.mp3
in 4.1.0
Now it works! I set the path to play directly from the state. Thank you for your support and your great job!
sayit cannot upload announcement file
To Reproduce
Steps to reproduce the behavior:
Versions:
Log: sayit.0 | 2023-12-27 11:11:01.126 | error | Cannot write file: TypeError [ERR_INVALID_ARG_TYPE]: The "data" argument must be of type string or an instance of Buffer, TypedArray, or DataView. Received an instance of Object
sayit.0 | 2023-12-27 11:11:01.126 | error | Cannot play file: Error: Cannot upload file "tts.userfiles/scifi.mp3" to state: Error: ENOENT: no such file or directory, open 'tts.userfiles/scifi.mp3'