About /afs/slac/g/lcls/tools/python/
----------------------------------------
This directory is meant to hold Python packages for the LCLS project.
CVS
----------------------------------------
Commit SLAC-built packages to LCLS CVSROOT/tools/python/slac-packages/<package name>
Commit 3rd party packages to LCLS CVSROOT/tools/python/external-packages/<package name>
Tag packages as py_<package name>-RX-Y-Z
Check out tagged packages to $TOOLS/python/pythonx.y.z/xxxx-packages/<package name>_RX_Y_Z
Search Path
----------------------------------------
"$TOOLS/python/pythonx.y.z/slac-packages" and "$TOOLS/python/pythonx.y.z/external-packages" should be a part of your Python package search path. You can run the search path test script to verify your search path.
$ python $TOOLS/python/modulesearchpathtest.py
Importing Modules
----------------------------------------
The slac-packages and external-packages directories should be in your Python search path (see above).
You can specify which release of a Python package to use at import.
Example:
import subprocessca_R1_0_0 as subprocessca
scripts
------------
Simple python scripts can be released to tools/python/scripts
More Information
----------------------------------------
Python modules: http://docs.python.org/tutorial/modules.html
Style Guide for Python Code: http://www.python.org/dev/peps/pep-0008/
Code Like a Pythonista: http://python.net/~goodger/projects/pycon/2007/idiomatic/handout.html