Skip to content
Snippets Groups Projects

Adding links to user & build stage in a Build message

What does this MR do?

Adds links to commit author and build stage in slack notifications

  • Build the author_url and send it as part of the build message
    • If the author is a GitLab user, author_url is the GitLab user's url
    • else it is the mailto ref. of the author_email from git
  • Use the build_id & author_url to construct links to the build & author

Are there points in the code the reviewer needs to double check?

  • The location of where the author_url should be constructed. Was not sure if the data_builder/build.rb file is the correct place

Why was this MR needed?

For giving additional information about builds in slack notifications

Screenshots (if relevant)

Before:

before_new

After:

after_new

Does this MR meet the acceptance criteria?

What are the relevant issue numbers?

Closes #26500 (closed)

Partially addresses #21114 (moved)

Merge request reports

Loading
Loading

Activity

Filter activity
  • Approvals
  • Assignees & reviewers
  • Comments (from bots)
  • Comments (from users)
  • Commits & branches
  • Edits
  • Labels
  • Lock status
  • Mentions
  • Merge request status
  • Tracking
  • I'm not sure if the fallback to mailto: link makes sense. It may be a little bit unexpected that sometimes clicking the link opens your browser and sometimes email client. Maybe we can get some UX help.

  • added ~19492 label

  • added 1 commit

    • 8e46fe2d - Modifying changelog entry to add merge request id

    Compare with previous version

  • mentioned in issue #27149 (moved)

  • Thoughts on this @dimitrieh? Thanks! 😄

  • This seems great, i think the fallback to mailto: is sort of integrated with git.. and is imo the way to handle this.. (we do this in some places within gitlab it self as already).. just an extra thought towards this.. wouldn't it be even more useful to get linked to a 1:1 chat if that person is a gitlab user and also a mattermost user?

    @adamniedzielski @mpoornima just to be sure.. we are speaking about a single build, not a whole "stage" correct? in that sense perhaps adjust the wording?

    @pedroms including you in this, as you did work on chatops previously, what do you think about the fallback to mailto: ?

  • @dimitrieh Thank you for your comments. Will change the wording.

  • added 339 commits

    Compare with previous version

  • username-removed-378947 resolved all discussions

    resolved all discussions

  • @dimitrieh

    wouldn't it be even more useful to get linked to a 1:1 chat if that person is a gitlab user and also a mattermost user?

    I agree that it would be even more useful, but:

    1. I think that this notification is used both for Slack and Mattermost
    2. Even for Mattermost I'm not sure if we have the necessary information to do that
    3. It would make this MR more difficult

    So I believe that we should stick to what is currently suggested. I'm fine with mailto: if you say so 😄.

  • @mpoornima The build failure doesn't seem to be related to your changes. I believe that we are already aware of the failing specs and it is already fixed in master or will be fixed soon.

  • changed milestone to %8.17

  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Please register or sign in to reply
    Loading