Discussion:
Major update to sync-engine...
Dr J A Gow
2007-12-19 23:40:18 UTC
Permalink
Folks,

Here is the major update to sync-engine that I have been using for the
last few days. The basic details are in the excerpt from the changelog
below.

Have fun

John.

19/12/2007 - 231400 Dr J A Gow
------------------------------

IMPORTANT - IF USING AN EARLIER VERSION THAN THIS, EXCEPT FOR config.xml
PLEASE DELETE THE CONTENTS OF YOUR ~/.synce DIRECTORY INCLUDING THE
partnerships SUBDIRECTORY . AND RECREATE YOUR PARTNERSHIPS.

What's changed? Lots. The partnership code has been considerably
overhauled with a view to getting rid of some serious flaws in the old
code. The partnership concept is now split into two parts: the
partnership on the phone and the 'binding' on the host. Both must exist
and match to create a partnership. It is now possible to bind
successfully with multiple devices (although not at once). Syncing can
only occur with a bound partnership. This process is transparent to the
user.

Unfortunately the bug with deletion of Exchange Server partnerships is
still present -the workaround is to create the partnership with
sync-engine first.

We now have per-partnership configuration! - Look at
configure_bindings.py in the tools directory.

delete_partnership.py no longer needs the user to phaff about with
running list_partnerships.py and grabbing long hex numbers. It directly
presents the user with a list selectable by index.

select_partnership.py has gone, it is no longer needed with the new
code. Selection will occur automatically, properly, when the device is
connected.

DTPT has now been fully implemented in sync-engine and should be turned
on by default, and should 'just work' for WM5 and WM6. It can be turned
off globally in config.xml, or on a per-partnership basis with
configure_bindings.py.

Some bugs fixed in the OpenSync 0.3x conversion code, but it continues
to be experimental at this time. Opensync 0.2x should be generally
reliable.

The item data pathway has been de-convoluted and made a lot more obvious
and cleaner. Look at syncdb.py for more info. I will try and document
this a bit later.
Guido Diepen
2007-12-20 10:57:40 UTC
Permalink
Post by Dr J A Gow
Folks,
Here is the major update to sync-engine that I have been using for the
last few days. The basic details are in the excerpt from the changelog
below.
One word: WOW :)

I had an idea for a very small improvement.

One of the things I saw is that sync-engine still needs the odccm to be
running, otherwise you will get lots of errors about odccm not being present
on dbus.

The same was for the small example program synce-gnome/test.py which notifies
you when a device is (un)plugged. I just commited a patch for this that will
look whether odccm is present on dbus, if not, it will still start, but
starts looking on the dbus for messages indicating odccm was started.

Since the synce-gnome/test.py was quite small I could do this plus I don't
want to start patching your sync-engine stuff, therefor I mention this patch
to you :) Maybe it is an idea to implement something like that in sync-engine
also?

Regards,

Guido Diepen
--
Aviation is proof that given the will, we have the
capacity to achieve the impossible.
--Eddie Rickenbacker
Dr J A Gow
2007-12-21 18:37:17 UTC
Permalink
Post by Guido Diepen
Post by Dr J A Gow
Folks,
Here is the major update to sync-engine that I have been using for the
last few days. The basic details are in the excerpt from the changelog
below.
One word: WOW :)
I had an idea for a very small improvement.
One of the things I saw is that sync-engine still needs the odccm to be
running, otherwise you will get lots of errors about odccm not being present
on dbus.
The same was for the small example program synce-gnome/test.py which notifies
you when a device is (un)plugged. I just commited a patch for this that will
look whether odccm is present on dbus, if not, it will still start, but
starts looking on the dbus for messages indicating odccm was started.
Since the synce-gnome/test.py was quite small I could do this plus I don't
want to start patching your sync-engine stuff, therefor I mention this patch
to you :) Maybe it is an idea to implement something like that in sync-engine
also?
Patch away! Anything to lose error messages like these is a good
thing :)

I won't be working on this specific part of sync-engine for at least a
week or so, so we shouldn't tread on each others toes. My next step is
to clean up the code in airsync.py and kernel.py, but as I say this
won't be for at least a week so feel free to add this.

John.
Guido Diepen
2007-12-22 01:37:00 UTC
Permalink
Post by Dr J A Gow
Patch away! Anything to lose error messages like these is a good
thing :)
Again, since multiple people are using the sync-engine regularly and I don't
want to commit something that will break the code, I supply the patch
manually. The reason for this is that i just started last week with python
and I want to be sure that what is svn still keeps working ;) I am pretty
sure that it is, but since I currently really need the exchange partnership
not to be deleted, I can't fully test it right now (i did some preliminary
tests with added return statements in the device_(dis)connect_cb functions
and they seemed to work without a problem). I will test that exchange
partnership problem later on for you though :)

Could you verify the attached patch and if it is working, could you either
notify me, and I will feel free to commit it :), or commit it yourself,
whatever is the easiest for you.

Regards,

Guido Diepen
--
Aviation is proof that given the will, we have the
capacity to achieve the impossible.
--Eddie Rickenbacker
Dr J A Gow
2007-12-22 13:16:17 UTC
Permalink
Post by Guido Diepen
Post by Dr J A Gow
Patch away! Anything to lose error messages like these is a good
thing :)
Again, since multiple people are using the sync-engine regularly and I don't
want to commit something that will break the code, I supply the patch
manually. The reason for this is that i just started last week with python
and I want to be sure that what is svn still keeps working ;) I am pretty
sure that it is, but since I currently really need the exchange partnership
not to be deleted, I can't fully test it right now (i did some preliminary
tests with added return statements in the device_(dis)connect_cb functions
and they seemed to work without a problem). I will test that exchange
partnership problem later on for you though :)
Could you verify the attached patch and if it is working, could you either
notify me, and I will feel free to commit it :), or commit it yourself,
whatever is the easiest for you.
Looks basically sane and seems to work well here! Thanks for that patch,
I have committed it in r3115 along with a little fix that should stop
Exchange server partnerships being clobbered - if you could verify this
at your end I would be grateful, also let me know if you see any adverse
effects.

Now I just need to find a way to stop Opensync cleanly if a user tries
to start one without either odccm running or a device connected. This
should be straightforward with Opensync 0.3x but is a bit more
problematic with the earlier versions....

John.
Iain Buchanan
2007-12-21 01:24:14 UTC
Permalink
Post by Dr J A Gow
Folks,
Here is the major update to sync-engine that I have been using for the
last few days. The basic details are in the excerpt from the changelog
below.
cooooooool! The Dr is IN!

Can I make a gentoo snapshot now?

Also, should select_partnership.py be removed from setup.py ?

thanks heaps!
--
Iain Buchanan <iaindb at netspace dot net dot au>

As you grow older, you will still do foolish things, but you will do
them
with much more enthusiasm.
-- The Cowboy
Dr J A Gow
2007-12-21 18:29:56 UTC
Permalink
Post by Iain Buchanan
Can I make a gentoo snapshot now?
Also, should select_partnership.py be removed from setup.py ?
Yes, go for it! Also go ahead and remove select_partnership.py from
setup.py - I always manage to forget to update setup.py.....

John.
Jonny Lamb
2007-12-22 00:05:47 UTC
Permalink
Post by Dr J A Gow
Post by Iain Buchanan
Also, should select_partnership.py be removed from setup.py ?
Yes, go for it! Also go ahead and remove select_partnership.py from
setup.py - I always manage to forget to update setup.py.....
Committed in r3113.
--
Jonny Lamb, UK ***@jonnylamb.com
http://jonnylamb.com GPG: 0x2E039402
Guido Diepen
2007-12-22 13:21:36 UTC
Permalink
Hi john,

I just had some spare minutes to look into the exchange thingy again.
Unfortunately, it doesn't matter when I create the partnership with an
exchange server, it is always deleted by the sync-engine. The reason for this
is that it looks like it never creates a P1 or P2 or whatever directory.

Could it just be that an exchange server does not need a P. subkey in the
Partners registry key?

Furthermore, I started looking into those provisioning documents and created a
small program that I can use to fetch info from the device through such
documents (Python is really cool :) ). I decided to look at the information
that was present about the charac. Sync when I had both partnerships
(Exchange and Linux with only files) installed on the device (i.e. I did not
have sync-engine running anymore ;) )

Attached to this email you will find the reply provisioning doc I got. What
struck me as odd is that there is a difference in "StoreType" parm. For the
AS connection to linux, this is two, while for the Exchange it is 3. Could
this be something? Do you know If you have multiple partnerships with linux,
they all have storetype 2?

Regards,

Guido Diepen
Post by Dr J A Gow
19/12/2007 - 231400 Dr J A Gow
------------------------------
IMPORTANT - IF USING AN EARLIER VERSION THAN THIS, EXCEPT FOR config.xml
PLEASE DELETE THE CONTENTS OF YOUR ~/.synce DIRECTORY INCLUDING THE
partnerships SUBDIRECTORY . AND RECREATE YOUR PARTNERSHIPS.
What's changed? Lots. The partnership code has been considerably
overhauled with a view to getting rid of some serious flaws in the old
code. The partnership concept is now split into two parts: the
partnership on the phone and the 'binding' on the host. Both must exist
and match to create a partnership. It is now possible to bind
successfully with multiple devices (although not at once). Syncing can
only occur with a bound partnership. This process is transparent to the
user.
Unfortunately the bug with deletion of Exchange Server partnerships is
still present -the workaround is to create the partnership with
sync-engine first.
We now have per-partnership configuration! - Look at
configure_bindings.py in the tools directory.
delete_partnership.py no longer needs the user to phaff about with
running list_partnerships.py and grabbing long hex numbers. It directly
presents the user with a list selectable by index.
select_partnership.py has gone, it is no longer needed with the new
code. Selection will occur automatically, properly, when the device is
connected.
DTPT has now been fully implemented in sync-engine and should be turned
on by default, and should 'just work' for WM5 and WM6. It can be turned
off globally in config.xml, or on a per-partnership basis with
configure_bindings.py.
Some bugs fixed in the OpenSync 0.3x conversion code, but it continues
to be experimental at this time. Opensync 0.2x should be generally
reliable.
The item data pathway has been de-convoluted and made a lot more obvious
and cleaner. Look at syncdb.py for more info. I will try and document
this a bit later.
-------------------------------------------------------------------------
Check out the new SourceForge.net Marketplace.
It's the best place to buy or sell services
for just about anything Open Source.
http://ad.doubleclick.net/clk;164216239;13503038;w?http://sf.net/marketplac
e _______________________________________________
SynCE-Devel mailing list
https://lists.sourceforge.net/lists/listinfo/synce-devel
--
Aviation is proof that given the will, we have the
capacity to achieve the impossible.
--Eddie Rickenbacker
Dr J A Gow
2007-12-22 13:34:16 UTC
Permalink
Post by Guido Diepen
Hi john,
I just had some spare minutes to look into the exchange thingy again.
Unfortunately, it doesn't matter when I create the partnership with an
exchange server, it is always deleted by the sync-engine. The reason for this
is that it looks like it never creates a P1 or P2 or whatever directory.
Could it just be that an exchange server does not need a P. subkey in the
Partners registry key?
I think this is correct, as you can have two AS partnerships and still
have a third Exchange one.
Post by Guido Diepen
Furthermore, I started looking into those provisioning documents and created a
small program that I can use to fetch info from the device through such
documents (Python is really cool :) ). I decided to look at the information
that was present about the charac. Sync when I had both partnerships
(Exchange and Linux with only files) installed on the device (i.e. I did not
have sync-engine running anymore ;) )
Attached to this email you will find the reply provisioning doc I got. What
struck me as odd is that there is a difference in "StoreType" parm. For the
AS connection to linux, this is two, while for the Exchange it is 3. Could
this be something? Do you know If you have multiple partnerships with linux,
they all have storetype 2?
I wondered about this a while back but needed to confirm that the
StoreType was also set to 2 for a partnership created by AS/Windows.
It's on my to-do list to test.However, along with your patch I have just
committed a quick workaround for this exchange-deletion problem by
simply not deleting dangling partnerships. This should work until I can
establish the exact meaning of the StoreType by confirmation with a
Windows system.

John.
Guido Diepen
2007-12-22 13:43:56 UTC
Permalink
Post by Dr J A Gow
Post by Guido Diepen
Could it just be that an exchange server does not need a P. subkey in the
Partners registry key?
I think this is correct, as you can have two AS partnerships and still
have a third Exchange one.
Plus this would also explain the reason why you can't have more then one
Exchange partnership, since that is taken care of in different way then
through these P. subkeys.
Post by Dr J A Gow
Post by Guido Diepen
Furthermore, I started looking into those provisioning documents and
created a small program that I can use to fetch info from the device
through such documents (Python is really cool :) ). I decided to look at
the information that was present about the charac. Sync when I had both
partnerships (Exchange and Linux with only files) installed on the device
(i.e. I did not have sync-engine running anymore ;) )
Attached to this email you will find the reply provisioning doc I got.
What struck me as odd is that there is a difference in "StoreType" parm.
For the AS connection to linux, this is two, while for the Exchange it is
3. Could this be something? Do you know If you have multiple partnerships
with linux, they all have storetype 2?
I wondered about this a while back but needed to confirm that the
StoreType was also set to 2 for a partnership created by AS/Windows.
It's on my to-do list to test.However, along with your patch I have just
committed a quick workaround for this exchange-deletion problem by
simply not deleting dangling partnerships. This should work until I can
establish the exact meaning of the StoreType by confirmation with a
Windows system.
Just when I had sent my first email, I found your email. I have been trying
to search a bit on google for storetype, unfortunately there is not a lot of
info, but every wap prosivisiong doc I found through google regarding sync
sources, always had storetype 3 when exchange server was involved..

Guido Diepen
--
Aviation is proof that given the will, we have the
capacity to achieve the impossible.
--Eddie Rickenbacker
Loading...