All threads / Jumpstart App get's stucked with wrong login data

Ask A Question

Notifications

You’re not receiving notifications from this thread.

Jumpstart App get's stucked with wrong login data

Martin asked in General

Hi.
I've created a new app by using the jumpstart template:
rails new testapp -d postgresql -m https://raw.githubusercontent.com/excid3/jumpstart/master/template.rb'

rails db:create db:migrate
rails s

Nothing changed in the app.

A signed-up user can sign in successfully, but the app get's stucked when I'm using wrong login data. No (error) messages are displayed and the login button is disabled after being (back) redirected to 'sessions#new'. No errors are shown by the rails server. The browser console is showing this:

Error: Form responses must redirect to another location
at FormSubmission.requestSucceededWithResponse (application-6749d4385864232cfaf0.js:1712)
at FetchRequest._callee2$ (application-6749d4385864232cfaf0.js:1293)
at tryCatch (application-6749d4385864232cfaf0.js:20932)
at Generator.invoke as _invoke
at Generator.next (application-6749d4385864232cfaf0.js:20988)
at asyncGeneratorStep (application-6749d4385864232cfaf0.js:713)
at _next (application-6749d4385864232cfaf0.js:715)
at application-6749d4385864232cfaf0.js:715
at new Promise ()
at FetchRequest. (application-6749d4385864232cfaf0.js:715)
formSubmissionErrored @ application-6749d4385864232cfaf0.js:4120

Can someone help me out?

Cheers,
Martin

What version of Rails are you on?

Hi Chris.

Rails version 6.1.4
Ruby version ruby 3.0.1p64 (2021-04-05 revision 0fb782ee38) [x86_64-darwin20]
RubyGems version 3.2.15
Rack version 2.2.3
JavaScript Runtime Node.js (V8)

I just found this video: https://gorails.com/episodes/devise-hotwire-turbo
In the end it worked (with the jumpstart template). But is it still the right way to go?

The latest version of jumpstart includes @hotwired/turbo-rails...(?)

I just updated Jumpstart open source to use Hotwire, so maybe there is a bug in it. I'll have to try it out again.

Also feel free to post this on the Jumpstart repository so I can keep track easier. 👍

Logging in with invalid credentials does fail and is a bug. I'll get that fixed. 👍

Alrighty, pushed fixes for that. If sign up or login failed, it would just hang. Those are both working now. 👍

Great! The changes worked in my project as well. Thank you very much Chris!

Fantastic! Let me know if you run into any other issues! We're still working on Madmin, but it should do all the basics nicely.

Hey Chris. Same problem with devise_invitable. When I try to set the password after accepting an invitation (view: users/invitations/edit) and e.g. the password doesn't match, the app gets stucked. Could you please give me some help here too?

Join the discussion

Want to stay up-to-date with Ruby on Rails?

Join 54,645+ developers who get early access to new tutorials, screencasts, articles, and more.

    We care about the protection of your data. Read our Privacy Policy.

    logo Created with Sketch.

    Ruby on Rails tutorials, guides, and screencasts for web developers learning Ruby, Rails, Javascript, Turbolinks, Stimulus.js, Vue.js, and more. Icons by Icons8

    © 2021 GoRails, LLC. All rights reserved.