Bad news. I don't think this has been fixed.
I have an M2 Pro MacBook Pro. For as long as I've had it, it has this "Disk Not Ejected Properly" issue.
I now have my external drives connected via an OWC Thunderbolt dock, and haven't gotten those notifications for a while, but they just happened again.
It continues to be a problem on macOS Sequoia, from 15.1 up through 15.5.
Once or twice, these disconnects corrupted my encrypted Time Machine backups, causing me to lose ALL my backup history.
I have my Mac set to:
"Prevent automatic sleeping on power adapter when the display is off"
"Put hard disks to sleep when possible: NEVER"
In the Terminal, I can run this: pmset -g | grep sleep
And get this result:
hibernatefile /var/vm/sleepimage
networkoversleep 0
disksleep 0
sleep 0 (sleep prevented by nsurlsessiond, powerd, useractivityd, bluetoothd, mds_stores, backupd, sharingd)
displaysleep 10
I've noticed this is a LOT more common when I haven't been at my Mac for over 24 hours.
Looking at the logs, I found the following, which was during the time the Mac was locked, but supposedly not asleep:
2025-07-05 13:13:33.274200-0400 0x1593c5f Default 0x0 508 0 diskarbitrationd: [com.apple.DiskArbitration.diskarbitrationd:default] ejected disk, id = /dev/disk5, ongoing.
2025-07-05 13:13:33.274591-0400 0x1593c5f Default 0x0 508 0 diskarbitrationd: [com.apple.DiskArbitration.diskarbitrationd:default] ejected disk, id = /dev/disk5, success.
2025-07-05 13:13:33.643571-0400 0x1593c5f Default 0x0 508 0 diskarbitrationd: [com.apple.DiskArbitration.diskarbitrationd:default] ejected disk, id = /dev/disk4, ongoing.
2025-07-05 13:13:33.652292-0400 0x1593c5f Default 0x0 508 0 diskarbitrationd: [com.apple.DiskArbitration.diskarbitrationd:default] ejected disk, id = /dev/disk4, success.
So, it looks like, despite my settings, something in macOS has decided that a "long" period of user inactivity means it can do a (partial) sleep, disregarding user settings.
I think that what is happening is that at some point it was decided by Apple that user settings should be disregarded when it comes to power management.
Something that makes this even more frustrating is that whatever system process decides to eject the disks in disregard of our settings cannot even do it properly. So, we get system notifications chastising us for the improper disconnects, as if we were yanking out the cables or something.
I'm going to have to use something like this command to make my Mac NOT eject disks on its own: caffeinate -i
Or, I think I'll try the Amphetatmine.app, which puts a nice GUI interface, complete with triggers on this.