Fix autocompletion scoping with has_* through relations#233
Fix autocompletion scoping with has_* through relations#233adamruzicka merged 2 commits intowvanbergen:masterfrom
Conversation
|
Nope, hold on, not quite it |
5815b54 to
063ab24
Compare
|
This could do it, but it changes the autocomplete's behaviour a bit. An example from Foreman - I have a Host with:
Before this (and the previous scope change), calling |
ofedoren
left a comment
There was a problem hiding this comment.
Thanks, @adamruzicka ! I've tested it a bit and it seems to work per description, also I've noticed that in the context of Foreman if I do Host.complete_for('location = ') it would suggest only locations which have a host. I'd say that's fine, but some might find it as a bug, what's your take on this?
Overall ACK from me.
I'd say having autocomplete offer you options which yield no results when evaluated is a bit pointless. So while it might be viewed as a bug, I'd say this new behaviour makes more sense. |
We should somehow propagate this take to the users of the library, like a heads up. |
This is a hack. Some stale record was being left somewhere between the test runs. Individual runs of auto_complete_spec and relation_querying_spec were passing, but running both at once failed. Renaming a constant that was used in both helped.
ae646f3 to
86b6957
Compare
|
I updated the changelog, once this goes in I'll update the wiki. Not sure if there's anything else that can be done |
No description provided.