Encountered this problem with a fresh install of Rubymine for Mac, Ruby and Rails and following Roku integration steps in https://www.jetbrains.com/help/ruby/heroku-getting-started.html
I tried deleting directory .local/share/heroku and then heroku update, but does not fix the issue, which occurs both when, say trying to upload public key file, and when trying to deploy application with Heroku run configuration.