[Python-Dev] Fixing #7175: a standard location for Python config files

Michael Foord fuzzyman at voidspace.org.uk
Thu Aug 12 13:17:49 CEST 2010


On 12/08/2010 11:54, Tim Golden wrote:
> On 12/08/2010 11:40, Michael Foord wrote:
>> User editable configuration files are very different from libraries. The
>> per user site-packages folder *should* be hidden somewhere out of the
>> way where you can get at them if you want them but won't stumble across
>> them all the time. e.g. AppData on Windows.
>>
>> For files we expect the user to be able to edit we shouldn't go out of
>> our way to make them hard or inconvenient to find.
>
> This really comes down -- as with the Mac discussion last week, I
> think -- to the tension between standard file locations and 
> easy-to-get-to.
> The difference on Windows, though, is that while on Mac it's either:
> Apple standard /This/That/TheOther vs Unix standard $HOME/.something
> on Windows it's %APPDATA%\myprog vs whatever-I-thought-of-at-the-time.
>
> APPDATA isn't actually that hard to get to on any version of Windows
> post 2000. (Just stick %APPDATA% into any Explorer window -- even
> IE, for goodness sake). Even from the command line it's not hard:
>
> notepad "%APPDATA%\python\python26\idle.ini"
>
> Ultimately, as a Windows user/developer, I'd vote for a memorable
> consistency, which for me would be %APPDATA%\python\... If everything's
> in one place, I'll just create a shortcut / hardlink / whatever to get
> me there when I want to change things.


How is ~/python not memorable or consistent? (And cross-platform 
memorability and consistency is valuable too.)

Another issue is discoverability. Many users won't know about these 
config files unless they *see* them. Sure if you *know* where they are 
then editing them is easy - but how often as a user do you browse your 
AppData folder? (As a windows user the only times I went delving in this 
mysterious location was trying to diagnose obscure errors.)

I'm not aware of any consistent pattern of putting *user editable* files 
in AppData, and I doubt this is where most users would look for them. In 
fact for Windows the *correct* thing to do is probably to use the 
registry and then provide a graphical tool for editing the values. If 
you're arguing for consistency why not argue for this? If we were to 
provide native GUI tools for editing values then the location suggested 
by Ronald for the Mac (which is the standard location for preferences 
files maintained by GUI tools) would also be the right location.

All the best,

Michael

>
> TJG
> _______________________________________________
> Python-Dev mailing list
> Python-Dev at python.org
> http://mail.python.org/mailman/listinfo/python-dev
> Unsubscribe: 
> http://mail.python.org/mailman/options/python-dev/fuzzyman%40voidspace.org.uk 
>


-- 
http://www.ironpythoninaction.com/
http://www.voidspace.org.uk/blog

READ CAREFULLY. By accepting and reading this email you agree, on behalf of your employer, to release me from all obligations and waivers arising from any and all NON-NEGOTIATED agreements, licenses, terms-of-service, shrinkwrap, clickwrap, browsewrap, confidentiality, non-disclosure, non-compete and acceptable use policies (”BOGUS AGREEMENTS”) that I have entered into with your employer, its partners, licensors, agents and assigns, in perpetuity, without prejudice to my ongoing rights and privileges. You further represent that you have the authority to release me from any BOGUS AGREEMENTS on behalf of your employer.




More information about the Python-Dev mailing list