Skip to content

prompted for email on logout #836

Closed
Closed

Description

@zeke
$ heroku update
heroku: Updating CLI from 7.0.15 to 7.0.33... done
heroku: Updating CLI... done

$ heroku logout
heroku: Enter your login credentials
Logging out... ?
Email [****@****.com]:      
Logging out... ?
Password: 
Warning: Cannot read property 'statusCode' of undefined
Logging out... done

Activity

  1. zeke commented on May 8, 2018

    @zeke
    Author
    $ heroku login --sso
    Organization name: github-enterprise
    Opening browser for login... ?
    Access token: ************************************
    Validating token... done
    
    
    $ heroku logout     
    Logging out... ?
    Organization name [github-enterprise]: 
    Opening browser for login... ?
    Access token: 
    Warning: SIGINT
    Opening browser for login... done
    
    
    $ heroku whoami
     ›   Error: not logged in
    
    
    $ heroku login
    heroku: Enter your login credentials
    Email: 
    
  2. jdx commented on May 8, 2018

    @jdx
    Contributor

    apologies for this. There is some really complex logic around logging out existing tokens when logging in that wasn't quite right. The login should still work even though it's erroring out though. I've got a fix ready that should be out in a few minutes

  3. jdx commented on May 8, 2018

    @jdx
    Contributor

    BTW because what this is doing is saving the last used org and login method into the netrc file, if you run heroku logout it will clear that setting and won't remember you used sso the last time.

    I feel this behavior is fine since it still works if you run a command like heroku apps and the sso session is not valid. It will remember the org and method as sso for the next login attempt. It's just if you explicitly call heroku logout that will clear any existing settings.

  4. jdx commented on May 8, 2018

    @jdx
    Contributor

    screen shot 2018-05-08 at 12 50 51 pm

    seems to be working well now
  5. Joble commented on May 8, 2018

    @Joble

    I have upgraded to 7.0.34. heroku logoff actually seems to be acting like logon, and then it's still looping asking for tokens.

  6. Joble commented on May 8, 2018

    @Joble

    $ heroku logout
    Logging out... ?
    Organization name [sfdc-aloha]:
    Opening browser for login... ?
    Access token: ************************************
    Opening browser for login... ?
    Organization name [sfdc-aloha]:
    Opening browser for login... ?
    Access token: ************************************
    Opening browser for login... ?
    Organization name [sfdc-aloha]:

  7. jdx commented on May 8, 2018

    @jdx
    Contributor

    @Joble what method did you install the CLI through?

  8. Joble commented on May 8, 2018

    @Joble

    @jdxcode I had it installed already, but I used brew upgrade heroku once I saw your comments a bit ago.

  9. jdx commented on May 8, 2018

    @jdx
    Contributor

    heroku version is showing 7.0.34 right? I've tested a few scenarios with logout and I'm not sure how this situation is possible. Right now it looks like old code.

  10. Joble commented on May 8, 2018

    @Joble

    @jdxcode I found I had several old versions installed. I used pip to remove all versions with the intent of installing the latest. However, brew install heroku only installs 7.0.30. I've updated brew, so I'm not sure what the issue is.

  11. jdx commented on May 8, 2018

    @jdx
    Contributor

    run heroku update

  12. Joble commented on May 8, 2018

    @Joble

    @jdxcode Thank you!

  13. reopened this on May 8, 2018
  14. zeke commented on May 9, 2018

    @zeke
    Author

    if you run heroku logout it will clear that setting and won't remember you used sso the last time.

    thanks for this. will give it another try.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions