Found this problem on my 'real' site. so I set up a fresh install of drupal 8 and tried there. got the error to reproduce.
Setup:
(make sure all errors visible) /admin/config/development/logging
Followed the steps in https://www.drupaleasy.com/video/2016/04/using-group-module-administrato...
(Created some users, a few groups, and an 'article' piece of content and article node assigned to a group
Then installed -TWO- available content plugins.
Made an 'article' assigned to a group
Warning appears on the groups node page group/{groupid}/nodes:
Warning: Illegal offset type in isset or empty in views_query_views_alter() (line 663 of core/modules/views/views.module).
First line of backtrace points to:
views_query_views_alter(Object, NULL, NULL) (Line: 501)
If i uninstall the second available content plugin, warnings go away.
Comments
Comment #2
aamouri CreditAttribution: aamouri commentedHello mu5a5hi,
I have the same problem.
I will try to find a solution for this bug
Thx
Comment #3
achtonThis has to do with the way the join is prepared in
GroupContentToEntityBase->query()
where the arguments provided to Views (views_query_views_alter()
) end up being an multidimensional array. This means an array is passed toisset()
as a parameter, which obviously breaks.Example:
The relevant code from
GroupContentToEntityBase->query()
:I'm honestly not sure how to fix this. Views' documentation for the Join handler indicates that
'value'
may be an array, and will activate theIN
operator, which it does here.Comment #4
achtonAh, this seems to be a Views bug after all - see #2744069: views_query_views_alter() does not handle IN queries.
Comment #5
achtonComment #6
kristiaanvandeneyndeYeah this is broken in core right now :)
Thanks for the investigation though, achton. Sorry I couldn't get to this issue earlier to save you the trouble.
Comment #7
rogertcd CreditAttribution: rogertcd commentedThanks achton the patch works for me