Statistics
| Branch: | Tag: | Revision:

root / lib / utils @ 7142485a

Name Size
__init__.py 22 kB
algo.py 7.3 kB
filelock.py 5 kB
hash.py 2.4 kB
io.py 28.2 kB
log.py 8.4 kB
mlock.py 2.3 kB
nodesetup.py 3.4 kB
process.py 28.6 kB
retry.py 6.2 kB
text.py 14.8 kB
wrapper.py 5 kB
x509.py 9.4 kB

Latest revisions

# Date Author Comment
81f7ea25 03/09/2012 04:46 pm Iustin Pop

Fix lint error in commit 035b33e2

Commit 035b33e2 forgot one blank space, and current pylint in Debian
Sid doesn't run on our code… so I didn't realise this until after
commit, sorry.

Signed-off-by: Guido Trotter <>
Reviewed-by: Guido Trotter <>

035b33e2 03/07/2012 10:59 pm Iustin Pop

Fix tempfile reset code & test on newer Python

Python 2.7.3 (rc status) and 3.2.3/3.3 (rc, respectively alpha status)
have fixed http://bugs.python.org/issue12856 which we worked around
ourselves.

This means two things:

- we don't need to manually reset the module...

3ccb3a64 02/21/2012 05:23 pm Michael Hanselmann

Replace single- with double-quotes

In at least two cases "%s" is replaced with str(), too.

Signed-off-by: Michael Hanselmann <>
Reviewed-by: Iustin Pop <>

5401c39d 02/17/2012 05:39 pm Michael Hanselmann

utils.text: Add function to truncate string

The function adds an ellipse if the string was actually truncated. Also
start using it in mcpu for result checks (where the message is also
slightly changed to use a colon).

Signed-off-by: Michael Hanselmann <>...

59d81cb3 01/19/2012 03:14 pm Michael Hanselmann

Merge branch 'devel-2.5'

  • devel-2.5:
    Fix wrong option names in QA and cluster-merge
    Bump version to 2.5.0~rc5, update NEWS
    Add UnescapeAndSplit unittest for multi-escapes
    Fix a bug in command line option parsing code
    cli: Disable abbreviation matching for options...
ecabe27e 01/19/2012 02:42 pm Nikos Skalkotos

Fix a bug in command line option parsing code

Fix bug affecting command line options of "keyval" type. Although
escaping commands with \ is supported, it is is not applied to the
input recursively.

Signed-off-by: Nikos Skalkotos <>
Signed-off-by: Iustin Pop <>...

380bb53a 01/10/2012 05:16 pm Michael Hanselmann

utils.ResetTempfileModule: Improve performance

This function is called for after every fork (e.g. for handling an RPC
request). With the changes in this patch generating the next random
filename is about 30% faster.

Signed-off-by: Michael Hanselmann <>...

2635bb04 01/06/2012 01:34 pm Michael Hanselmann

Move helper class from watcher to utils.io

“FileStatHelper” can be used together with “ReadFile” to a file's status
while it's opened. This avoids certain race conditions.

Signed-off-by: Michael Hanselmann <>
Reviewed-by: Iustin Pop <>

aa66c183 12/22/2011 07:16 pm Michael Hanselmann

Merge branch 'devel-2.5'

  • devel-2.5:
    jqueue: Factorize checking job processor's result
    jqueue unittest: Rename simple fake-job class
    jqueue: Fix epylint errors introduced in 37d76f1e4
    jqueue: Fix deadlock between job queue and dependency manager...
eea3b572 12/22/2011 03:12 pm Bernardo Dal Seno

noded: Fix /etc/hosts group ownership

When Ganeti was compiled with the option of running as a different
user/group, the group ownership of /etc/hosts was set to gnt-daemons. Now
permissions for /etc/hosts are preserved (or set correctly).

Signed-off-by: Bernardo Dal Seno <>...

View revisions

Also available in: Atom