Closed michael-s-molina closed 1 month ago
All modified and coverable lines are covered by tests :white_check_mark:
Project coverage is 83.89%. Comparing base (
76d897e
) to head (785069d
). Report is 966 commits behind head on master.
:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.
@michael-s-molina I'm trying to understand when this would happen. Could this have something to do with BaseEngineSpec.make_label_compatible
changing the column alias?
@michael-s-molina I'm trying to understand when this would happen. Could this have something to do with
BaseEngineSpec.make_label_compatible
changing the column alias?
@villebro This happens when your engine spec has allows_subqueries = False
and you apply a series limit. I updated the PR description with a video.
However, maybe we could start using some convention for annotating code that should be removed/cleaned up during breaking windows? If we don't start cleaning up stuff like this we'll never get out of the tech debt hole we're in..
@villebro We generally use the @deprecated
annotation but I don't have enough context about this function to actually mark it as deprecated. Maybe @betodealmeida will know more and we could add the annotation in a follow-up if it's a valid case.
However, maybe we could start using some convention for annotating code that should be removed/cleaned up during breaking windows? If we don't start cleaning up stuff like this we'll never get out of the tech debt hole we're in..
We generally use the
@deprecated
annotation but I don't have enough context about this function to actually mark it as deprecated. Maybe @betodealmeida will know more and we could add the annotation in a follow-up if it's a valid case.
Good point, we can reuse that even for non-public methods. I'll keep that in mind in subsequent PRs 👍
SUMMARY
This PR fixes an issue with pre-query normalization when dealing with custom SQL. Previously, a custom SQL that had a label that does not match any column name would throw the following error:
Given function docs:
We simply skip the conversion of custom SQL types as we cannot determine if they are temporal or not currently.
BEFORE/AFTER SCREENSHOTS OR ANIMATED GIF
https://github.com/user-attachments/assets/e6191c06-2d78-43a9-8d08-334453ca78d2
TESTING INSTRUCTIONS
Repro the steps shown in the video using a db engine spec with
allows_subqueries = False
ADDITIONAL INFORMATION