Hi Albrecht, On Fri, 1 Feb 2019 at 19:50, Albrecht Baur via Pharo-users <pharo-users@lists.pharo.org> wrote: > > I get a DirectoryIsNotEmpty exception on > FileReference(AbstractFileReference)>>deleteAll. > > But deleteAll is supposed to delete children too. -> So why the exception ?
This is a bug in the FilePlugin. When deleting directories it is leaving the deleted directory open. On Unix this is OK, the entry is removed from the parent directory and actually deleted when the file is closed. I assume that because CIFS is a windows protocol it doesn't handle it, and leaves the entry there until closed, causing the problems later on. The problem can be reduced to the following code: | root deleteMeFolder | root := '/path/to/cifs' asFileReference. deleteMeFolder := root / 'delme'. deleteMeFolder ensureCreateDirectory. deleteMeFolder delete. Then execute: $ sudo lsof | grep delme and you'll see the deleted entries. Issue: https://github.com/OpenSmalltalk/opensmalltalk-vm/issues/368 Cheers, Alistair