Open dkebler opened 5 years ago
I'm guessing it's the nemo action
Exec=<send-by-mail.py %F>
which calls this python script
#!/usr/bin/python3 -OOt
import argparse
from itertools import chain
from subprocess import call
parser = argparse.ArgumentParser()
parser.add_argument('filelist', help='list of absolute paths separated by /#/')
args = parser.parse_args()
command = ['xdg-email'] + list(chain.from_iterable(('--attach', arg) for arg in args.filelist.split('/#/')))
call(command)
It uses xdg-email. Maybe xdg-email is the wrong tool or the command is bad. Is there a better more direct way to invoke gnome-gmail??
from command line seems like attaching a file is creating a parsing error?
this works
gnome-gmail "mailto:?Subject=Hello%20again"
but this gives error
$ gnome-gmail -r "testfiletosend" "mailto:?Subject=Hello%20again"
Traceback (most recent call last):
File "/usr/share/gnome-gmail/gnomegmail.py", line 1005, in <module>
main()
File "/usr/share/gnome-gmail/gnomegmail.py", line 979, in main
from_address = fromFromMessage(message)
File "/usr/share/gnome-gmail/gnomegmail.py", line 714, in fromFromMessage
line = [x for x in message.split('\n') if 'FROM:' in x.upper()][0]
IndexError: list index out of range
Is there a space in the name of the file that failed?
The "-r" option is not intended to be used that way. The attachment becomes part of the mailto:
gnome-mail "mailto:?subject=Hello%20again&attach=testfiletosend"
Either "attach" or "attachment" may be used. I'm not sure right now if a valid, fully formed recipient is required.
As a general rule, I use "xdg-open mailto:...". It would be interesting to know what the "command" is coming out of that script.
Running Linux Mint 19 (Ubuntu 18.04 under hood) with nemo file manager. Installed latest gnome-gmail deb 2.5.6.
Set up as preferred ap. Send as Email nemo action works but
Can't tell the version of the gmail api but I assume it's the latest.
Let me know how to provide you logs or more info that will help track this down. Does your app create it's own nemo action file? Maybe that's the problem?