NotSqrt / mattermost-integration-gitlab

Send events from Gitlab to Mattermost through webhooks
https://www.mattermost.org/webhooks/
Apache License 2.0
99 stars 45 forks source link

KeyError: u'action' #40

Open thomich opened 4 years ago

thomich commented 4 years ago

Hey all

Have a problem to receive events, even merge events, which are enabled by default.

Traceback (most recent call last):
File "/usr/local/lib/python2.7/dist-packages/mattermost_gitlab/server.py", line 45, in new_event
text = event.format()
File "/usr/local/lib/python2.7/dist-packages/mattermost_gitlab/event_formatter.py", line 204, in format
if self.action == 'open':
File "/usr/local/lib/python2.7/dist-packages/mattermost_gitlab/event_formatter.py", line 200, in action
return self.data['object_attributes']['action']
KeyError: u'action'
x.y.z.a - - [18/Jun/2020 16:21:46] "POST /new_event HTTP/1.1" 200 -

All is Setup based on README.

Mattermost incoming webhook:

image

Gitlab project webhook:

image

Anything i missed to configure?

Thanks for help

Regards thomi