I've done some testing and found out Samba is crashing:
[2024/03/14 09:07:19.329402, 0] ../../source3/smbd/fd_handle.c:39(fd_handle_destructor)
PANIC: assert failed at ../../source3/smbd/fd_handle.c(39): (fh->fd == -1) || (fh->fd == AT_FDCWD)
[2024/03/14 09:07:19.329435, 0] ../../lib/util/fault.c:178(smb_panic_log)
===============================================================
[2024/03/14 09:07:19.329442, 0] ../../lib/util/fault.c:179(smb_panic_log)
INTERNAL ERROR: assert failed: (fh->fd == -1) || (fh->fd == AT_FDCWD) in smbd (smbd[192.168.1.) (client [192.168.1.188]) pid 22564 (4.19.5)
[2024/03/14 09:07:19.329447, 0] ../../lib/util/fault.c:186(smb_panic_log)
If you are running a recent Samba version, and if you think this problem is not yet fixed in the latest versions, please consider reporting this bug, see https://wiki.samba.org/index.php/Bug_Reporting
[2024/03/14 09:07:19.329451, 0] ../../lib/util/fault.c:191(smb_panic_log)
===============================================================
[2024/03/14 09:07:19.329464, 0] ../../lib/util/fault.c:192(smb_panic_log)
PANIC (pid 22564): assert failed: (fh->fd == -1) || (fh->fd == AT_FDCWD) in 4.19.5
[2024/03/14 09:07:19.329708, 0] ../../lib/util/fault.c:303(log_stack_trace)
This is with samba 4.19.
I seem to have found a get around, but I'm baffled right now about why this works. Install the recycle bin plugin and be sure it is running.
In my testing it looks like file deletes work. Deleting directories works but an error is displayed and the Android app does not show the directory as being deleted until closed and re-opened. The directory delete also crashes samba. Since the recycle bin plugin is for deleted files through SMB, there is something the recycle bin vfs is doing that prevents the file deletes from failing in this situation.
Because samba is crashing it looks to be an issue that the samba team needs to fix. At this time, I don't see any way through samba settings we will be able to fix this on the Unraid side. It could also be an issue with the Android app, but I doubt it.
In doing some research, there is a samba bug here that might solve the issue.