problem:
the default program corresponding to the file is not set.
solution:
check if your ~/.local/share/applications/<default-program>.desktop
-file contains the MIME-type of your file. It must contain the MIME-type of your file.
example: mplayer.desktop
with MIME-type containing video/mp4
[Desktop Entry]
Exec=mplayer
MimeType=video/mp4;
Name=mplayer
NoDisplay=true
Type=Application
set the default-program ‘mplayer’ for MIME-type ‘video/mp4’:xdg-mime default mplayer.desktop video/mp4
check the default-program:xdg-mime query default video/mp4