Jun-06-2023, 12:37 PM
(This post was last modified: Jun-06-2023, 12:37 PM by Gribouillis.)
I try the same on my computer and it works
Output:λ python
Python 3.10.6 (main, May 29 2023, 11:10:38) [GCC 11.3.0] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> from os import makedirs
>>> makedirs('somewhere', mode=0o0755)
>>>
λ stat somewhere
File: somewhere
Size: 4096 Blocks: 8 IO Block: 4096 directory
Device: 804h/2052d Inode: 19141748 Links: 2
Access: (0755/drwxr-xr-x) Uid: ( 1000/ eric) Gid: ( 1000/ eric)
Access: 2023-06-06 14:47:15.152311228 +0200
Modify: 2023-06-06 14:47:15.152311228 +0200
Change: 2023-06-06 14:47:15.152311228 +0200
Birth: 2023-06-06 14:47:15.152311228 +0200
λ rmdir somewhere
λ
The only difference is that I created somewhere
and not /somewhere
. Are you doing this as super-user?