Yes, the string was malformed and that caused the error. It was malformed because of a hack I wrote many years ago that breaks long writeln statements into as many write statements as necessary to keep them under 250 char. Unfortunately in this case the chop point was in a bad location. Yesterday I fixed my code and it handled the 367 char string without error due to adding the {$H+} to the top of my generated units that could likely have a long string.
Thank you to everyone who answered!