spectacles-ci / spectacles

A continuous integration tool for Looker and LookML.
https://spectacles.dev
MIT License
217 stars 35 forks source link

Fix profiling and open it back up to all queries #706

Closed joshtemple closed 1 year ago

joshtemple commented 1 year ago

Change description

Fixes a bug where profiling did not work at all and expands profiling to be allowed for all queries again, not just fail fast queries.

It's important to note that the profiler results are a bit harder to interpret now that we use binary search. Previously, we had N + 1 queries for each Explore (one that selected all dimensions and one for each dimension). So a query either had exactly N dimensions or 1 dimension.

Now, a query can have any number of dimensions between 1 and N. I've basically handwaved this by returning "*" for the Dimension(s) column in the profiler output whenever a query has more than 1 dimension. It's worth documenting that this means "more than one" and not necessarily "all". I thought this was better than trying to print an arbitrarily long list of dimensions, but open to feedback.

Type of change

Related issues

Closes #653.

Checklists

Security

Code review