revisiting the "What am I running on?" question
songbird at anthive.com
Wed Feb 20 08:39:58 EST 2019
Chris Angelico wrote:
> songbird wrote:
>> no win64?
> The value "win32" means Windows (or, more technically, "Windows NT
> family", as opposed to Win95/Win98 - but since Win XP, that's the only
> type of Windows there is). If you actually care about whether it's a
> 32-bit or 64-bit OS, you can look at sys.maxsize.
i'm not sure what system my code will actually
run on or not. i got rid of my old hardware as
part of a cleanup so i can't test things like
that anymore without some kind of emulator or
other kind people.
at present i just want to know what kind of
system i am running on so i can put my configuration
file and saved games in the correct places.
if i can't determine what kind of system i am
running on then i won't run at all (instead of
risking creating a directory or file on a system
that doesn't have such ways of doing that - i
really don't know what people may attempt after
>> no arm(s)?
> That's a CPU architecture. What OS would you be running on your ARM?
> If it's Windows, "win32". If it's Linux, "linux". Etc.
ok. since i never have such things to try i
don't always know what they run or how it looks
to a python3 program.
anyways, one thing i do like about an actual
probe of the temporary kind is that i can answer
the question of:
"Do I have temporary directory and file creation
permissions on this system or not?"
a more accurate answer for any longer term storage
would tell me if i have more permanent directory and
file creation permissions or not, but my program
doesn't require those since it will run without a
configuration file or any saved games.
More information about the Python-list