[Python-Dev] Warnings (original) (raw)
Antoine Pitrou solipsis at pitrou.net
Thu Feb 5 18:49:57 CET 2009
- Previous message: [Python-Dev] Warnings
- Next message: [Python-Dev] Why a STACKADJ(-1) in UNARY_NOT on ceval.c?
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Jaroslav Pachola <pachola mageo.cz> writes:
What's the replacement in the library then, in case that I just want to create a unique file name and I don't care about the possible issues?
Three alternatives I'm thinking of:
- tempfile.mktemp(): the doc says it has been deprecated since 2.3, but it's still there;
- NamedTemporaryFile(delete=False): that's the officially suggested replacement in the doc;
- tempfile.mkdtemp() and then create a regular file in the created directory.
Regards
Antoine.
- Previous message: [Python-Dev] Warnings
- Next message: [Python-Dev] Why a STACKADJ(-1) in UNARY_NOT on ceval.c?
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]