Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Initial sync: Error updating Monica contact: ['The day field is required.', 'The month field is required.']. #26

Closed
Turochamp opened this issue Aug 9, 2021 · 3 comments
Assignees
Labels
bug Something isn't working

Comments

@Turochamp
Copy link
Contributor

2021-07-29 18:29:18,401 ERROR 'Thanasis W' ('461798'): Error updating Monica contact: ['The day field is required.', 'The month field is required.']. Does it exist?
2021-07-29 18:29:18,401 ERROR Error updating Monica contact!
Traceback (most recent call last):
  File "GMSync.py", line 77, in main
    sync.startSync('initial')
  File "/home/mahs/git/GoogleMonicaSync/SyncHelper.py", line 44, in startSync
    self.__initialSync()
  File "/home/mahs/git/GoogleMonicaSync/SyncHelper.py", line 92, in __initialSync
    self.__sync('full', dateBasedSync=False)
  File "/home/mahs/git/GoogleMonicaSync/SyncHelper.py", line 202, in __sync
    self.__mergeAndUpdateNBD(monicaContact, googleContact)
  File "/home/mahs/git/GoogleMonicaSync/SyncHelper.py", line 914, in __mergeAndUpdateNBD
    self.monica.updateContact(monicaId=monicaContact["id"], data=googleForm.data)
  File "/home/mahs/git/GoogleMonicaSync/MonicaHelper.py", line 107, in updateContact
    raise Exception("Error updating Monica contact!")
@Turochamp
Copy link
Contributor Author

The Google contact Thanasis W has birthday: "2014-10-20"

@antonplagemann antonplagemann self-assigned this Aug 15, 2021
@antonplagemann antonplagemann added the bug Something isn't working label Aug 15, 2021
@antonplagemann
Copy link
Owner

Hm, that one is a bit tricky. I fixed a default value in e646874 (dev branch) and added additional logging for the contact data that has been sent.
I dont think this will fix it, but it may help to diagnose this further.
Can you try and paste your log again?
It will contain some details of the contact, please remove everything not related to the birthday 😊 🙏

@Turochamp
Copy link
Contributor Author

After #25 was fixed, I took another look at this and actually Google does not recognize "2014-10-20" as a date, but changing it to "10/20/2014" instead solved the problem.

So this is an issue of bad data in, not a bug in GoogleMonicaSync. Closing it. 😊

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants