First of all, CAPCOM said "wontfix" (it is not a bug) regarding this behavior; this means the knowledge provided in this question's answers will be relevant for a long time.
According to a recollection, Safi'jiiva's Sapphire of the Emperor pattern probably consists of two separate patterns chained: the pattern for spawning the rock, and the actual Sapphire of the Emperor. Safi is guaranteed to either smash the ground or shoot out a rising breath to make comets fall down before it actually drops the Sapphire.
However, this pattern and Sapphire of the Emperor are not protected with flinch immunity like Behemoth does with their Comet. Worse, this cancellation does not prevent it from casting the Sapphire. Therefore, a party armed to the teeth can totally cause Safi to cancel it summoning comets but still let it drop the Sapphire.
To cancel it out, you can (some given in @Rapitor's answer)
- When Safi is going to drop the Sapphire, flash it right before you are unable to use your item.
- As you did with the comet, cancel the Sapphire with a flinch. Do note, however, that Safi will try to pull it off again when it is downed that way for the first time. If you intend to do it anyway, you can do it either by flinch, or ailments (paralysis, sleep or KO)
- Bomb Pod it twice. This can also cancel the Sapphire.
- Try to escape using a Farcaster before it becomes impossible.
To prevent such a situation, you can either check whether Safi is casting its rising breath and stop dealing damage and/or ailments at that timing, or force it use the ground smash pattern. The aggroed target can force the ground smash by either getting below Safi's abdomen, or clutching onto it.