Send e164 formatted phone numbers when syncing contact details and blocked lists
Bug description
Contact info and blocked lists sometimes fail to sync correctly on Desktop due to non-e164 phone number formats. Repro steps below demonstrate this for contact color syncing, though blocked number sync messages are similarly affected (see screenshots from Chrome's debugger).
Steps to reproduce
- Edit a contact number so it includes punctuation, such as parentheses, spaces, or dashes.
- Refresh the contact info in Signal (see that the punctuated number is rendered in the conversation header).
- Change the contact's color in signal
Actual result: Signal Desktop becomes confused and fails to save the change in contact info or blocked state.
Expected result: Signal Desktop correctly updates the conversation color.
Screenshots
Device info
Device: Galaxy Nexus Android version: 4.3 Signal version: 3.27.1
Link to debug log
https://gist.github.com/faf5c52bfecc2672a4b7fc9581e4e2c5
Am i correct if i assume this will happen only if i didn't save the contact in e164 in my android contacts?
Hapening also with Galaxy S6 and Android 6.x on last stable Android Signal version.
Shouldn't every contact be in e164?
Every contact has a canonical address but the sync messages aren't being populated from that table (apparently).
Aaah, i think you are completely right.
e164 numbers are stored in canonical_addresses, but the numbers for the contact sync objects are fetched from the droid contact store.
Could you test #6094? Can't test it myself right now, haven't got a smartphone with Signal-Android as a master in reach.
85aa5c5 only fixed one half of this issue, the details are fixed by https://github.com/WhisperSystems/Signal-Android/pull/6094.