-
-
Notifications
You must be signed in to change notification settings - Fork 101
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Does not start in terminal linux (without windows) #11
Comments
Similar use case here: I use an imap command line mail client with gmail, but gmail is disabling "traditional" authorisation, so I need to switch to oauth2. I realise I need to open a browser window to make the initial setup, but once that's done, my use cases are ALL on headless / no windows servers. I'm also wanting code without any GUI dependency, so I'll try your suggestion above. Cheers. |
Thanks for reporting this. The There are two options here, then:
Please could you try the environment variable option and let me know whether it works? |
With environment variable doesn't work. Traceback (most recent call last): During handling of the above exception, another exception occurred: Traceback (most recent call last): dummy is not a valid option, In my case it works by removing the import pystray and the class RetinaIcon I have been working separating the RetinaIcon class in a new file and importing it only if it runs in GUI mode |
Can you let me know which version of pystray you have? It looks like a change in how this environment variable is handled has broken the dummy backend. I still think this would be a better approach than refactoring the proxy, however. So, if you force version 0.18.0 of pystray ( |
with version 0.18.0 and In my case with 0.19.2 it didn't work for me |
Note: this workaround was correct at the time of writing, but is no-longer required now that the proxy has full support for headless operation via a separate non-GUI dependencies file. Instead, install the script's requirements via Excellent - it looks like the dummy backend is the best way forward, and the second issue you encountered is a bug in pystray For the benefit of others, the solution to run the proxy with no GUI dependencies (and no need to edit the proxy script) is:
Also – just to be clear: while this usage of the proxy will work, it has no way of requesting reauthorisation directly in this mode, so you will either need to monitor for log messages about authentication failures, or use the new |
Also force pystray 0.19.4 or later to make addressing #11 easier
The application does not start in linux terminal mode even with the --no-gui option, example a vps.
The idea is to run the app on a windows system to generate the token, then copy the config file to a linux terminal
I managed to get it working by removing the import pystray and the RetinaIcon class
As a suggestion, an option could be added to request a token in CLI as in the example:
https://github.com/google/gmail-oauth2-tools/tree/master/python
Using the url in a browser with generates an authorization code that is pasted to authorize and generate token
The text was updated successfully, but these errors were encountered: