This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author John Jones
Recipients John Jones
Date 2015-07-12.17:13:43
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1436721223.66.0.229120395272.issue24617@psf.upfronthosting.co.za>
In-reply-to
Content
os.makedirs() gives the optional variable mode to set the permissions on the directories it creates.

While it seems to work for all triplet octal values (777,755,etc) it doesn't seem to work on values with the sticky bit (1777,1755,etc)

I know that to set the value as octal, you need, for some reason, to prepend a '0' to the number, such that the final value is '01755' - but even if you do int('1755',8) the error is there. Below I make a directory and then chmod it to the right value:

os.makedirs('/Users/Carolin/Desktop/demo',01703)
drwx-----x     2 Carolin  staff      68 12 Jul 18:53 demo

os.chmod('/Users/Carolin/Desktop/demo',01703)
drwx----wt     2 Carolin  staff      68 12 Jul 18:53 demo
History
Date User Action Args
2015-07-12 17:13:43John Jonessetrecipients: + John Jones
2015-07-12 17:13:43John Jonessetmessageid: <1436721223.66.0.229120395272.issue24617@psf.upfronthosting.co.za>
2015-07-12 17:13:43John Joneslinkissue24617 messages
2015-07-12 17:13:43John Jonescreate