Restoring a backup from Thunderbird

gContactSync makes a backup before the first sync and every 7 days afterwards by default.  If possible you should use Gmail’s interface to restore contacts.  If this isn’t an option (something happened during the first sync, for example) you may follow the steps below to restore your address book in Thunderbird.

  1. First disable synchronization with the address book:
    1. gContactSync -> Accounts and select the address book.
    2. Check Show Advanced Settings
    3. Check Temporarily disable synchronization with this address book.
    4. Click Save Changes
  2. Close Thunderbird. Find your TB profile folder.  If you open the log the path you should see Log Location, for example: C:\Users\<username>\AppData\Roaming\Thunderbird\Profiles\xxxxxxxx.default\gcontactsync\gcontactsync_log.txt
  3. Go to the specified directory (ignoring the filename at the end) and go into the address_book_backups folder
  4. Address books are of the form abook(-N).mab (except collected addresses, which is history.mab).  If you only have one unique address book name then move on to step 5, otherwise you’ll need to figure out which address book you are synchronizing with.
    1. Go to the menu -> Options -> Options… -> Advanced -> General -> Config Editor…
    2. Type the following: ldap_2.servers.*filename and look for the line with that has your address book’s name in it (certain characters are stripped).  The text under Value is the filename of your address book.
  5. Now that you know the name of you address book you should see one or two files in address_book_backups that include that filename.  <filename>.bak is the most recent backup and init_<filename>.bak is a backup from before the first time you synchronized that address book.  Copy the file you want.
  6. Go up two directories to your main TB profile folder.
  7. Rename the file with the name found in step 4 (make sure this backup filename is different than the filename in address_book_backups).
  8. Paste the file from step 5 and rename it to the original name of the file renamed in step 7.
  9. Open Thunderbird.  You can re-enable synchronization when ready, or setup a new address book to sync with.

No Comments

Version 3.0 (Optional) Feature: Ignoring Contacts Without E-mail Addresses

gContactSync version 3 will have a new, optional feature to ignore contacts without e-mail addresses to address the common complaint about contacts with “dummy” e-mail addresses (nobody…@nowhere.invalid).  This will be configurable in each synchronized address book, and will be off by default in existing synchronized address books for forward compatibility.

Contacts that do not have any e-mail addresses will be ignored by the synchronization process.  This means that if you remove all e-mail addresses from a contact that was previously synchronized gContactSync will consider it to have been “deleted” and will delete the contact from the other source.

Version 3.0.0a1 is on the development channel on addons.mozilla.org if anyone wants to try this new feature.

No Comments

Version 2.0.9 Released

Version 2.0.9 has been released with several new localizations courtesy of the translators below:

  • Andreas Nowack – de
  • Sebastian Zartner – de
  • Bert Visser – nl
  • markh van BabelZilla.org – nl
  • devezas – pt-PT
  • Peter Klofutar – sl-SI
  • Mikael Hiort af Ornäs – sv-SE
  • http://t.qq.com/HeartBlade – zh-CN

Version 2.0.8 was released earlier this week with a few bug fixes:

  • Multiple new contacts are pushed the same photo
  • Delete confirmation threshold pops up on every sync if set to 0 in the preferences

3 Comments

Version 2.0.4 Released

Version 2.0.4 has been released.  It fixes the “Find All Groups” button in the New Account Wizard and Edit Accounts dialogs.

I also fixed Twitter import on my website.  The API changed and now requires using SSL for OAuth.

2 Comments

Version 2.0.3 Release

Version 2.0.3 has been released with a fix for the expired token dialog not automatically being closed.  It should auto-update soon.  Thanks to gkresic on the forums and many others who sent me logs!

Version 2.0.2 was skipped because addons.mozilla.org said the version already existed.

No Comments

Version 2.0.1

I uploaded version 2.0.1 for review today.  It should fix the most common issues with version 2.0, mainly it switches over to using a special URI that instructs Google to change the document title instead of redirecting to localhost.

Change Details:

  • Added validation to prevent duplicate login errors
  • Updated authentication to no longer require a redirect to localhost.  That method didn’t work in a web server or other application was listening on port 80.
  • Fix: Next button in new account wizard with new account not always disabled
  • Fix: AB not displayed in new account dialog after having its synced username cleared
  • Added the cs locale courtesy of Michal Stanke
  • Added the es-ES locale courtesy of Scooter
  • Added the it locale courtesy of Leopoldo Saggin

No Comments

Version 2.0 Authentication Issues

A few people have had trouble authenticating with version 2.0.  Google deprecated the old method called ClientLogin, so version 2 switched over to OAuth2, which is more secure since you don’t have to provide the application with your password.

The most common causes are an application listening on port 80 (a web server, skype, etc.), not allowing cookies and using a proxy.

Please follow these steps if you are having trouble authenticating:

  • Update to version 2.0.3 – this version has a fix for the expired token dialog.  2.0.1 change the authentication method so it would work even when an application was listening on port 80 (such as a web server or skype)
  • Go to the Menu -> File -> Offline and verify Work Offline is not checked
  • Go to Menu -> Options -> Privacy.  Either check Accept cookies from sites (Accept third-party cookies can be set to Never) or click Exceptions… and add google.com and click Allow.  You may need to clear cookies and clear all exceptions first.
  • Go to the Menu -> Options -> Options -> Advanced -> General and click Config Editor…  Click the button saying you’ll be careful and type javascript.enabled in the filter.  If it is set to false right-click and and click Toggle.  Restart Thunderbird and try again.
  • Disable all other add-ons and restart Thunderbird.  Lightning + the Google Calendar Provider add-on have caused this issue in the past.
  • Go to Menu -> Options  -> Advanced -> Network & Disk Space -> Click on Settings -> choose No Proxy.  Restart Thunderbird and try again.

If none of the above works, please enable verbose logging in the gContactSync Preferences, try to authenticate again, then send me the log.  Also try clicking on this link in a web browser and see if it eventually redirects you to a blank page with an address localhost/?code=….  That link is what gContactSync uses to authenticate.

 

 

No Comments

Mandatory Upgrade – Version 2.0.0 Released

I recently released version 2.0.0 of gContactSync.  This is a mandatory upgrade for all users since Google is discontinuing the authentication method that previous versions used.

The first time you use version 2.0.0 or later you will have to reauthenticate each unique account you synchronize (once per e-mail address, not synchronized address book).  Unfortunately gContactSync cannot use your saved e-mail password from Thunderbird any more with OAuth2.

Features

  • Switches to OAuth2.  This is a more secure method of authentication and won’t require application-specific passwords for accounts using 2-step authentication.
  • Throttles requests that upload photos to Google.  This will prevent 503 errors when uploading several new photos in a short period of time, or photos appearing to not be synchronized.
  • Synchronization is now done in a worker thread to improve responsiveness while synchronizing.

,

No Comments

Version 2.0.0b1 released (beta channel)

I released version 2.0.0 beta 1 today to the beta channel.  The major change in version 2.0 is switching to OAuth2 for authentication because Google deprecated the ClientLogin method that previous versions of gContactSync used (it will no longer be supported in April 2015).  You can download it here.  Just scroll down to Development Channel.

The first time you use version 2.0.0b1 or later you will have to reauthenticate each unique account you synchronize (once per e-mail address, not synchronized address book).  Unfortunately gContactSync cannot use your saved e-mail password from Thunderbird any more with OAuth2.

It also adds a hidden preference to change the size of the Notes field in the Edit Contact dialog.    To change this preference:

  • Go to Menu -> Preferences -> Preferences
  • Go to the Advanced -> General tab
  • Click Config Editor…
  • Click the button saying that you’ll be careful
  • Type notesHeight
  • Double-click the result and type the desired size, followed by px, for example, 400px
  • Close the Config Editor and Preferences windows

If you try the beta please let me know how it works.

, , , ,

3 Comments

Offline errors in Thunderbird 31.2.0

I’ve received a few dozen error reports about error messages saying gContactSync can’t sync or authenticate with offline.  Most logs are from TB 31.2.0 but that may just be a coincidence.

I haven’t been able to recreate the issue yet so I would really appreciate the following information from anyone who has seen this error message:

  1. Disable any security software you have (Internet Security Suite, firewall, antivirus, etc.).  Kaspersky Internet Security is known to cause this issue, so disable it and try again.  If that works, make Mozilla Thunderbird a Trusted Application: http://support.kaspersky.com/11157#block1
  2. Go to the Menu -> File -> Offline and verify Work Offline is not checked
  3. Disable all other add-ons and restart Thunderbird.  Lightning + the Google Calendar Provider add-on have caused this issue in the past.
  4. Go to the Google Security page and verify that Access for Less Secure Apps is set to Enable
  5. Edit: Thanks to Julie from the comments: “So I went to Tools>Options>Network&DiskSpace>Connection/Settings and Selected “No Proxy”. Restarted Thunderbird, that message was gone, and now the gContactSync works.”
  6. Try downloading an old version of Thunderbird to see if that works.

If none of the above helps, please send me the following debug information:

  • Go to Menu -> Tools -> Error Console and paste the following then hit Evaluate.  Let me know what pops up:
    function reqLoaded() {if(this.readyState == 4){alert(this.status);}}var req=new XMLHttpRequest();req.open("GET", "https://www.google.com/accounts/ClientLogin", true);req.onreadystatechange=reqLoaded;req.send();
  • Turn on verbose logging and send me the log if it happens again (the third bullet shows how to find the log file location).
  • Send me your prefs.js file (this contains all of your settings so I can look for something that is common between all affected users):
    1. View the gContactSync log file
    2. At the top it shows your Thunderbird profile folder location:
       * Log location:     C:\Users\Josh\AppData\Roaming\Thunderbird\Profiles\31fopnzq.default\gcontactsync\gcontactsync_log.txt
    3. Open the directory that contains the gcontactsync folder (C:\Users\Josh\AppData\Roaming\Thunderbird\Profiles\31fopnzq.default in my case)
    4. E-mail me the prefs.js file in this directory
  • If you know how to use Wireshark, a trace while trying to synchronize would be extremely helpful.

Josh

4 Comments