[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Hooking python callback functions to a svn_client_ctx_t

From: Philipp von Weitershausen <philipp_at_weitershausen.de>
Date: 2003-05-05 21:50:14 CEST

Hello everyone,

I pretty much find my way around the python bindings. Accessor functions
aren't cool if you're used to python, but we don't have anything better
(yet; I'm working on it ;))

One thing got me stumbling, though. Consider the following python code:

------snip------
from svn import client, util

def cancel_func(cancel_baton):
     pass

pool = util.svn_pool_create(None)
ctx = client.new_svn_client_ctx_t()
client.svn_client_ctx_t_cancel_func_set(ctx, cancel_func)
------snip------

This code will throw the following exception:
TypeError: Type error. Expected _svn_cancel_func_t

Sure, I can see in svn_client.h that svn_client_ctx_t wants a
svn_cancel_func_t, but if the above does not work, how can I hook my
python callbacks up to the client context?

Cheers,
Phil

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Mon May 5 21:54:31 2003

This is an archived mail posted to the Subversion Dev mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.