Edgewall Software

Ticket #7008 (closed defect: worksforme)

Opened 8 months ago

Last modified 4 weeks ago

TypeError in self-compiled svn bindings for CentOS 5

Reported by: ta_nik@… Owned by: cboos
Priority: normal Milestone:
Component: version control Version:
Severity: normal Keywords: needinfo
Cc: carlos@…

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

Change History

Changed 8 months ago by thatch

  • summary changed from trac-admin fails to create env to TypeError in self-compiled svn bindings for CentOS 5

Hmm. This isn't a duplicate of #4165 as no mod_python is involved.

I have a buildbot running something similar.

  • CentOS 5 (64-bit)
  • python 2.4.3 (python-2.4.3-19.el5) in /usr/lib64/python2.4
  • svn 1.4.2 (subversion-1.4.2-2.el5) in /usr/lib64/python2.4/site-packages/svn
  • Latest source:sandbox/testing branch which was just merged to 0.11b2.

It 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.log for it and confirm that it points at the correct Python version?

Changed 8 months ago by sid

  • keywords needinfo added

Changed 6 months ago by anonymous

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?

Changed 6 months ago by carlos@…

  • cc carlos@… added

Please add me to Cc as I see it disabled for me.

Changed 4 weeks ago by cboos

  • status changed from new to closed
  • resolution set to worksforme

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.

Add/Change #7008 (TypeError in self-compiled svn bindings for CentOS 5)

Author



Change Properties
<Author field>
Action
as closed
Next status will be 'reopened'
to The owner will change from cboos. Next status will be 'closed'
 
Note: See TracTickets for help on using tickets.