I'm trying to use the log-police.py script from tools/hook-scripts but
when i try to use as pre-commit hook i get this error:
Traceback (most recent call last):
File "/var/svn/repositories/test/hooks/log-police.py", line 140, in ?
sys.exit(svn.core.run_app(main, sys.argv))
File "/opt/CollabNet_Subversion/lib/svn-python/svn/core.py", line 288,
in run_app
return apply(func, (application_pool,) + args, kw)
File "/var/svn/repositories/test/hooks/log-police.py", line 122, in main
fix_txn(fs, txn_name)
File "/var/svn/repositories/test/hooks/log-police.py", line 43, in fix_txn
txn = svn.fs.svn_fs_open_txn(fs, txn_name)
File "/opt/CollabNet_Subversion/lib/svn-python/libsvn/fs.py", line
209, in svn_fs_open_txn
return apply(_fs.svn_fs_open_txn, args)
svn.core.SubversionException: ('No such transaction', 160007)
svn: MERGE of '/svn/test/test': 409 Conflict (https://svnesel.eng.it)
Thi is the call to the script in the pre-commit hook:
#!/bin/sh
REPOS="$1"
TXN="$2"
log-police.py -t "$TNX" "$REPOS"
If I try to use it at command line giving the revision number instead of
the transaction id the script execute successfully:
./log-police.py -r 12345 /path/to/repos
In both cases I get also some warnings:
/opt/CollabNet_Subversion/lib/svn-python/libsvn/fs.py:7: RuntimeWarning:
Python C API version mismatch for module _fs: This Python has API
version 1012, module _fs has version 1011.
import _fs
/opt/CollabNet_Subversion/lib/svn-python/libsvn/fs.py:7: RuntimeWarning:
Python C API version mismatch for module swig_runtime_data3: This Python
has API version 1012, module swig_runtime_data3 has version 1011.
import _fs
/opt/CollabNet_Subversion/lib/svn-python/libsvn/core.py:7:
RuntimeWarning: Python C API version mismatch for module _core: This
Python has API version 1012, module _core has version 1011.
import _core
/opt/CollabNet_Subversion/lib/svn-python/libsvn/delta.py:7:
RuntimeWarning: Python C API version mismatch for module _delta: This
Python has API version 1012, module _delta has version 1011.
import _delta
/opt/CollabNet_Subversion/lib/svn-python/libsvn/repos.py:7:
RuntimeWarning: Python C API version mismatch for module _repos: This
Python has API version 1012, module _repos has version 1011.
import _repos
What is the problem? Am I doing something wrong?
Andrea
------------------------------------------------------
http://subversion.tigris.org/ds/viewMessage.do?dsForumId=1065&dsMessageId=983310
To unsubscribe from this discussion, e-mail: [users-unsubscribe_at_subversion.tigris.org].
Received on 2008-12-12 19:57:07 CET