-
-
Notifications
You must be signed in to change notification settings - Fork 662
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
[typer] better error messages when importing nonexistent subtypes / fields #10899
Conversation
Are these tests supposed to fail? There's only one failure and that's because of a different range. |
No, I did implement those. I didn't commit the fully qualified ones yet, need to clean those a bit |
I added failing tests 659de5c for the two cases I'm not sure how to handle
|
Yeah the expression-level ones are quite difficult. This portion of code has been working very well since the nadako-rework, but the underlying logic is still complicated. There's a lot of try/resume going on, so communicating meaningful information is not very obvious. I'll take a look but I don't want to spend too much time on this because it'd be little more than a small QOL improvement anyway. |
Yeah I agree; handling only imports for now is fine I guess, it's already an improvement. |
We can catch this case in | Error (Type_not_found((_,mname),tname,Not_defined),_) when tname = first.name && tname = mname However, when we put So yeah I think we shouldn't worry about this at the moment and just merge the changes you've already made. It might be possible to clean up this field chain handling code some more (there are some |
This reverts commit 659de5c.
See #10897
Would also be nice to do the same when using fully qualified paths, but not sure how feasible that would be.