[neomutt-users] mutt_oauth2.py

Andrew Sullivan ajs at anvilwalrusden.com
Thu Aug 4 22:43:11 CEST 2022


Hi there,

Is anyone here using mutt_oauth2.py with O365?

I've had a strange problem where I edit the script with the various settings that need changing (gpg key, client_id, &c. &c.) but, unless they're specified on the command line, they don't get picked up.  This perplexed me when I first went to authorize, but I managed to get it working by specifying everything as command line arguments.  But now the same problem emerges when trying to refresh.

So, for instance, I edited mutt_oauth2.py to say this:

         'client_id': 'ACTUAL ID HERE',
         'client_secret': 'ACTUAL SECRET HERE',

but

$ ./mutt_oauth2.py --verbose --test ./oauth/sullivan at isoc.org.tokens 
NOTICE: Invalid or expired access token; using refresh token to obtain new access token.
Traceback (most recent call last):
   File "/Users/andrew/.mutt/./mutt_oauth2.py", line 365, in <module>
     update_tokens(response)
   File "/Users/andrew/.mutt/./mutt_oauth2.py", line 189, in update_tokens
     writetokenfile()
   File "/Users/andrew/.mutt/./mutt_oauth2.py", line 141, in writetokenfile
     sub2 = subprocess.run(ENCRYPTION_PIPE, check=True, input=json.dumps(token).encode(),
   File "/opt/homebrew/Cellar/python at 3.9/3.9.13_1/Frameworks/Python.framework/Versions/3.9/lib/python3.9/subprocess.py", line 505, in run
     with Popen(*popenargs, **kwargs) as process:
   File "/opt/homebrew/Cellar/python at 3.9/3.9.13_1/Frameworks/Python.framework/Versions/3.9/lib/python3.9/subprocess.py", line 951, in __init__
     self._execute_child(args, executable, preexec_fn, close_fds,
   File "/opt/homebrew/Cellar/python at 3.9/3.9.13_1/Frameworks/Python.framework/Versions/3.9/lib/python3.9/subprocess.py", line 1680, in _execute_child
     args = list(args)
TypeError: 'NoneType' object is not iterable

Anyone have a clue-stick?

Thanks,

A

-- 
Andrew Sullivan
ajs at anvilwalrusden.com


More information about the neomutt-users mailing list