我最近更新我的服务器使用apt-get upgrade
,然后突然trac开始显示以下错误信息:
Warning: Can't synchronize with repository "(default)" (Unsupported version control system "svn": No module named svn). Look in the Trac log for more information.
我试图安装python-subversion
,但已经安装,所以我已经重新安装它,但是没有帮助。
~# python Python 2.7.2+ (default, Oct 4 2011, 20:06:09) [GCC 4.6.1] on linux2 Type "help", "copyright", "credits" or "license" for more information. >>> import svn Traceback (most recent call last): File "<stdin>", line 1, in <module> ImportError: No module named svn
我在ubuntu 11.10 x64上运行svn 1.7.4。
我不太了解python。 为什么不能findSVN了?
我也尝试使用sudo apt-get install python-svn
。 这也没有帮助。
我在Ubuntu 12.04上遇到类似的问题。 我使用WANdisco软件包将subversion升级到1.7.5。 这个包将svn绑定到python2.6,而Ubuntu 12.04有python2.7。
这是一个解决了我的问题的脚本:
mkdir /usr/lib/python2.7/dist-packages/libsvn for f in /usr/lib/pyshared/python2.6/libsvn/*; do ln -s $f /usr/lib/python2.7/dist-packages/libsvn/; done for f in /usr/share/pyshared/libsvn/*; do ln -s $f /usr/lib/python2.7/dist-packages/libsvn/; done mkdir /usr/lib/python2.7/dist-packages/svn for f in /usr/share/pyshared/svn/*; do ln -s $f /usr/lib/python2.7/dist-packages/svn/; done mkdir /usr/lib/pyshared/python2.7/libsvn for f in /usr/lib/pyshared/python2.6/libsvn/*; do ln -s $f /usr/lib/pyshared/python2.7/libsvn/; done
最好的问候Wojciech 12月
你只需要用apt-get来安装它们
apt-get update apt-get install python-svn
python-svn安装的python模块叫做pysvn。 显然,Trac需要一个SWIG绑定。 看到
对我来说,以下帮助:
apt-get install python-svn apt-get install python-subversion
然后一切正常。