goobook dump_contacts behaviour change

10 views
Skip to first unread message

Edward Barker

unread,
May 4, 2020, 4:24:58 PM5/4/20
to goobook
I have been running goobook dump_contacts for some time now as a backup; it returned an xml string containing all of my contact information, and all was good.

Recently the downstream attempt at a record count croaked. goobook dump_contacts is now returning json, not xml. Not a problem, I can do a record count much easier with json, but it is a behaviour change. It seems to coincide with the upgrade from Fedora 31 to 32 and deprecation of Python2.

I have been struggling to find documentation for goobook dump_contacts on the web, is there anybody who could point me towards it? Many thanks.

Ed.

Edward Barker

unread,
May 4, 2020, 4:39:09 PM5/4/20
to goobook
I found goobook dump_contacts -h but that is all I have found so far. That does refer to json, not xml!

Christer Sjöholm

unread,
May 5, 2020, 9:46:18 AM5/5/20
to goobook
The reason the dump_* commands exists are really to help with development. They are useful as generic tools but have no guaranteed stable behavior.
What they do is to dump the data we get from Google with as little changes as possible so if there is changes in how we query Google or how they reply it will affect the result.
The reason there was a switch from XML to JSON was that we switched from a old XML based Google API to a newer JSON based one.

This change was noted in the changelog for version 3.0.0 https://gitlab.com/goobook/goobook/-/blob/master/CHANGES.rst

Regards.

Edward Barker

unread,
May 5, 2020, 10:03:42 AM5/5/20
to goobook
That explains it. I must have still been running Goobook 1.x until the Fedora changes breaking my vpn forced me to run pip again and upgrade to 3.x.

I just use goobook as an automated grab of contact data to throw into normal backup, and it has worked real well. Initially, in the absence of this alternative, I had been, query by query, dragging the data direct from a Google API which was a real unstable chore so I really do appreciate what you have provided here.

Many thanks.

Ed.

Reply all
Reply to author
Forward
0 new messages