Using @ breaks adding groups to message

When adding users to a new message, using the @ symbol searches only usernames, not groups.

Is this intentional? Looking back at previous instructions, it seems that we were encouraged to use the @

When trying to send a message to a group, where Everyone is allowed to mention and message the group, you are unable to add them. It appears that if you start with the @ symbol the autocomplete only accepts usernames, even if you add the full name of the group.

If you just enter text however, then the group names do appear

message%20group

8 Likes

To me this looks like a regression, @joffreyjaffeux do you recall anything here?

2 Likes

No, it’s not select-kit. And I don’t think I ever touched this.

2 Likes

@nbianca I recall you worked on this selector in the past can you have a look at this issue?

3 Likes

I tried to bisect this, but I had no luck… because this has been broken before v1.8! (I could not install older versions because I had problems with dependencies that were not worth the time) :boom:

Anyway, I got it fixed. The problem is that the query that gets to the server includes @ which seemed to work fine for usernames (Search.ts_query is pretty smart), but did not for groups.

Fixed by

7 Likes

Since they both use the same namespace, should they also use the same code path for search (on the server)?

3 Likes

Currently there is search data for users, topic, posts, categories and tags, but none for groups. Implementing it is definitely possible, but I do not think it is worth the effort.

3 Likes

I see, we should at the very least do the same stripping on the server for those who call the API directly.

And maybe give some (ts_query) :heart: to Group.search_groups as well :wink:

2 Likes

At first I implemented the stripping on the server side, but then I realised it isn’t server’s fault. If the client wants correct results, they should ask the correct questions.

2 Likes

This topic was automatically closed after 14 days. New replies are no longer allowed.