[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] externals/elpa 0f57efb 26/71: Simplify bug-reporting instructions
From: |
João Távora |
Subject: |
[elpa] externals/elpa 0f57efb 26/71: Simplify bug-reporting instructions |
Date: |
Wed, 16 Dec 2020 11:42:18 -0500 (EST) |
branch: externals/elpa
commit 0f57efb3d77dfb2992457611c77b665f78b7f8ec
Author: João Távora <joaotavora@gmail.com>
Commit: João Távora <joaotavora@gmail.com>
Simplify bug-reporting instructions
We assume the user has a recent enough jsonrpc.el that consolidates
events and stderr int the same transcript.
* README.md (Reporting bugs): Simplify instructions.
* eglot.el (eglot-events-buffer): Can work with no server.
---
README.md | 39 +++++++++++++++++----------------------
eglot.el | 12 +++++++++---
2 files changed, 26 insertions(+), 25 deletions(-)
diff --git a/README.md b/README.md
index d904c32..0bc20c0 100644
--- a/README.md
+++ b/README.md
@@ -174,33 +174,28 @@ operation? We may have help, so open a [new
issue](https://github.com/joaotavora/eglot/issues) and try to be as
precise and objective about the problem as you can:
-1. Try to replicate the problem with **as clean an Emacs run as
- possible**. This means an empty `.emacs` init file or close to it
- (just loading `eglot.el`, `company.el` and `yasnippet.el` for
- example, and you don't even need `use-package.el` to do that).
-
-2. Include the log of **LSP events** and the **stderr output** of the
- server (if any). You can find the former with `M-x
- eglot-events-buffer` and the latter with `M-x eglot-stderr-buffer`.
- You run these commands in the buffer where you enabled Eglot, but
- if you didn't manage to enable Eglot at all (because of some
- bootstrapping problem), you can still find these buffers in your
- buffer list: they're named like `*EGLOT <project>/<major-mode>
- events*` and `*EGLOT <project>/<major-mode> stderr*`.
+1. Include the invaluable **events transcript**. You can display that
+ buffer with `M-x eglot-events-buffer`. It contains the JSONRPC
+ messages exchanged between client and server, as well as the
+ messages the server prints to stderr.
-3. If Emacs errored (you saw -- and possibly heard -- an error
+2. If Emacs errored (you saw -- and possibly heard -- an error
message), make sure you repeat the process using `M-x
toggle-debug-on-error` so you **get a backtrace** of the error that
you should also attach to the bug report.
-Some more notes: it's understandable that you report it to Eglot
-first, because that's the user-facing side of the LSP experience in
-Emacs, but the outcome may well be that you will have to report the
-problem to the server's developers, as is often the case. But the
-problem can very well be on Eglot's side, of course, and in that case
-we want to fix it! Also bear in mind that Eglot's developers have
-limited resources and no way to test all the possible server
-combinations, so you'll have to do most of the testing.
+3. Try to replicate the problem with **as clean an Emacs run as
+ possible**. This means an empty `.emacs` init file or close to it
+ (just loading `eglot.el`, `company.el` and `yasnippet.el` for
+ example, and you don't even need `use-package.el` to do that).
+
+Some more notes: it is often the case the you will have to report the
+problem to the LSP server's developers, too, though it's
+understandable that you report it Eglot first, since it is the
+user-facing frontend first. If the problem is indeed on Eglot's side,
+we _do_ want to fix it, but because Eglot's developers have limited
+resources and no way to test all the possible server combinations,
+you'll sometimes have to do most of the testing.
<a name="commands"></a>
# Commands and keybindings
diff --git a/eglot.el b/eglot.el
index d172f4c..03609a1 100644
--- a/eglot.el
+++ b/eglot.el
@@ -808,9 +808,15 @@ INTERACTIVE is t if called interactively."
(add-hook 'post-command-hook #'maybe-connect 'append nil)))))
(defun eglot-events-buffer (server)
- "Display events buffer for SERVER."
- (interactive (list (eglot--current-server-or-lose)))
- (display-buffer (jsonrpc-events-buffer server)))
+ "Display events buffer for SERVER.
+Use current server's or first available Eglot events buffer."
+ (interactive (list eglot--cached-server))
+ (let ((buffer (if server (jsonrpc-events-buffer server)
+ (cl-find "\\*EGLOT.*events\\*"
+ (buffer-list)
+ :key #'buffer-name :test #'string-match))))
+ (if buffer (display-buffer buffer)
+ (eglot--error "Can't find an Eglot events buffer!"))))
(defun eglot-stderr-buffer (server)
"Display stderr buffer for SERVER."
- [elpa] externals/elpa d99a447 12/71: Close #439: Hide eldoc-message on empty hover info, (continued)
- [elpa] externals/elpa d99a447 12/71: Close #439: Hide eldoc-message on empty hover info, João Távora, 2020/12/16
- [elpa] externals/elpa af32ebf 06/71: Close #444: use text-mode for plaintext markup, João Távora, 2020/12/16
- [elpa] externals/elpa ef6c483 13/71: Fix #452: also check types when destructuring LSP objects, João Távora, 2020/12/16
- [elpa] externals/elpa 487cde5 18/71: Close #443: kind of honour eldoc-echo-area-use-multiline-p, João Távora, 2020/12/16
- [elpa] externals/elpa 22aa27c 01/71: Close #397: Simplify a bit of code, João Távora, 2020/12/16
- [elpa] externals/elpa 8900a35 04/71: Prevent "Cant guess python-indent-offset..." messages in tests, João Távora, 2020/12/16
- [elpa] externals/elpa dd48f4a 08/71: * eglot.el (eglot-put-doc-in-help-buffer): Tiny docstring fix., João Távora, 2020/12/16
- [elpa] externals/elpa e5cf30e 09/71: Close #435: create match xrefs when possible, João Távora, 2020/12/16
- [elpa] externals/elpa ad3f049 24/71: Close #417: minimally document relation with project.el, João Távora, 2020/12/16
- [elpa] externals/elpa 2f75da2 28/71: Fix #460: fix "free variable" warning, João Távora, 2020/12/16
- [elpa] externals/elpa 0f57efb 26/71: Simplify bug-reporting instructions,
João Távora <=
- [elpa] externals/elpa 91a7cba 33/71: Fix #474, #478: prompt for executable if supplied name does not exist, João Távora, 2020/12/16
- [elpa] externals/elpa 9efe207 05/71: Make curl invocation fail more explicitly in .travis.yml, João Távora, 2020/12/16
- [elpa] externals/elpa 73bc752 11/71: Close #441: shield tests from some user customizations, João Távora, 2020/12/16
- [elpa] externals/elpa b6519a5 16/71: Per #446: Add tests for eglot-server-programs, João Távora, 2020/12/16
- [elpa] externals/elpa 9bc58df 17/71: Fix #446: unbreak eglot--guess-contact for host-and-port case, João Távora, 2020/12/16
- [elpa] externals/elpa 197984c 27/71: Remove trailing whitespaces, João Távora, 2020/12/16
- [elpa] externals/elpa a0249c8 23/71: Per #437: remap display-local-help (C-h .) to eglot-help-at-point, João Távora, 2020/12/16
- [elpa] externals/elpa ee87519 41/71: Replace uses of project-roots with project-root, João Távora, 2020/12/16
- [elpa] externals/elpa 3b01561 39/71: Close #459: rework computation of string given to Eldoc (again), João Távora, 2020/12/16
- [elpa] externals/elpa bf75312 35/71: Require Xref, Project and Eldoc from GNU ELPA, João Távora, 2020/12/16