System hook event_type vs. event_name
Everyone can contribute. Help move this issue forward while earning points, leveling up and collecting rewards.
Summary
System hook event type field name inconsistent between merge_request and other event types.
Steps to reproduce
Create a system hook and point it to some appropriate handler.
Test the hook with different hook types or cause the real events to happen. Compare with the results for merge_request event.
What is the current bug behavior?
Only merge request hook data contain event type in "event_type" field, other use "event_name". According to the documentation, even other events use "event_name".
What is the expected correct behavior?
I would expect all the events use the same field name, probably "event_name". Is there a reason for this inconsistency?
Results of GitLab environment info
Expand for output related to GitLab environment info
System information System: Ubuntu 16.04 Current User: git Using RVM: no Ruby Version: 2.3.7p456 Gem Version: 2.6.14 Bundler Version:1.13.7 Rake Version: 12.3.1 Redis Version: 3.2.11 Git Version: 2.16.4 Sidekiq Version:5.0.5 Go Version: unknownGitLab information Version: 10.8.3 Revision: 564c342 Directory: /opt/gitlab/embedded/service/gitlab-rails DB Adapter: postgresql URL: https://gitlab.office.nic.cz HTTP Clone URL: https://gitlab.office.nic.cz/some-group/some-project.git SSH Clone URL: git@gitlab.office.nic.cz:some-group/some-project.git Using LDAP: yes Using Omniauth: no
GitLab Shell Version: 7.1.2 Repository storage paths:
- default: /var/opt/gitlab/git-data/repositories Hooks: /opt/gitlab/embedded/service/gitlab-shell/hooks Git: /opt/gitlab/embedded/bin/git