According to this document, “When you use direct filter mode and no data is available that satisfies the filter, an error is shown. Common error messages include Chart definition invalid and No data is available for the selected timeframe.”
Here are my thoughts to fix this:
Verify the labels and resources types match exactly.
If cross-project aggregation isn't necessary, filter by a single project when querying.
Verify that your account has Monitoring Viewer
or higher permissions on all relevant projects.