-
Notifications
You must be signed in to change notification settings - Fork 189
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
fix for #121 (multiple identical first names) #201
base: master
Are you sure you want to change the base?
Conversation
…irst_name was an empty string, but not None Actually inserting a User with full_name or first_name of None into the UserList would cause errors in utils.get_conv_name()
Google Voice participants often first appear with no name at all, and then get upgraded unpredictably to numbers (e.g. "+18005551212") or real names when their ConversationParticipantData message is re-sent. The official Android and Chrome clients appear to share this behavior in some cases: they inexplicably show some users as numbers only, even when those users and their numbers are in my Google Contacts and have been for a long time.
Perhaps this is not immediately relevant, but the I wonder if there are existing libraries out there that deal with this problem in a multilingual way… ? |
Seems to be working fine on my end. I do have one guy whose first name only appears once in the user list, however, his name has the first letter of his last name appended to it. I come from a land where |
Ah, that may be a problem. I am not sure how the You might try commenting out |
Nice solution! Do any of Google's clients solve the issue this way? Since this is a UI issue, I think it would be more appropriate to solve it purely in the UI code (eg. have |
I don't believe Google's own Hangouts clients do this, exactly. Although Gmail does something pretty similar when an email is addressed to multiple people with the same first name. It probably would be more appropriate to handle this in |
We could add a stateful |
This builds on top of #200, and fixes the issue of identical first names leading to a hard-to-follow conversations.
As a Daniel with many friends named Dan or Daniel, I feel the pain of the folks who reported #121 👍.
Any time a new user appears in the user list, this patch revisits the
UserList
and ensures that each name is represented uniquely by including (only if necessary) either the last initial or the whole name.For example, this userlist would be mapped as follows:
Now, if a new user ("Daniel Schmidt") joins the party, both Daniel Smith and Daniel Schmidt's full last names will be added.