[Cubicweb] Foaf implementation

St├ęphane Bugat stephane.bugat at free.fr
Wed Jul 18 16:49:07 CEST 2012


> A unittest would allow us to easily reproduce your pb. Quickly
> looking at
> your code, I see at least one potential infinite loop in
> syncUserPersonHook:
> you edit a user, hook edits related person, hook edits related user,
> etc.

You are probably right: the conflict should lie here.

> Tip (probably undocumented): add 'category = "synchronization" to
> your hook.
> then, call set_attributes withing a
> 
>   with self._cw.allow_all_hooks_but("synchronization"):
>       x.set_attributes(...)
> 
> block. This would probably also apply to email sync hook.

Another good undocumented tip! I'll try this.

Thanks for help



More information about the Cubicweb mailing list