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 lars.gustaebel
Recipients lars.gustaebel, tarek
Date 2009-09-07.16:25:41
SpamBayes Score 1.9941605e-07
Marked as misclassified No
Message-id <1252340744.56.0.594418086004.issue6856@psf.upfronthosting.co.za>
In-reply-to
Content
I do not quite see the benefit from the set_* methods. Although the
attribute access I proposed may be slightly more complicated (because
you might need the pwd and grp modules) it offers the most freedom.
Let's take the set_uid() method as an example: Its purpose would be to
set both the uid and uname field in the tar header. That is fine as long
as its argument is a uid or username that actually exists. If set_uid()
gets a username that does not exist, what are we going to do? Only set
the uname field and leave the uid field alone or raise an exception? If
the user wants to set a non-existant username on purpose, he cannot use
the set_uid() method. And what are we going to do on Windows? Is there
anything comparable to pwd/grp we could use?
I expect the common use case for these both methods will be to *reset*
the owner information to a default, and this is done by setting uname to
"root" and uid to 0.

The filter argument is actually a nice idea. I have attached a patch
that outlines my idea of how it is supposed to be. Comments welcome.
History
Date User Action Args
2009-09-07 16:25:45lars.gustaebelsetrecipients: + lars.gustaebel, tarek
2009-09-07 16:25:44lars.gustaebelsetmessageid: <1252340744.56.0.594418086004.issue6856@psf.upfronthosting.co.za>
2009-09-07 16:25:43lars.gustaebellinkissue6856 messages
2009-09-07 16:25:42lars.gustaebelcreate