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
Request for support. Note: Please try to avoid submitting issues for support requests. Use Gitter instead.
Checklist before submitting:
I've searched for an existing issue.
I've asked my question on Gitter and have not received a satisfactory answer.
I've included a complete bug report template. This step helps us and allows us to see the bug without trying to reproduce the problem from your description. It helps you because you will frequently detect if it's a problem specific to your project.
The feature I'm asking for is compliant with the JSON:API spec.
Description
If the user adds a join (e.g. in records) and that association has include_optional_linkage_data: true, then get_join_arel_node prints "get_join_arel_node: No join added" to stdout, returns nil, and a little later we crash because of the nil.
This happens because get_join_arel_node compares the node count before & after adding a join, but the count doesn't change because the join was already there.
We should fix this by looking for a compatible join and only failing if we can't find one. If we are trying to add a left outer join, then any join type will do (since adding an outer join wouldn't change the cardinality). If we are trying to add an inner join, then only another inner join is compatible (since otherwise the filtering we expect wouldn't happen).
I have a test case in my related PR, so I haven't included one here.
I hit this bug on master (a3a2a7a) and ruby 3.1.2p20.
The text was updated successfully, but these errors were encountered:
This issue is a (choose one):
Checklist before submitting:
Description
If the user adds a join (e.g. in
records
) and that association hasinclude_optional_linkage_data: true
, thenget_join_arel_node
prints "get_join_arel_node: No join added" to stdout, returns nil, and a little later we crash because of the nil.This happens because
get_join_arel_node
compares the node count before & after adding a join, but the count doesn't change because the join was already there.We should fix this by looking for a compatible join and only failing if we can't find one. If we are trying to add a left outer join, then any join type will do (since adding an outer join wouldn't change the cardinality). If we are trying to add an inner join, then only another inner join is compatible (since otherwise the filtering we expect wouldn't happen).
I have a test case in my related PR, so I haven't included one here.
I hit this bug on
master
(a3a2a7a) and ruby 3.1.2p20.The text was updated successfully, but these errors were encountered: