-
Notifications
You must be signed in to change notification settings - Fork 1.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[CT-2510] [Bug] Raise an error if non-versioned model is defined with same name as existing versioned model #7487
Comments
This is not a partial parsing bug per se. I've created a test case which does not fail appropriately even with full parsing. |
I haven't been able to recreate the compilation error. Whether I create the non-versioned model first or second, it never complains. |
I tried the same set of steps as outlined and was not able to produce the compilation error. |
I can reproduce this now. I accidentally didn't create and save Here's my key files at the end:
models:
- name: my_model
versions:
- v: 1
select 1 as id
select 0 as id |
Commit 0de046d yesterday removed the code that was causing the error in the example to be thrown. |
The error was thrown in the no-partial-parse case and not in the partial parse case because the order of the nodes encountered was different and the code was checking is_versioned for the previously encountered node. |
Set up:
Now:
models/my_model.sql
(no version suffix)versions
block in the yaml fileRe-parse with partial parsing, and everything looks fine:
And now without partial parsing, I see an error (good! I should!):
The text was updated successfully, but these errors were encountered: