[gnome-builder/gnome-builder-43] libide/lsp: give info about why LSP is restarting
- From: Christian Hergert <chergert src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-builder/gnome-builder-43] libide/lsp: give info about why LSP is restarting
- Date: Tue, 27 Sep 2022 22:04:02 +0000 (UTC)
commit 4d820809ffbf7c47a0b05f0dd3af79cedb205823
Author: Christian Hergert <chergert redhat com>
Date: Tue Sep 27 15:00:16 2022 -0700
libide/lsp: give info about why LSP is restarting
src/libide/lsp/ide-lsp-service.c | 13 +++++++++++++
1 file changed, 13 insertions(+)
---
diff --git a/src/libide/lsp/ide-lsp-service.c b/src/libide/lsp/ide-lsp-service.c
index 62a083962..c3f6dfee5 100644
--- a/src/libide/lsp/ide-lsp-service.c
+++ b/src/libide/lsp/ide-lsp-service.c
@@ -607,6 +607,9 @@ ide_lsp_service_restart (IdeLspService *self)
g_return_if_fail (IDE_IS_LSP_SERVICE (self));
g_return_if_fail (!ide_object_in_destruction (IDE_OBJECT (self)));
+ g_debug ("Request to restart LSP service %s",
+ G_OBJECT_TYPE_NAME (self));
+
ide_lsp_service_stop (self);
if ((context = ide_object_get_context (IDE_OBJECT (self))))
@@ -624,6 +627,13 @@ on_pipeline_loaded_cb (IdeLspService *self,
g_assert (IDE_IS_LSP_SERVICE (self));
g_assert (IDE_IS_PIPELINE (pipeline));
+ g_signal_handlers_disconnect_by_func (pipeline,
+ G_CALLBACK (on_pipeline_loaded_cb),
+ self);
+
+ g_debug ("Pipeline has completed loading, restarting LSP service %s",
+ G_OBJECT_TYPE_NAME (self));
+
ide_lsp_service_restart (self);
IDE_EXIT;
@@ -641,6 +651,9 @@ on_notify_pipeline_cb (IdeLspService *self,
g_assert (IDE_IS_LSP_SERVICE (self));
g_assert (IDE_IS_BUILD_MANAGER (build_manager));
+ g_debug ("Pipeline changed, requesting LSP service %s restart",
+ G_OBJECT_TYPE_NAME (self));
+
ide_lsp_service_stop (self);
if ((pipeline = ide_build_manager_get_pipeline (build_manager)))
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]