mirror of
https://github.com/odoo/runbot.git
synced 2025-03-15 23:45:44 +07:00

The previous version of the code assumed `pr['body']` is always a
string, which is not correct, when the PR body is emptied the body
itself is removed (its value is `None`).
Add a case for this in the PR edition test, and avoid blowing up (or
adding empty newlines) when the PR body is empty. For PR creation this
issue was fixed in c2db5659d8
but
apparently I missed that the exact same issue occurs just a few lines
above.
Also turns out github does *not* send change information when the body
is updated from (or to?) `None`, so don't even bother with that, just
check every time if the overall message has been updated.
Fixes #629
189 B
189 B
FIX: correctly handle PR empty PR descriptions
Github's webhook for this case are weird, and weren't handled correctly, updating a PR's description to or from empty might be mishandled.