Do you use the raw/HTML/CKeditor syntax (syntax_plugin="none" in flyspray.conf.php) ?

If yes, were you fronted during upgrade with a form option and you choosed yes ?

Is the upgrade running ok if you choose no at that point during the upgrade?

Can you please show that description content of task 400? For example load from database with

select detailed_desc from flyspray_tasks where task_id=400;

I assume some UTF8 issues, but need to find where the problem is.

Sadly I use syntax_plugin="dokuwiki" and mysql for my own stuff and the last supporting developer here who used Postgresql with Flyspray - jahto - is inactive for a while and the tests on github / travis-ci aren't written yet.