(self, pathname: str)
| 863 | ) |
| 864 | |
| 865 | def _g_check_not_contains(self, pathname: str) -> None: |
| 866 | # The not-a-TARDIS test. ;) |
| 867 | mypathname = self._v_pathname |
| 868 | if ( |
| 869 | mypathname == "/" # all nodes fall below the root group |
| 870 | or pathname == mypathname |
| 871 | or pathname.startswith(mypathname + "/") |
| 872 | ): |
| 873 | raise NodeError( |
| 874 | "can not move or recursively copy node ``%s`` " |
| 875 | "into itself" % mypathname |
| 876 | ) |
| 877 | |
| 878 | def _g_maybe_remove( |
| 879 | self, parent: Group, name: str, overwrite: bool |