Actions
Bug #30238
closedundefined method `klass' for nil:NilClass
Difficulty:
Triaged:
Yes
Bugzilla link:
Pull request:
Description
When using host filter 'applicable_errata_issued > "10 days ago"' [0], I get error "undefined method `klass' for nil:NilClass" in WebUI and attached traceback. Happens for both filtering hosts in hosts list and filtering hosts while generating templates.
Steps to Reproduce:
1. Monitoring -> Report Templates -> Host - Statuses -> Generate
2. hosts: applicable_errata_issued > "10 days ago"
3. Submit
Actual results:
Error, nothing generated
Expected results:
Successfully generated, correctly filtered report
This can also be generated via rails console
> Host.search_for('applicable_errata_issued = "10 days ago"') NoMethodError: undefined method `klass' for nil:NilClass from /home/vagrant/foreman/.vendor/ruby/2.5.0/gems/scoped_search-4.1.8/lib/scoped_search/query_builder.rb:398:in `reflection_keys'
Actions