From 2565db12b0baeef9607b35086f9609c0667d96eb Mon Sep 17 00:00:00 2001 From: Dannon Baker Date: Wed, 4 Oct 2023 14:49:35 -0400 Subject: [PATCH 1/2] Add ClientSearchMiss basic sentry message -- might be better as a custom event for aggregation? --- client/src/components/Panels/ToolBox.vue | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/client/src/components/Panels/ToolBox.vue b/client/src/components/Panels/ToolBox.vue index 30700602e42b..39ae9f3774eb 100644 --- a/client/src/components/Panels/ToolBox.vue +++ b/client/src/components/Panels/ToolBox.vue @@ -180,7 +180,15 @@ export default { this.queryPending = true; }, onResults(results, closestTerm = null) { + const Galaxy = getGalaxyInstance(); this.results = results; + if (!this.hasResults) { + Galaxy.Sentry.captureMessage("ClientSearchMiss", { + extra: { + query: this.query, + }, + }); + } this.closestTerm = closestTerm; this.queryFilter = this.hasResults ? this.query : null; this.setButtonText(); From 81749e050bc07787c44b70db905a153f885b65d6 Mon Sep 17 00:00:00 2001 From: Dannon Baker Date: Fri, 6 Oct 2023 10:10:17 -0400 Subject: [PATCH 2/2] Avoid trying to send message if sentry isnt' configured --- client/src/components/Panels/ToolBox.vue | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/client/src/components/Panels/ToolBox.vue b/client/src/components/Panels/ToolBox.vue index 39ae9f3774eb..cc4826cdd2ab 100644 --- a/client/src/components/Panels/ToolBox.vue +++ b/client/src/components/Panels/ToolBox.vue @@ -183,7 +183,7 @@ export default { const Galaxy = getGalaxyInstance(); this.results = results; if (!this.hasResults) { - Galaxy.Sentry.captureMessage("ClientSearchMiss", { + Galaxy.Sentry?.captureMessage("ClientSearchMiss", { extra: { query: this.query, },