I tried. In the new texts I write, it adds spaces like the ones in the screenshot I sent.
I think I might have an answer. InDesign has recently switched its complex-script text rendering engine to HarfBuzz, and many older fonts seem to fail to render correctly. We've seen questions here about older fonts for languages like Urdu, Gujarati, or Nepali, failing with symptoms a lot like yours. So I think you can safely ignore my longer message about document corruption and IDML, and just try these two things:
1) Can you tell us the name of the font in question? Is it one I can download and test myself?
and
2) You should try turning on the Legacy Character Shaping Engine in the Preferences under Advanced Type to see if your Arabic compositon problems go away.