title: Where to put a config file for a compiled Python script?
body: <p>This is similar to <a href="https://stackoverflow.com/q/7567642/125507">Where to put a configuration file in Python?</a>, but I'm asking about scripts compiled/frozen with py2exe or similar on Windows systems.  (Namely, this one: <a href="https://stackoverflow.com/q/9687841/125507">What config file format to use for user-friendly strings of arbitrary bytes?</a> <a href="https://gist.github.com/1119561" rel="nofollow noreferrer">https://gist.github.com/1119561</a>)</p>
  
  <p>My first thought was to put the config file in the same folder as the .exe, which makes it sort of self-contained.  But if I associate files with the .exe, it will be called from their directory, not its own, so I'd need something like <a href="https://stackoverflow.com/q/2632199/125507">How do I get the path of the current executed file in Python?</a> to find the config file.</p>
  
  <p>Is this the best way?  Or is there some standard config file locations to search in, like <a href="https://stackoverflow.com/a/7567946/125507">https://stackoverflow.com/a/7567946/125507</a> ?</p>