google-cloud-python: ValueError: For an array_value, subvalues must either all be indexed or all excluded from indexes.
Getting ValueError: For an array_value, subvalues must either all be indexed or all excluded from indexes. error when querying entities with empty arrays.
Edit: I tried getting around this with projection queries where possible but I need to modify the entities after fetching them, which you can’t do with the results of a projection query. So this is a pretty big issue as there is no way around it.
About this issue
- Original URL
- State: closed
- Created 7 years ago
- Reactions: 4
- Comments: 21 (6 by maintainers)
Commits related to this issue
- Non-functional datastore fix for #3152. — committed to lukesneeringer/google-cloud-python by deleted user 7 years ago
- Non-functional datastore fix for #3152. — committed to lukesneeringer/google-cloud-python by deleted user 7 years ago
- Non-functional datastore fix for #3152. — committed to lukesneeringer/google-cloud-python by deleted user 7 years ago
- Add unit test which actually exercises #3152. — committed to googleapis/google-cloud-python by tseaver 6 years ago
- Don't check 'exclude_from_indexes' for empty lists. Closes #3152. — committed to googleapis/google-cloud-python by tseaver 6 years ago
- Don't check 'exclude_from_indexes' for empty lists. (#4915) Closes #3152. — committed to googleapis/google-cloud-python by tseaver 6 years ago
I’ve forked the project just to do merge from upstream/master to the PR branch that contains this fix. You can clone my branch and install it manually if you like.
So you would have to do: