Python discussion: Difference between revisions

imported>Fadenb
m whitespace removal
m update url to wayback machine url
 
(2 intermediate revisions by 2 users not shown)
Line 1: Line 1:
{{Outdated|also, this article describes discussions from old days}}
== python basics ==
== python basics ==
* '''*.pth''' files
* '''*.pth''' files
:Python supports *.pth files which contain the paths to the parent directories of your python modules one per line. Those files are placed in site-packages and are typically generated by python package managers such as easy_install.
:Python supports *.pth files which contain the paths to the parent directories of your python modules one per line. Those files are placed in site-packages and are typically generated by python package managers such as easy_install.
* PYTHONPATH
* PYTHONPATH
:The other way is to set additional paths for the required modules before running python. This is done by setting the python paths in the environment variable PYTHONPATH. A path typcially looks like this on a Nix system: /nix/store/fxpfc2hyw5qbxly8xwrxzai8lny4pcq2-ipython-0.11/lib/python2.7/site-packages/ipython-0.11-py2.7.egg
:The other way is to set additional paths for the required modules before running python. This is done by setting the python paths in the environment variable PYTHONPATH. A path typically looks like this on a Nix system: /nix/store/fxpfc2hyw5qbxly8xwrxzai8lny4pcq2-ipython-0.11/lib/python2.7/site-packages/ipython-0.11-py2.7.egg
* PYTHONUSERBASE
* PYTHONUSERBASE
:?
:?
Line 22: Line 23:


=== packaging virt-manager ===
=== packaging virt-manager ===
see '''problem 2''' in [http://permalink.gmane.org/gmane.linux.distributions.nixos/8732]
see '''problem 2''' in [https://web.archive.org/web/20150406220317/https://permalink.gmane.org/gmane.linux.distributions.nixos/8732]


=== python-gudev ===
=== python-gudev ===