get_short_history crashes on multi-line history entries
RT handles multi-line entries by surrounding them by blank lines. python-rt crashes when (1) the short history contains multiline entries and (2) the multi-line entries themselves contain the ': ' string.
For example, here is a snippet from our RT:
RT/4.0.13 200 Ok
# 71/71 (/total)
6580556: Ticket created by sjl
6580557: Outgoing email recorded by RT_System
6580558: Membership in ticket #314828 added by RT_System
6580560: SLA 1d added by RT_System
6580561: Due changed from Wed Mar 27 19:15:01 2013 to Tue Mar 26 09:30:00 2013 by RT_System
6580562: Starts changed from Not set to Thu Mar 21 09:00:00 2013 by RT_System
6580563: ssg-ticket-cat Undefined added by RT_System
6580564: Ops-FLF Undefined added by RT_System
6580911: Priority changed from '1' to '3' by root
6581379: Correspondence added by tt2
6581380: Outgoing email recorded by RT_System
6581381: Status changed from 'new' to 'open' by RT_System
6581382: Outgoing email recorded by RT_System
6581383: Status changed from 'open' to 'stalled' by tt2
6590191: SLA 1d deleted by tt2
6590192: ssg-ticket-cat Undefined changed to Service Request by tt2
6590193: Ops Department Server added by tt2
6590194: Ops-FLF Undefined changed to FirstLine by tt2
6590195: Subject changed from 'Re: storage space for muspa
' to 'Re: storage space for muspa' by tt2
6590196: TimeWorked changed from (no value) to '5' by tt2
6590197: Status changed from 'stalled' to 'resolved' by tt2
In this example, transaction 6590195 causes python-rt to crash because on the continuation line, it splits on ': ' and then tries to parse the first part as an int, but the string " ' to 'Re" is not an int.
I have fixed this in https://github.com/wtsi-hgi/python-rt/commit/0d9ebf305b6dfd619a1cd68254d37c49ae29cfa2 (I tried to fork on gitlab, but it won't let me).