Edgewall Software
Modify

Opened 16 years ago

Closed 15 years ago

#7008 closed defect (worksforme)

TypeError in self-compiled svn bindings for CentOS 5

Reported by: ta_nik@… 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 Tim Hatch, 16 years ago

Summary: trac-admin fails to create envTypeError 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?

comment:2 by sid, 16 years ago

Keywords: needinfo added

comment:3 by anonymous, 16 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:4 by carlos@…, 16 years ago

Cc: carlos@… added

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

comment:5 by Christian Boos, 15 years ago

Resolution: worksforme
Status: newclosed

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.

Modify Ticket

Change Properties
Set your email in Preferences
Action
as closed The owner will remain Christian Boos.
The resolution will be deleted. Next status will be 'reopened'.
to The owner will be changed from Christian Boos to the specified user.

Add Comment


E-mail address and name can be saved in the Preferences .
 
Note: See TracTickets for help on using tickets.