locomotivecms / wagon

Wagon is a command line tool that let's you develop for Locomotive right on your local machine.
https://www.locomotivecms.com
MIT License
188 stars 117 forks source link

Unable to wagon auth #399

Open r-obeen opened 3 years ago

r-obeen commented 3 years ago

Hello, I'm struggling with linking wagon to remote locomotive cms.

Locomotivecms server : heroku Ruby version : 2.6.7

Error I'm getting when I run wagon auth :

Enter the URL of your platform? (default: https://station.locomotive.works) https://web.tourcrib.com
Enter your e-mail? simeon.robeen@gmail.com
Enter your password? Traceback (most recent call last):
    24: from /Users/robeen/.rvm/gems/ruby-2.6.6/bin/ruby_executable_hooks:24:in `<main>'
    23: from /Users/robeen/.rvm/gems/ruby-2.6.6/bin/ruby_executable_hooks:24:in `eval'
    22: from /Users/robeen/.rvm/gems/ruby-2.6.6/bin/wagon:23:in `<main>'
    21: from /Users/robeen/.rvm/gems/ruby-2.6.6/bin/wagon:23:in `load'
    20: from /Users/robeen/.rvm/gems/ruby-2.6.6/gems/locomotivecms_wagon-3.0.5/bin/wagon:73:in `<top (required)>'
    19: from /Users/robeen/.rvm/gems/ruby-2.6.6/gems/thor-0.20.3/lib/thor/base.rb:466:in `start'
    18: from /Users/robeen/.rvm/gems/ruby-2.6.6/gems/thor-0.20.3/lib/thor.rb:387:in `dispatch'
    17: from /Users/robeen/.rvm/gems/ruby-2.6.6/gems/thor-0.20.3/lib/thor/invocation.rb:126:in `invoke_command'
    16: from /Users/robeen/.rvm/gems/ruby-2.6.6/gems/thor-0.20.3/lib/thor/command.rb:27:in `run'
    15: from /Users/robeen/.rvm/gems/ruby-2.6.6/gems/locomotivecms_wagon-3.0.5/lib/locomotive/wagon/cli.rb:234:in `auth'
    14: from /Users/robeen/.rvm/gems/ruby-2.6.6/gems/locomotivecms_wagon-3.0.5/lib/locomotive/wagon.rb:19:in `authenticate'
    13: from /Users/robeen/.rvm/gems/ruby-2.6.6/gems/locomotivecms_wagon-3.0.5/lib/locomotive/wagon/commands/authenticate_command.rb:12:in `authenticate'
    12: from /Users/robeen/.rvm/gems/ruby-2.6.6/gems/locomotivecms_wagon-3.0.5/lib/locomotive/wagon/commands/authenticate_command.rb:16:in `authenticate'
    11: from /Users/robeen/.rvm/gems/ruby-2.6.6/gems/locomotivecms_wagon-3.0.5/lib/locomotive/wagon/commands/authenticate_command.rb:26:in `fetch_api_key'
    10: from /Users/robeen/.rvm/gems/ruby-2.6.6/gems/locomotivecms_wagon-3.0.5/lib/locomotive/wagon/commands/authenticate_command.rb:58:in `my_account'
     9: from /Users/robeen/.rvm/gems/ruby-2.6.6/gems/locomotivecms_coal-1.6.0/lib/locomotive/coal/resources/my_account.rb:9:in `get'
     8: from /Users/robeen/.rvm/gems/ruby-2.6.6/gems/locomotivecms_coal-1.6.0/lib/locomotive/coal/resources/concerns/request.rb:7:in `get'
     7: from /Users/robeen/.rvm/gems/ruby-2.6.6/gems/locomotivecms_coal-1.6.0/lib/locomotive/coal/resources/concerns/request.rb:27:in `do_request'
     6: from /Users/robeen/.rvm/gems/ruby-2.6.6/gems/locomotivecms_coal-1.6.0/lib/locomotive/coal/resources/concerns/request.rb:69:in `_do_request'
     5: from /Users/robeen/.rvm/gems/ruby-2.6.6/gems/locomotivecms_coal-1.6.0/lib/locomotive/coal/resources/concerns/request.rb:111:in `_token'
     4: from /Users/robeen/.rvm/gems/ruby-2.6.6/gems/locomotivecms_coal-1.6.0/lib/locomotive/coal/client.rb:100:in `block in connection'
     3: from /Users/robeen/.rvm/gems/ruby-2.6.6/gems/locomotivecms_coal-1.6.0/lib/locomotive/coal/client.rb:17:in `token'
     2: from /Users/robeen/.rvm/gems/ruby-2.6.6/gems/locomotivecms_coal-1.6.0/lib/locomotive/coal/resources/token.rb:9:in `get'
     1: from /Users/robeen/.rvm/gems/ruby-2.6.6/gems/locomotivecms_coal-1.6.0/lib/locomotive/coal/resources/concerns/request.rb:11:in `post'
/Users/robeen/.rvm/gems/ruby-2.6.6/gems/locomotivecms_coal-1.6.0/lib/locomotive/coal/resources/concerns/request.rb:54:in `do_request': Internal Server Error (Locomotive::Coal::ServerSideError)

Any idea what the issue is ?

r-obeen commented 3 years ago

Found the issue... It was related to rack.

Solution : add this to Gemfile gem 'rack', '2.0.8'