Open sureshbabu-nair opened 1 year ago
Thanks a lot for reporting this issue.
Can you please try the following steps from the MacOS Ventura device?
sourcery --verify
from the command line.Do these work?
Hi Reka,
As per your instructions, I did the following
2 Run sourcery --verify from the command line. suresh$ sourcery --verify sourcery, version 1.6.0
Verifying user config /Users/suresh/.config/sourcery/sourcery.yaml - success Verifying server availability https://api.sourcery.ai/health - success Verifying refactoring functionality - success Verifying local database - success
Thanks so much for the verifying steps. :+1:
It seems that you can basically reach Sourcery, but the login doesn't work. :thinking:
Log Files
Can you please send us your sourcery.log
file from the MacOS Ventura work device?
It should be located at ~/Library/Application Support/sourcery/sourcery.log
You can send them in email to support@sourcery.ai
Firewall Is it possible that your MacOS Ventura work device has a firewall set up? If yes, please try running Sourcery using a proxy. You can find information about the Proxy Configuration in the docs: https://docs.sourcery.ai/Reference/Configuration/Proxy/
Hi Reka,
The answer to your second question is that I already tested using proxy server. I ran a unsecured squid proxy on my personal device, configured the proxy settings for sourcery and still I got the same errors,
when I used the token: Sourcery requires a token. Visit our website to get yours free
when I used the plan login command (redirected via my browser): Failed to fetch token: {"error":{"message":"You did not provide authentication. You need to provide the Authorization header, using Bearer auth (e.g. 'Authorization: Bearer YOUR_SECRET_KEY').","type":"unauthorized"}}
I will send the sourcery.log soon.
Checklist
Description
I have been trying to use sourcery on my office laptop (MacOS Ventura) without much success, but I am able to login from my personal devices. I am tried using both the web-browser code method as well as using the token, I am not sure whats preventing my access.
I am getting this error from the command line
suresh$ sourcery login --token user_orEywFeB0It1ynbQelvlZ_JUe7z1W9AjXRJsvwY3ftD_wCaolyWo3WsUJLc Sourcery requires a token. Visit our website to get yours free Failed to log in, please try again.
suresh$ sourcery login Your browser will be opened to visit: https://auth.sourcery.ai/activate?user_code=JXHR-CHWB
Ensure that the following code is displayed: JXHR-CHWB
Failed to fetch token: {"error":{"message":"You did not provide authentication. You need to provide the Authorization header, using Bearer auth (e.g. 'Authorization: Bearer YOUR_SECRET_KEY').","type":"unauthorized"}} Failed to log in, please try again.
I am having similar errors from Pycharm and vscode. But when I used my personal devices (Windows 10 & MacOS Catalina), I am able to login without a problem with both the methods, token & web browser on IDEs as well as commandline.
I even tried to use one of my personal device as a proxy, in case, if there was a firewall issues on my Office Laptop
Code snippet that reproduces issue
Debug Information
IDE Version: PyCharm Community Edition 2023.1.4 , VS Code (Version: 1.80.1) as well as Python Module, sourcery (1.6.0)
Sourcery Version: v1.6.0
Operating system and Version: MacOS Ventura 13.4.1