Re: [Tutor] Can tempfile.NamedTemporaryFile(delete=False) be used to create *permanent* uniquely named files?

2018-10-22 Thread Wolfgang Maier
On 21.10.18 08:13, boB Stepp wrote: Use case: I want to allow a user of my Solitaire Scorekeeper program to be able to give any name he wants to each game of solitaire he wishes to record. My thought for permanent storage of each game's parameters is to use a dictionary to map the user-chosen g

[Tutor] Fwd: Can tempfile.NamedTemporaryFile(delete=False) be used to create *permanent* uniquely named files?

2018-10-22 Thread boB Stepp
Forwarding to the Tutor list. Herr Maier offers a good idea that would take away much of a remaining issue -- the name "Temporary". I need to look into the functools library to see what "partial" does. -- Forwarded message - From: Wolfgang Maier Date: Mon, Oct 22, 2018 at 5:25 A

Re: [Tutor] What is the best way for a program suite to know where it is installed?

2018-10-22 Thread Mats Wichmann
On 10/20/18 9:00 PM, boB Stepp wrote: > I was just re-reading the entire thread at > https://www.mail-archive.com/tutor@python.org/msg77864.html > And I have asked similar questions previous to that thread. I still > do not have a satisfactory answer for the subject line's question that > both

Re: [Tutor] Fwd: Can tempfile.NamedTemporaryFile(delete=False) be used to create *permanent* uniquely named files?

2018-10-22 Thread Mats Wichmann
On 10/22/18 8:24 AM, boB Stepp wrote: > Forwarding to the Tutor list. Herr Maier offers a good idea that > would take away much of a remaining issue -- the name "Temporary". I > need to look into the functools library to see what "partial" does. if you really don't care what the file is called

Re: [Tutor] organisation of folder structure of Python'sinstallation directory

2018-10-22 Thread Malhar Lathkar
Is it possible to install just python runtime environment only similar to JRE? On Sun, 21 Oct 2018, 20:12 Mats Wichmann, wrote: > [image: Boxbe] Mats Wichmann ( > m...@wichmann.us) is not on your Guest List >

Re: [Tutor] organisation of folder structure of Python'sinstallation directory

2018-10-22 Thread Mats Wichmann
On 10/22/18 9:58 AM, Malhar Lathkar wrote: > Is it possible to install just python runtime environment only similar to > JRE? You could probably arrange it if you build your own, but there doesn't seem much point. I'm looking at a Windows system here with several Python versions installed; for a

Re: [Tutor] What is the best way for a program suite to know where it is installed?

2018-10-22 Thread boB Stepp
On Mon, Oct 22, 2018 at 9:47 AM Mats Wichmann wrote: > > On 10/20/18 9:00 PM, boB Stepp wrote: > > So far the best method I've come up with is to make use of "__file__" > > for the initiating program file. But from past discussions I am not > > certain this is the *best* way. Is the *best* way

Re: [Tutor] Fwd: Can tempfile.NamedTemporaryFile(delete=False) be used to create *permanent* uniquely named files?

2018-10-22 Thread boB Stepp
On Mon, Oct 22, 2018 at 11:57 AM Mats Wichmann wrote: > > On 10/22/18 8:24 AM, boB Stepp wrote: > > Forwarding to the Tutor list. Herr Maier offers a good idea that > > would take away much of a remaining issue -- the name "Temporary". I > > need to look into the functools library to see what "p

Re: [Tutor] Fwd: Can tempfile.NamedTemporaryFile(delete=False) be used to create *permanent* uniquely named files?

2018-10-22 Thread William Ray Wing via Tutor
> On Oct 22, 2018, at 8:30 PM, boB Stepp wrote: > > On Mon, Oct 22, 2018 at 11:57 AM Mats Wichmann wrote: >> >> On 10/22/18 8:24 AM, boB Stepp wrote: >>> Forwarding to the Tutor list. Herr Maier offers a good idea that >>> would take away much of a remaining issue -- the name "Temporary". I

Re: [Tutor] What is the best way for a program suite to know where it is installed?

2018-10-22 Thread eryk sun
On 10/22/18, boB Stepp wrote: > > Importing the various program modules/module contents is > no issue. Where I believe I need to know the paths to things are to > get to data folders, config files, and occasionally utility programs > that I have written that are on my hard drive, but not copied t

Re: [Tutor] What is the best way for a program suite to know where it is installed?

2018-10-22 Thread Cameron Simpson
On 22Oct2018 19:26, boB Stepp wrote: On Mon, Oct 22, 2018 at 9:47 AM Mats Wichmann wrote: As you've concluded by now, this isn't a completely trivial exercise, and you'll possibly get asked the question "why do you think you need to know that?". Actually no one has yet asked me this question