Hoping this patch sorts out the missing curlies from the MR above. I saw two in Remote.php. Seems to be running fine now on my sites.
Re-rolled patch for 9.0.x. I can make a new fork in a bit. Just adding a patch for now.
The move to 9.5.x brought this issue back for us since CKEditor 4 was moved from core to contrib. So, we had to make a new version specific to Drupal 9.5.x and CKEditor 4 as contrib.
This patch is the same as the one provided here, https://www.drupal.org/project/drupal/issues/3131055 π Wrapping drupal-media image in a link produces empty P tags after image Needs work , just applied to the contrib CKEditor module.