Comments (4)
I've created a feature request issue in #206
from passwordless.
In the stacktrace, with_locale goes through two passwordless methods.
mailer.sign_in tries to build a magic_link with context.url_for and fails
passwordless/context.rb:42:in `url_for'
passwordless/mailer.rb:16:in `sign_in'
actionpack (7.1.2) lib/action_dispatch/journey/formatter.rb:44:in `path'
actionpack (7.1.2) lib/action_dispatch/routing/route_set.rb:854:in `url_for'
actionpack (7.1.2) lib/action_dispatch/routing/url_for.rb:184:in `full_url_for'
actionpack (7.1.2) lib/action_dispatch/routing/url_for.rb:174:in `url_for'
actionpack (7.1.2) lib/action_dispatch/routing/route_set.rb:537:in `url_for'
passwordless (1.2.0) lib/passwordless/context.rb:42:in `url_for'
passwordless (1.2.0) app/mailers/passwordless/mailer.rb:16:in `sign_in'
actionpack (7.1.2) lib/abstract_controller/base.rb:224:in `process_action'
actionpack (7.1.2) lib/abstract_controller/callbacks.rb:259:in `block in process_action'
activesupport (7.1.2) lib/active_support/callbacks.rb:121:in `block in run_callbacks'
actiontext (7.1.2) lib/action_text/rendering.rb:23:in `with_renderer'
actiontext (7.1.2) lib/action_text/engine.rb:69:in `block (4 levels) in <class:Engine>'
activesupport (7.1.2) lib/active_support/callbacks.rb:130:in `instance_exec'
activesupport (7.1.2) lib/active_support/callbacks.rb:130:in `block in run_callbacks'
activesupport (7.1.2) lib/active_support/callbacks.rb:141:in `run_callbacks'
actionpack (7.1.2) lib/abstract_controller/callbacks.rb:258:in `process_action'
actionpack (7.1.2) lib/abstract_controller/base.rb:160:in `process'
actionmailer (7.1.2) lib/action_mailer/rescuable.rb:29:in `block in process'
actionmailer (7.1.2) lib/action_mailer/rescuable.rb:21:in `handle_exceptions'
actionmailer (7.1.2) lib/action_mailer/rescuable.rb:28:in `process'
actionview (7.1.2) lib/action_view/rendering.rb:40:in `process'
actionmailer (7.1.2) lib/action_mailer/base.rb:658:in `block in process'
activesupport (7.1.2) lib/active_support/notifications.rb:206:in `block in instrument'
activesupport (7.1.2) lib/active_support/notifications/instrumenter.rb:58:in `instrument'
activesupport (7.1.2) lib/active_support/notifications.rb:206:in `instrument'
actionmailer (7.1.2) lib/action_mailer/base.rb:657:in `process'
actionmailer (7.1.2) lib/action_mailer/message_delivery.rb:136:in `block in processed_mailer'
<internal:kernel>:90:in `tap'
actionmailer (7.1.2) lib/action_mailer/message_delivery.rb:135:in `processed_mailer'
actionmailer (7.1.2) lib/action_mailer/message_delivery.rb:124:in `deliver_now'
passwordless (1.2.0) lib/passwordless/config.rb:47:in `block in <class:Configuration>'
passwordless (1.2.0) app/controllers/passwordless/sessions_controller.rb:34:in `create'
actionpack (7.1.2) lib/action_controller/metal/basic_implicit_render.rb:6:in `send_action'
actionpack (7.1.2) lib/abstract_controller/base.rb:224:in `process_action'
actionpack (7.1.2) lib/action_controller/metal/rendering.rb:165:in `process_action'
actionpack (7.1.2) lib/abstract_controller/callbacks.rb:259:in `block in process_action'
activesupport (7.1.2) lib/active_support/callbacks.rb:121:in `block in run_callbacks'
i18n (1.14.1) lib/i18n.rb:322:in `with_locale'
from passwordless.
Yes, I believe this is due to how passwordless builds its urls. I'm afraid we don't support scoped urls like that currently.
It is not something I have the bandwidth to add support for atm, but I'll gladly review and possibly include a nice PR if someone is up for the challenge.
from passwordless.
@andreaskundig If you need this url structure, you can set up your own routes and possibly controllers/mailers/routes. Use the built-in ones as a starting point. Will take a bit of work but it's possible.
from passwordless.
Related Issues (20)
- Bug: Release has outdated source for router_helpers.rb HOT 6
- Feature Request: Instrumentation via `ActiveSupport::Instrumentation` HOT 1
- troubles upgrading to 1.0.0 HOT 3
- enumerate passwordless_sessions HOT 6
- app/views/passwordless/sessions/new.html.erb - label for does not match field ID HOT 1
- app/views/passwordless/sessions/show.html.erb HOT 2
- Error when registering new users HOT 3
- Bug: default_url_options[:host] is required for mailer HOT 6
- Embed redirect URL in magic link HOT 2
- error: Missing host to link to! Please provide the :host parameter HOT 1
- [DRAFT] readme proofreading HOT 6
- Add support for Turbo Native HOT 1
- autofocus in the show action view HOT 2
- current_user action controller HOT 3
- Support scoped routes
- NoMethodError: undefined method `session' for nil HOT 12
- sign in via QR code 📸 HOT 3
- Add `after_session_confirm` hook after session confirmation HOT 2
- Paranoid mode still autosaves its associated authenticatable model HOT 8
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from passwordless.