Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
* Current commerce_shipping dev
* create view that contains line items (in my case an order view that relates line items)
* set filter on shipping service and select one arbitrary value
result:
* :-) view seems to work
* :-( saving the view is blocked and shows message "No valid values found on filter: Commerce Line item: Shipping service"
daring to raise prio as this is a views integration showstopper
Comments
Comment #1
geek-merlinComment #2
geek-merlinhas some relation to #1207680: No valid values found (6.x-3.x-dev & 7.x-3.x-dev)
Comment #3
geek-merlinnote:
* so this is about the filter for the 'commerce_shipping_service' field declared in commerce_shipping_line_item_configuration() and using core 'list_text'.
debugging views-save shows:
* 5x the validation call succeeds(!)
* 1x (the last) it fails
the evil call chain (where this->value == array() in views_handler_filter_in_operator::validate() )
* view::validate() - views/includes/view.inc:2057
* views_plugin_display::validate() - views/plugins/views_plugin_display.inc:2729 (the default display: views_plugin_display_default)
* views_handler_filter_in_operator::validate()
wtf?
Yes,
* ther IS an option selected
* this IS the default display
And NO,
* this is not reproducible with core text_list field on a node.
* nothing strange in syslog.
* stable or dev views all the same
Comment #4
geek-merlinGEE, in the offending instance of views_handler_filter_in_operator,
* $this->value ==array() :-(
* but $this->options['value'] == array(...)
looks we did not pass $this->init()!
EDIT: not necessarily, as handlers are cached.
Comment #5
geek-merlinWTF? mocking this gives us a completely well-behaved filter with correct $this->value
so where can this break?
hmm, as handlers are cached in the views object, the filter value must have been deleted before.
Comment #6
geek-merlinAs the shipping service field just uses a 'list_text' field with a custom options callback, i believe this is a views issue.
A nasty one.
Comment #7
maxchock CreditAttribution: maxchock commentedAny updates on this? I'm also stuck in the same situation.