signalapp / Signal-iOS

A private messenger for iOS.
https://signal.org
GNU Affero General Public License v3.0
10.84k stars 3.04k forks source link

Search can't handle "@" character #4058

Open denver-s opened 5 years ago

denver-s commented 5 years ago

Bug description

Searching for "@" or strings containing "@" doesn't work or it doesn't show the matched messages.

Steps to reproduce

Actual result: (A) it says that no messages are found. (B) matching results don't include "@" character in the preview.

Expected result: the search engine should find any message containing "@".

Screenshots

2018-11-22_17-04-43_000 2018-11-22_17-04-54_000 2018-11-22_17-05-01_000

Device info

Device: iPhone 8 Plus

iOS version: 12.1

Signal version: 2.32.0.14

Link to debug log

nebloc commented 5 years ago

Also fails to match . so email addresses such as example.email@server.com have to be searched like exampleemailservercom. Punctuation seems to be filtered out here.

stale[bot] commented 2 years ago

Is this still relevant? If so, what is blocking it? Is there anything you can do to help move it forward?

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs.

denver-s commented 2 years ago

Still relevant.

stale[bot] commented 2 years ago

Is this still relevant? If so, what is blocking it? Is there anything you can do to help move it forward?

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs.

denver-s commented 2 years ago

Still relevant

stale[bot] commented 2 years ago

Is this still relevant? If so, what is blocking it? Is there anything you can do to help move it forward?

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs.

denver-s commented 2 years ago

Still relevant

stale[bot] commented 2 years ago

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

denver-s commented 2 years ago

Still relevant

ghost commented 2 years ago

The problem is solved by removing the "@" sign from the CharacterSet.punctuationCharacters set defined in the static function charactersToRemove in the FullTextSearchFinder.swift file. So, adding charactersToFilter.remove(charactersIn: "@") after line 101 seems to resolve the error in the search part.

But the main issue here is this; There are many characters that can be used in search in Apple's punctutationCharacters. I haven't tested all of them, but it is necessary to compare them with Android and determine which ones will be included.

Thanx.

falkikowski commented 3 months ago

The search also fails to find "€".