dsnote icon indicating copy to clipboard operation
dsnote copied to clipboard

"couldn't import. The file does not contain audio or subtitles" - error

Open ilippert opened this issue 2 months ago • 6 comments

On version 4.8.3 since a few weeks, on multiple Fedora 42 machines, I cannot open any audio files, ogg, wav, mp3. Even if I "repair" – re-encode – the audio files, they cannot be read anymore. The listening still works. if you ask me questions, I am happy to do my best to provide answers (as a non programmer).

however, on various devices I can listen to the audio.

ilippert avatar Oct 24 '25 14:10 ilippert

Hi. Thanks for reporting.

To view more logs, run in the terminal with --verbose option and try to reproduce the problem.

flatpak run net.mkiol.SpeechNote --verbose

mkiol avatar Oct 25 '25 17:10 mkiol

I can easily reproduce the problem.

D] 16:45:46.603278785.603 0x7f0f67752d00 () - opening file: "/home/x/2025-6/2025_10_21_09_02_24.ogg" -1
[D] 16:45:46.603308522.603 0x7f0f67752d00 init_av_in_format:594 - opening file: /home/x/2025_10_21_09_02_24.ogg
[E] 16:45:46.604202152.604 0x7f0f67752d00 init_av_in_format:599 - avformat_open_input error: No such file or directory
[D] 16:45:46.604223091.604 0x7f0f67752d00 media_info:1285 - can't get media info: avformat_open_input error
[W] 16:45:46.604241339.604 0x7f0f67752d00 () - failed to open file for read: "/home/x/2025_10_21_09_02_24.ogg"
[W] 16:45:46.604706543.604 0x7f0f67752d00 () - can't open text file
[D] 16:45:46.604715562.604 0x7f0f67752d00 () - import file result: error-no-supported-streams
[D] 16:45:51.172119944.172 0x7f0f67752d00 exit_program:59 - exiting

Does this help to guide me towards a next step?

ilippert avatar Oct 26 '25 16:10 ilippert

How are you trying to open this file?

  • "File->Import from a file"
  • drag&drop,
  • click on file?

Most likely, Speech Note does not have permissions for the directory. Without extra permissions, only "File->Import from a file" should work correctly because the file is exposed to "Flatpak sandbox" via so called Portal. For other methods, you need to grand permissions, for instance using FlatSeal app.

Image

mkiol avatar Oct 27 '25 20:10 mkiol

I was able to find a key difference in behaviour: if the file to be opened is at /home/user I can easily open and process it. If, however, the file sits in a location that is symlinked, than speechnote cannot access it.

yes, it was "File->Import from a file"

ilippert avatar Nov 07 '25 18:11 ilippert

Yes, it looks like a permissions issue. Is the symlink's target file also located somewhere under /home/user? I'm not entirely sure how Flatpak handles symlinks, but I suspect that Flatpak sandbox must also have permission to symlink's target file (or target directory), not just symlink.

Have you tried granting more broad permissions with FlatSeal?

mkiol avatar Nov 08 '25 14:11 mkiol

Thanks a lot!

Have you tried granting more broad permissions with FlatSeal?

yes, like shown in https://github.com/mkiol/dsnote/issues/335#issuecomment-3453205678 I allowed home access. The error still happens in case of accessing files under /home/user/symlink/.../targetfile

Cheers

ilippert avatar Nov 08 '25 15:11 ilippert