WIP: Adds support for special @@ mentions
What does this MR do?
It adds support for special
@@ mentions. For instance access/role/permission groups like
@@developers, etc, and special groups like
assignees (of a merge request or an issue).
Are there points in the code the reviewer needs to double check?
- TODO in !17999 (diffs) line
- When a participant is also the assignee, calling
stack level too deep error. Any ideas?
Why was this MR needed?
This MR implements a feature request described in #33540.
Screenshots (if relevant)
Does this MR meet the acceptance criteria?
- Changelog entry added, if necessary
- Documentation created/updated
- API support added
- Tests added for this feature/bug
- Has been reviewed by UX
- Has been reviewed by Frontend
- Has been reviewed by Backend
- Has been reviewed by Database
- Conform by the merge request performance guides
- Conform by the style guides
- Squashed related commits together
End-to-end tests pass (
package-and-qamanual pipeline job)
What are the relevant issue numbers?
To recap the completeness state of the MR at this point (Apr 16, 2018) I think it misses the following:
Tests for the new
@@usage in cases other than Issues and Merge Requests. This tests will reveal what additional behaviour is missing.
- A clean way to pass context data (e.g. the noteable pointer) in the filter class.
- Find out what alternative context data are needed (if any) in the cases where the Noteable is not available.
Modify/add tests for asserting e-mail and web notifications are going out to the intented users in the cases of
- Resolve the "Stack level too deep" error.
Finally, when all is in place and working, extract all new
@@related functionality into new filter and parser classes.
- Add the newly supported handles in the autocomplete list on client side.
There a broken spec
spec/features/issues/spam_issues_spec.rb, but I could not figure out why.