After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 710244 - Improve contacts live search
Improve contacts live search
Status: RESOLVED OBSOLETE
Product: empathy
Classification: Core
Component: Contact List
3.10.x
Other All
: Normal normal
: ---
Assigned To: empathy-maint
empathy-maint
Depends on:
Blocks:
 
 
Reported: 2013-10-16 08:25 UTC by Philip Withnall
Modified: 2018-05-22 16:21 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
live-search: Add tpaw_live_search_match_words_anywhere() method (3.77 KB, patch)
2013-10-16 08:29 UTC, Philip Withnall
none Details | Review
libempathy-gtk: Only match Individual display IDs if they contain an ‘@’ (2.05 KB, patch)
2013-10-16 08:29 UTC, Philip Withnall
none Details | Review
libempathy-gtk: Add live search matching against full name, nick and phone (3.02 KB, patch)
2013-10-16 08:29 UTC, Philip Withnall
none Details | Review

Description Philip Withnall 2013-10-16 08:25:36 UTC
A couple of patches coming up to:
 • Fix spurious matches against display IDs for oFono personas (which are pseudo-random checksums and so we don’t want to match against them).
 • Add support for matching against folks’ NameDetails and PhoneDetails interfaces, so personas which don’t have aliases but do have full names can be matched against, and so matching against phone numbers is supported.
Comment 1 Philip Withnall 2013-10-16 08:29:11 UTC
Created attachment 257403 [details] [review]
live-search: Add tpaw_live_search_match_words_anywhere() method

This does word-by-word searches against a haystack string which aren’t just
prefix matches (in contrast to tpaw_live_search_match_words()). Matches may
be anywhere in the haystack.
Comment 2 Philip Withnall 2013-10-16 08:29:46 UTC
Created attachment 257404 [details] [review]
libempathy-gtk: Only match Individual display IDs if they contain an ‘@’

Only the display IDs exposed by folks’ Telepathy backend are particularly
useful for searching against. Other backends (such as the Ofono backend)
unavoidably expose checksums as display IDs, which can cause confusing false
positives in search results if matched against.
Comment 3 Philip Withnall 2013-10-16 08:29:49 UTC
Created attachment 257405 [details] [review]
libempathy-gtk: Add live search matching against full name, nick and phone

This adds matching against properties from folks’ NameDetails and
PhoneDetails interfaces. Since some folks backends don’t expose aliases for
their personas, but do expose full and structured names, this improves match
results against personas from such backends (e.g. the oFono backend). This
also allows searching against phone numbers, although further work could be
done to, for example, automatically handle international prefixes for
matching.
Comment 4 Xavier Claessens 2013-10-17 21:29:41 UTC
I don't like the tpaw_live_search_match_words_anywhere(), it defeats the idea of the live search that match word prefix. I see you use that for matching phone numbers, but I think you should have special code in empathy_individual_match_string() for that case instead of using tpaw_live_search.

Phone number matching is actually hard... you need to match things like "+32 (02) 123-45-67#89#", stripping spaces, dash, DTMF codes, etc... The good news is that I wrote that code for Nokia already. See http://cgit.collabora.com/git/user/xclaesse/extended-contacts-search.git/tree/src/ecs-match.c#n322 I uses e_normalize_phone_number() from our nokia branch of EDS that we did not upstream it seems, but code is there: https://vcs.maemo.org/svn/eds/trunk/evolution-data-server/addressbook/libebook-dbus/e-book-util.c
Comment 5 Xavier Claessens 2013-10-17 21:31:49 UTC
Looking for phone numbers will also fails on facebook/g+ jid because they are made of <numbers>@server.com, so we should have a way to not match them all if we want the phone lookup to be useful.
Comment 6 GNOME Infrastructure Team 2018-05-22 16:21:31 UTC
-- GitLab Migration Automatic Message --

This bug has been migrated to GNOME's GitLab instance and has been closed from further activity.

You can subscribe and participate further through the new bug through this link to our GitLab instance: https://gitlab.gnome.org/GNOME/empathy/issues/746.