Skip to content
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

improve error message for relations missing in includes #21111

Closed
eiked opened this issue Aug 3, 2015 · 2 comments
Closed

improve error message for relations missing in includes #21111

eiked opened this issue Aug 3, 2015 · 2 comments

Comments

@eiked
Copy link

eiked commented Aug 3, 2015

I'd like to suggest an improvement for the error messages.

I deleted a relation from my model but it was still referenced in an includes clause.

So I got an error message like:
'Association named 'label' was not found on Disk; perhaps you misspelled it?'
and it was not really obvious where this came from.

I believe the error message can be improved.
This obviously comes from a part of rails that wants to resolve the includes clause.

So maybe something like:
'Association named 'label' _referenced in includes_ was not found on Disk; perhaps you misspelled it?'
could be done

I was thinking about:
We might want to add more information to the call chain,
to improve error reporting (in debug mode)

We actually might want to add a debug:{} to every binding.
2p

~eike

@arthurnn
Copy link
Member

@eiked yep, I guess would be great to have a better message for sure.
Fell free to send a PR for it.

@kamipo
Copy link
Member

kamipo commented Nov 6, 2017

Fixed by #22518.

@kamipo kamipo closed this as completed Nov 6, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants