You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
With version 1.0.0 I see a NoMethodError for to_sym on a regular expression on Rails init. This is excerpt from the Github Action test log for the merge with 1.0.0:
NoMethodError: undefined method `to_sym' for /^((?-mix:client_secret|authentication_token|access_token|refresh_token|code))$/:Regexp
/home/runner/work/<...>/vendor/bundle/ruby/3.2.0/gems/devise-passwordless-1.0.0/lib/devise/passwordless/rails.rb:17:in `map'
/home/runner/work/<...>/vendor/bundle/ruby/3.2.0/gems/devise-passwordless-1.0.0/lib/devise/passwordless/rails.rb:17:in `block in <class:Engine>'
Great catch! ❤️ I think if there are non-stringy values in filter_parameters we'll assume you know what you're doing and not emit a warning. v1.0.1 with the bugfix will be on Rubygems in the next couple minutes. Thanks for the report!
With version 1.0.0 I see a
NoMethodError
forto_sym
on a regular expression on Rails init. This is excerpt from the Github Action test log for the merge with 1.0.0:The issue here is that the
Rails.application.config.filter_parameters
array may not only contains strings or symbols, but can also contain regular expressions. In my case it's the Doorkeeper gem that adds it (https://github.com/doorkeeper-gem/doorkeeper/blob/main/lib/doorkeeper/engine.rb#L9), resulting in this array:Looking at the precompiler for this filter in the Rails repo it looks to me that a regular expression should be supported (link to Rails 7.1, if I understand correctly the precompiler is new): https://github.com/rails/rails/blob/main/activesupport/lib/active_support/parameter_filter.rb#L56-L57
Not sure what the solution would be here, as the check in this project likely has to be done in a different way.
The text was updated successfully, but these errors were encountered: