Pull user login/name from pusher
field when sender
is nil
#46
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Some payloads come in that are missing a
sender
field for one reason or another, but they do seem to have apusher
field, which has aname
field that is the same as the ['sender']['login'] value.This isn't a common issue, but a persistent one, always buzzing in the background of .org and .com.
https://sentry.io/travis-ci/org-listener-production/issues/587467865/
https://sentry.io/travis-ci/com-listener-production/issues/562523767/
I assume that these are valid build requests; nothing in the payloads I snagged via logging I put into place earlier today (in #45) appear to be invalid, just missing the
sender
value for whatever reason. Cruising through API docs, I can't see any v3 API events that don't have asender
field, but the data simply isn't there. A few DO call out thatpusher
is expected in the payload as well, and contains a different, less-rich version of thesender
data, which implies it might be some legacy API is pushing events at us. Since all we want/need it thelogin
orname
value, this seems like a small patch to cover ourselves in this case.