Path: csiph.com!fu-berlin.de!uni-berlin.de!not-for-mail From: Ben Finney Newsgroups: comp.lang.python Subject: Re: Make a unique filesystem path, without creating the file Date: Tue, 23 Feb 2016 09:48:59 +1100 Lines: 21 Message-ID: References: <85r3gf55k4.fsf@benfinney.id.au> <85mvr26dij.fsf@benfinney.id.au> <56CB4F60.4010201@stoneleaf.us> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Trace: news.uni-berlin.de BZrT6ED6NNvokNIVyDRdpw+x70gAlYFWu1gRj0rhssXg== Cancel-Lock: sha1:Grm0b+rRpwWODPEJ7G06TO93kss= Return-Path: X-Original-To: python-list@python.org Delivered-To: python-list@mail.python.org X-Spam-Status: OK 0.066 X-Spam-Evidence: '*H*': 0.87; '*S*': 0.00; 'subject:file': 0.07; 'filesystem': 0.09; 'received:80.91': 0.09; 'received:80.91.229': 0.09; 'received:gmane.org': 0.09; 'received:list': 0.09; 'clarified': 0.16; 'received:80.91.229.3': 0.16; 'received:io': 0.16; 'received:plane.gmane.org': 0.16; 'received:psf.io': 0.16; 'wrote:': 0.16; 'later': 0.16; 'name;': 0.22; 'header:User- Agent:1': 0.26; 'header:X-Complaints-To:1': 0.26; 'entries': 0.27; 'function': 0.28; 'this.': 0.28; 'path,': 0.29; 'thread,': 0.29; 'entry': 0.31; 'file': 0.34; 'path': 0.35; 'something': 0.35; 'instead': 0.36; 'there': 0.36; 'depends': 0.36; 'to:addr:python- list': 0.36; 'pm,': 0.36; 'subject:: ': 0.37; 'received:org': 0.37; 'mean': 0.38; 'means': 0.39; 'subject:the': 0.39; 'to:addr:python.org': 0.40; 'skip:u 10': 0.61; 'real': 0.62; 'different': 0.63; 'goal': 0.64; 'touch': 0.66; 'skip:\xe2 10': 0.70; '_o__)': 0.84; 'received:125': 0.84; 'touching': 0.84; 'unique.': 0.84; 'ethan': 0.91; 'furman': 0.91; 'subject:Make': 0.91 X-Injected-Via-Gmane: http://gmane.org/ X-Gmane-NNTP-Posting-Host: jigong.madmonks.org X-Public-Key-ID: 0xAC128405 X-Public-Key-Fingerprint: 517C F14B B2F3 98B0 CB35 4855 B8B2 4C06 AC12 8405 X-Public-Key-URL: http://www.benfinney.id.au/contact/bfinney-pubkey.asc X-Post-From: Ben Finney User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.4 (gnu/linux) X-BeenThere: python-list@python.org X-Mailman-Version: 2.1.21rc2 Precedence: list List-Id: General discussion list for the Python programming language List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Xref: csiph.com comp.lang.python:103368 Ethan Furman writes: > On 02/14/2016 04:08 PM, Ben Finney wrote: > > > I am unconcerned with whether there is a real filesystem entry of that > > name; the goal entails having no filesystem activity for this. I want a > > valid unique filesystem path, without touching the filesystem. > > This is impossible. If you don't touch the file system you have no > way to know if the path is unique. That was unclear. Later in the same thread, I clarified that by “unique” I mean nothing about entries already on the filesystem. Instead it means “unpredictably different each time the function is called”. -- \ “It is difficult to get a man to understand something when his | `\ salary depends upon his not understanding it.” —Upton Sinclair, | _o__) 1935 | Ben Finney