Opened 18 years ago
Closed 17 years ago
#7008 closed defect (worksforme)
TypeError in self-compiled svn bindings for CentOS 5
| Reported by: | Owned by: | Christian Boos | |
|---|---|---|---|
| Priority: | normal | Milestone: | |
| Component: | version control | Version: | |
| Severity: | normal | Keywords: | needinfo | 
| Cc: | carlos@… | Branch: | |
| Release Notes: | |||
| API Changes: | |||
| Internal Changes: | |||
Description
After installing trac i try running trac-admin to create a new environment and get the following error message:
Failed to initialize environment. argument number 1: a 'apr_pool_t *' is expected, 'PySwigObject()' is received
Traceback (most recent call last):
  File "/usr/local/lib/python2.5/site-packages/Trac-0.11b2-py2.5.egg/trac/admin/console.py", line 559, in do_initenv
    repos = self.__env.get_repository()
  File "/usr/local/lib/python2.5/site-packages/Trac-0.11b2-py2.5.egg/trac/env.py", line 263, in get_repository
    return RepositoryManager(self).get_repository(authname)
  File "/usr/local/lib/python2.5/site-packages/Trac-0.11b2-py2.5.egg/trac/versioncontrol/api.py", line 142, in get_repository
    repos = self._connector.get_repository(rtype, rdir, authname)
  File "/usr/local/lib/python2.5/site-packages/Trac-0.11b2-py2.5.egg/trac/versioncontrol/svn_fs.py", line 277, in get_repository
    'branches': self.branches})
  File "/usr/local/lib/python2.5/site-packages/Trac-0.11b2-py2.5.egg/trac/versioncontrol/svn_fs.py", line 385, in __init__
    self.pool = Pool()
  File "/usr/local/lib/python2.5/site-packages/Trac-0.11b2-py2.5.egg/trac/versioncontrol/svn_fs.py", line 151, in __init__
    self._pool = core.svn_pool_create(self._parent_pool())
  File "/usr/local/lib/svn-python/svn/core.py", line 177, in svn_pool_create
    return Pool(parent_pool)
  File "/usr/local/lib/svn-python/libsvn/core.py", line 1137, in svn_pool_create
    return apply(_core.svn_pool_create, args)
TypeError: argument number 1: a 'apr_pool_t *' is expected, 'PySwigObject()' is received
Subversion is functioning normally, running on apache 2.2.8
Trac: 0.11b2 Subversion: 1.4.2 System: CentOS 5 (kernel 2.6.18-53.1.6.el5)
Attachments (0)
Change History (5)
comment:1 by , 18 years ago
| Summary: | trac-admin fails to create env → TypeError in self-compiled svn bindings for CentOS 5 | 
|---|
comment:2 by , 18 years ago
| Keywords: | needinfo added | 
|---|
comment:3 by , 17 years ago
I'm trying to configure trac 0.11rc1 with Python 2.5.1, svn 1.4.4, SWIG 1.3.33 and PostgreSQL as backend. I go all the way to trac-admin /xxx initenv, but then it fails with "TypeError: argument number 1: a 'apr_pool_t *' is expected, 'PySwigObject(��T)' is received" (see paste below) Although my Python 2.5 and SWIG/SVN are Fedora Core 8 stock.
I also got this on the Python interpreter:
>>> from svn import core
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/usr/lib/svn-python/svn/core.py", line 19, in <module>
    from libsvn.core import *
  File "/usr/lib/svn-python/libsvn/core.py", line 5, in <module>
    import _core
ImportError: /usr/lib/libsvn_fs_base-1.so.0: undefined symbol: db_create
This mail message says it happens so because Subversion was compiled with BerkeleyDB support disabled. I don't actually need it since my SVN is set to fsfs.
Is there a way I can make it work like this or what should I do if not?
comment:5 by , 17 years ago
| Resolution: | → worksforme | 
|---|---|
| Status: | new → closed | 
Not a Trac issue, but a problem with the bindings.
First thing to test is that they should be usable properly outside of Trac. See TracSubversion#Troubleshooting for more.



  
Hmm. This isn't a duplicate of #4165 as no mod_python is involved.
I have a buildbot running something similar.
python-2.4.3-19.el5) in/usr/lib64/python2.4subversion-1.4.2-2.el5) in/usr/lib64/python2.4/site-packages/svnIt looks like you've compiled Python 2.5 and the Subversion bindings yourself in /usr/local. My guess is something went wrong in the configure step for swig. Can you check
config.logfor it and confirm that it points at the correct Python version?