#<Thread:0x00007f2d4ee278e0 /home/marcel/.rbenv/versions/3.1.3/lib/ruby/gems/3.1.0/gems/i18n-tasks-1.0.12/lib/i18n/tasks/scanners/scanner_multiplexer.rb:33 run> terminated with exception (report_on_exception is true):
/home/marcel/.rbenv/versions/3.1.3/lib/ruby/gems/3.1.0/gems/i18n-tasks-1.0.12/lib/i18n/tasks/scanners/ast_matchers/rails_model_matcher.rb:19:in `human_attribute_name_to_key_occurences': Error scanning app/models/application_record.rb: undefined method `type' for nil:NilClass (I18n::Tasks::CommandError)
return unless method_name == :human_attribute_name && receiver.type == :const
^^^^^
from /home/marcel/.rbenv/versions/3.1.3/lib/ruby/gems/3.1.0/gems/i18n-tasks-1.0.12/lib/i18n/tasks/scanners/ast_matchers/rails_model_matcher.rb:8:in `convert_to_key_occurrences'
from /home/marcel/.rbenv/versions/3.1.3/lib/ruby/gems/3.1.0/gems/i18n-tasks-1.0.12/lib/i18n/tasks/scanners/ruby_ast_scanner.rb:106:in `block (2 levels) in ast_to_occurences'
from /home/marcel/.rbenv/versions/3.1.3/lib/ruby/gems/3.1.0/gems/i18n-tasks-1.0.12/lib/i18n/tasks/scanners/ruby_ast_scanner.rb:105:in `each'
from /home/marcel/.rbenv/versions/3.1.3/lib/ruby/gems/3.1.0/gems/i18n-tasks-1.0.12/lib/i18n/tasks/scanners/ruby_ast_scanner.rb:105:in `block in ast_to_occurences'
from /home/marcel/.rbenv/versions/3.1.3/lib/ruby/gems/3.1.0/gems/i18n-tasks-1.0.12/lib/i18n/tasks/scanners/ruby_ast_scanner.rb:104:in `each'
from /home/marcel/.rbenv/versions/3.1.3/lib/ruby/gems/3.1.0/gems/i18n-tasks-1.0.12/lib/i18n/tasks/scanners/ruby_ast_scanner.rb:104:in `ast_to_occurences'
from /home/marcel/.rbenv/versions/3.1.3/lib/ruby/gems/3.1.0/gems/i18n-tasks-1.0.12/lib/i18n/tasks/scanners/ruby_ast_scanner.rb:32:in `scan_file'
from /home/marcel/.rbenv/versions/3.1.3/lib/ruby/gems/3.1.0/gems/i18n-tasks-1.0.12/lib/i18n/tasks/scanners/file_scanner.rb:27:in `block in keys'
from /home/marcel/.rbenv/versions/3.1.3/lib/ruby/gems/3.1.0/gems/i18n-tasks-1.0.12/lib/i18n/tasks/scanners/files/file_finder.rb:30:in `map'
from /home/marcel/.rbenv/versions/3.1.3/lib/ruby/gems/3.1.0/gems/i18n-tasks-1.0.12/lib/i18n/tasks/scanners/files/file_finder.rb:30:in `traverse_files'
from /home/marcel/.rbenv/versions/3.1.3/lib/ruby/gems/3.1.0/gems/i18n-tasks-1.0.12/lib/i18n/tasks/scanners/file_scanner.rb:57:in `traverse_files'
from /home/marcel/.rbenv/versions/3.1.3/lib/ruby/gems/3.1.0/gems/i18n-tasks-1.0.12/lib/i18n/tasks/scanners/file_scanner.rb:26:in `keys'
from /home/marcel/.rbenv/versions/3.1.3/lib/ruby/gems/3.1.0/gems/i18n-tasks-1.0.12/lib/i18n/tasks/scanners/scanner_multiplexer.rb:34:in `block (3 levels) in collect_results'
/home/marcel/.rbenv/versions/3.1.3/lib/ruby/gems/3.1.0/gems/i18n-tasks-1.0.12/lib/i18n/tasks/scanners/ast_matchers/rails_model_matcher.rb:19:in `human_attribute_name_to_key_occurences': undefined method `type' for nil:NilClass (NoMethodError)
return unless method_name == :human_attribute_name && receiver.type == :const
^^^^^
from /home/marcel/.rbenv/versions/3.1.3/lib/ruby/gems/3.1.0/gems/i18n-tasks-1.0.12/lib/i18n/tasks/scanners/ast_matchers/rails_model_matcher.rb:8:in `convert_to_key_occurrences'
from /home/marcel/.rbenv/versions/3.1.3/lib/ruby/gems/3.1.0/gems/i18n-tasks-1.0.12/lib/i18n/tasks/scanners/ruby_ast_scanner.rb:106:in `block (2 levels) in ast_to_occurences'
from /home/marcel/.rbenv/versions/3.1.3/lib/ruby/gems/3.1.0/gems/i18n-tasks-1.0.12/lib/i18n/tasks/scanners/ruby_ast_scanner.rb:105:in `each'
from /home/marcel/.rbenv/versions/3.1.3/lib/ruby/gems/3.1.0/gems/i18n-tasks-1.0.12/lib/i18n/tasks/scanners/ruby_ast_scanner.rb:105:in `block in ast_to_occurences'
from /home/marcel/.rbenv/versions/3.1.3/lib/ruby/gems/3.1.0/gems/i18n-tasks-1.0.12/lib/i18n/tasks/scanners/ruby_ast_scanner.rb:104:in `each'
from /home/marcel/.rbenv/versions/3.1.3/lib/ruby/gems/3.1.0/gems/i18n-tasks-1.0.12/lib/i18n/tasks/scanners/ruby_ast_scanner.rb:104:in `ast_to_occurences'
from /home/marcel/.rbenv/versions/3.1.3/lib/ruby/gems/3.1.0/gems/i18n-tasks-1.0.12/lib/i18n/tasks/scanners/ruby_ast_scanner.rb:32:in `scan_file'
from /home/marcel/.rbenv/versions/3.1.3/lib/ruby/gems/3.1.0/gems/i18n-tasks-1.0.12/lib/i18n/tasks/scanners/file_scanner.rb:27:in `block in keys'
from /home/marcel/.rbenv/versions/3.1.3/lib/ruby/gems/3.1.0/gems/i18n-tasks-1.0.12/lib/i18n/tasks/scanners/files/file_finder.rb:30:in `map'
from /home/marcel/.rbenv/versions/3.1.3/lib/ruby/gems/3.1.0/gems/i18n-tasks-1.0.12/lib/i18n/tasks/scanners/files/file_finder.rb:30:in `traverse_files'
from /home/marcel/.rbenv/versions/3.1.3/lib/ruby/gems/3.1.0/gems/i18n-tasks-1.0.12/lib/i18n/tasks/scanners/file_scanner.rb:57:in `traverse_files'
from /home/marcel/.rbenv/versions/3.1.3/lib/ruby/gems/3.1.0/gems/i18n-tasks-1.0.12/lib/i18n/tasks/scanners/file_scanner.rb:26:in `keys'
from /home/marcel/.rbenv/versions/3.1.3/lib/ruby/gems/3.1.0/gems/i18n-tasks-1.0.12/lib/i18n/tasks/scanners/scanner_multiplexer.rb:34:in `block (3 levels) in collect_results'
i18n-tasks: Error scanning app/models/application_record.rb: undefined method `type' for nil:NilClass
return unless method_name == :human_attribute_name && receiver.type == :const
Heyho,
i have a problem with the rails model matcher. At first i need to require it in my config - weird, but okay :grin:
When i run it now, i get this error:
Greets Marcel