Can't login to heroku anymore

隐身守侯 提交于 2020-01-07 03:52:13

问题


I am not sure what exactly happened. I had to switch accounts, so logged out of one account to login to another-

heroku auth:login

These are my terminal commands-

hello@world:~/$ heroku auth:login
Error reading plugin: heroku-git. See /home/helloworld/.heroku/error.log for more information.
Enter your Heroku credentials.
Email: zzzzzzz@gmail.com
Password (typing will be hidden): 
 ▸    Post https://api.heroku.com/oauth/authorizations: dial tcp: lookup api.heroku.com on 127.0.1.1:53: cannot unmarshal DNS message

Here is the content of error.log file-

2015/12/30 20:31:06 Email: 
2015/12/30 20:31:38 [31m ▸    [39mPost https://api.heroku.com/oauth/authorizations: dial tcp: lookup api.heroku.com on 127.0.1.1:53: cannot unmarshal DNS message
2015/12/30 20:31:43 Error reading plugin: heroku-git. See /home/bozzmob/.heroku/error.log for more information.
2015/12/30 20:31:43 exit status 1 
 /home/bozzmob/.heroku/node_modules/heroku-git/node_modules/heroku-cli-util/lib/styled.js:39
      return Object.keys(obj).map(k => k + ': ' + util.inspect(obj[k])).join('
                                    ^^
SyntaxError: Unexpected token =>
    at exports.runInThisContext (vm.js:53:16)
    at Module._compile (module.js:413:25)
    at Object.Module._extensions..js (module.js:448:10)
    at Module.load (module.js:355:32)
    at Function.Module._load (module.js:310:12)
    at Module.require (module.js:365:17)
    at require (module.js:384:17)
    at Object.<anonymous> (/home/bozzmob/.heroku/node_modules/heroku-git/node_modules/heroku-cli-util/index.js:5:15)
    at Module._compile (module.js:430:26)
    at Object.Module._extensions..js (module.js:448:10)

2015/12/30 20:31:43 Email: 
2015/12/30 20:32:04 [31m ▸    [39mPost https://api.heroku.com/oauth/authorizations: dial tcp: lookup api.heroku.com on 127.0.1.1:53: cannot unmarshal DNS message

Please tell me what has gone wrong and how do I fix it.

I have also referred to heroku forums and "Similar Stackoverflow question". Both don't have solution.


回答1:


I resolved this problem by un-installing the current Heroku Toolbelt and re-installing it.

First Uninstalled-

sudo apt-get --purge remove heroku-toolbelt

Then, installed-

wget -qO- https://toolbelt.heroku.com/install-ubuntu.sh | sh


来源:https://stackoverflow.com/questions/34534594/cant-login-to-heroku-anymore

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!