Skip to content

Issue titles for issue platform issues aren't searchable #50345

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

Closed
wedamija opened this issue Jun 5, 2023 · 4 comments
Closed

Issue titles for issue platform issues aren't searchable #50345

wedamija opened this issue Jun 5, 2023 · 4 comments
Assignees

Comments

@wedamija
Copy link
Member

wedamija commented Jun 5, 2023

I think this is because we're not including them in search_message here:

def search_message(self) -> str:
"""
The internal search_message attribute is only used for search purposes.
It adds a bunch of data from the metadata and the culprit.
"""
data = self.data
culprit = self.culprit
event_metadata = self.get_event_metadata()
if event_metadata is None:
event_metadata = eventtypes.get(self.get_event_type())().get_metadata(self.data)
message = ""
if data.get("logentry"):
message += data["logentry"].get("formatted") or data["logentry"].get("message") or ""
if event_metadata:
for value in event_metadata.values():
value_u = force_text(value, errors="replace")
if value_u not in message:
message = f"{message} {value_u}"
if culprit and culprit not in message:
culprit_u = force_text(culprit, errors="replace")
message = f"{message} {culprit_u}"
return cast(str, trim(message.strip(), settings.SENTRY_MAX_MESSAGE_LENGTH))

We should write a test that searches on the title for a platform issue and figure out how to make it pass

@cmanallen
Copy link
Member

@wedamija Replays also suffers from this but on more fields than just the title. For example our events have a tag replayId which is not searchable. See: https://sentry.sentry.io/issues/?project=11276&query=is%3Aunresolved+issue.category%3Areplay+replayId%3A0779b2f063804a3489b8d6836fc5f8c6&referrer=issue-list&statsPeriod=14d&stream_index=0

@scefali
Copy link
Contributor

scefali commented Jun 6, 2023

It looks like we don't have the search text column in ClickHouse yet, we need to write to it first

@wedamija
Copy link
Member Author

wedamija commented Jun 6, 2023

https://github.com/getsentry/snuba/blob/c5f069eae10e256633825c2d56b44501412c67fe/snuba/datasets/configuration/events/entities/events.yaml#L84

Basically we should probably have this column in the search issues dataset in clickhouse so we can do general searches.

@rachrwang rachrwang added this to the Search Shortcuts milestone Jun 15, 2023
@rachrwang rachrwang assigned wedamija and unassigned scefali Jun 20, 2023
wedamija added a commit that referenced this issue Jun 20, 2023
…nce titles works as expected

This validates that searching for an issue platform issue via text in the title works as expected.
Relies on #51325 and getsentry/snuba#4385

Related to #50345
wedamija added a commit to getsentry/snuba that referenced this issue Jun 20, 2023
wedamija added a commit to getsentry/snuba that referenced this issue Jun 21, 2023
This allows the message column on search issues to be queried, and stops using `issue_title`. We
won't merge this until we've dual written data for a week or two.

Relies on #4385, #4387
Related to getsentry/sentry#50345
wedamija added a commit that referenced this issue Jun 21, 2023
…vent search_message (#51325)

We want occurrence information like title, subtitle and culprit to be
searchable in clickhouse. For this to happen, we need to make sure this
information is included in:
- `search_message`, which is passed on to snuba to be written to the
message columns
 - `Group.message`, which is used in the postgres side of search.

Related to #50345
wedamija added a commit that referenced this issue Jun 21, 2023
…nce titles works as expected

This validates that searching for an issue platform issue via text in the title works as expected.
Relies on #51325 and getsentry/snuba#4385

Related to #50345
wedamija added a commit to getsentry/snuba that referenced this issue Jun 21, 2023
* This adds the `message` column to search issues table, since we missed it initially..

Related to getsentry/sentry#50345

* remove __init__ so check stops complaining
wedamija added a commit to getsentry/snuba that referenced this issue Jun 21, 2023
wedamija added a commit to getsentry/snuba that referenced this issue Jun 22, 2023
This allows the message column on search issues to be queried, and stops using `issue_title`. We
won't merge this until we've dual written data for a week or two.

Relies on #4385, #4387
Related to getsentry/sentry#50345
@github-actions
Copy link
Contributor

This issue has gone three weeks without activity. In another week, I will close it.

But! If you comment or otherwise update it, I will reset the clock, and if you label it Status: Backlog or Status: In Progress, I will leave it alone ... forever!


"A weed is but an unloved flower." ― Ella Wheeler Wilcox 🥀

wedamija added a commit to getsentry/snuba that referenced this issue Feb 23, 2024
This allows the message column on search issues to be queried, and stops using `issue_title`. We
won't merge this until we've dual written data for a week or two.

Relies on #4385, #4387
Related to getsentry/sentry#50345
wedamija added a commit to getsentry/snuba that referenced this issue Feb 26, 2024
)

This allows the message column on search issues to be queried, and stops using `issue_title`. We
won't merge this until we've dual written data for a week or two.

Relies on #4385, #4387
Related to getsentry/sentry#50345
@github-actions github-actions bot locked and limited conversation to collaborators Nov 3, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants