Many of these utilities (or their ancestors) were developed for the Mojo Nation, Mnet, Allmydata.com “Mountain View”, Tahoe-LAFS, or SimpleGeo’s products. (In the case where the code was developed for a for-profit company, the copyright holder donated the pyutil code to the public under these open source licences.)

Thanks to Peter Westlake and Ravi Pinjala for help documenting what these do.

I no longer use these and I don’t recommend that you do either.

I don’t currently use these, but I still think they are possibly good ideas.

These are useful! Use them.

(To get the latest source, run darcs get --lazy http://tahoe-lafs.org/source/pyutil/trunk .)

tests and benchmarks

To run tests: python ./setup.py trial -s pyutil.test.current .

You can also run the tests with the standard pyunit test runner instead of trial, but a couple of the tests will fail due to the absence of Trial’s “Skip This Test” feature. You can also run the tests of the out-of-shape and deprecated modules:

python ./setup.py trial -s pyutil.test.out_of_shape

python ./setup.py trial -s pyutil.test.deprecated

Or of all modules:

python ./setup.py trial -s pyutil.test

Some modules have self-benchmarks provided. For example, to benchmark the cache module: python -OOu -c 'from pyutil.test import test_cache; test_cache.quick_bench()'

or for more complete and time-consuming results: python -OOu -c 'from pyutil.test import test_cache; test_cache.slow_bench()'

(The “-O” is important when benchmarking, since cache has extensive self-tests that are optimized out when -O is included.)