We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
LSP needs a LspJumpBackCommand
When executing LSP goto definition, 
and then executing the built in `jump_back` command, 
the cursor won't be placed in the previous place, as I expect.

To fix this, we can introduce a `LspJumpBackCommand`.
We can do the same thing as TernForSublime [did](https://github.com/ternjs/tern_for_sublime/blob/91a27a39b1b0a33a9043aa685e1ee48c64a58274/tern.py#L564).  

--- END ISSUE ---

Below are some code segments, each from a relevant file. One or more of these files may contain bugs.
--- BEGIN FILES ---
Path: `plugin/definition.py`
Content:
```
1 import sublime
2 
3 from .core.registry import client_for_view, LspTextCommand
4 from .core.protocol import Request, Point
5 from .core.documents import get_document_position, get_position, is_at_word
6 from .core.url import uri_to_filename
7 from .core.logging import debug
8 try:
9     from typing import List, Dict, Optional, Any
10     assert List and Dict and Optional and Any
11 except ImportError:
12     pass
13 
14 
15 class LspSymbolDefinitionCommand(LspTextCommand):
16     def __init__(self, view):
17         super().__init__(view)
18 
19     def is_enabled(self, event=None):
20         if self.has_client_with_capability('definitionProvider'):
21             return is_at_word(self.view, event)
22         return False
23 
24     def run(self, edit, event=None) -> None:
25         client = client_for_view(self.view)
26         if client:
27             pos = get_position(self.view, event)
28             document_position = get_document_position(self.view, pos)
29             if document_position:
30                 request = Request.definition(document_position)
31                 client.send_request(
32                     request, lambda response: self.handle_response(response, pos))
33 
34     def handle_response(self, response: 'Optional[Any]', position) -> None:
35         window = sublime.active_window()
36         if response:
37             location = response if isinstance(response, dict) else response[0]
38             file_path = uri_to_filename(location.get("uri"))
39             start = Point.from_lsp(location['range']['start'])
40             file_location = "{}:{}:{}".format(file_path, start.row + 1, start.col + 1)
41             debug("opening location", location)
42             window.open_file(file_location, sublime.ENCODED_POSITION)
43             # TODO: can add region here.
44         else:
45             window.run_command("goto_definition")
46 
47     def want_event(self):
48         return True
49
```
--- END FILES ---

Please first localize the bug based on the issue statement, and then generate a patch according to the `git diff` format fenced by three backticks.

Here is an example:

```diff
diff --git a/examples/server_async.py b/examples/server_async.py
--- a/examples/server_async.py
+++ b/examples/server_async.py
@@ -313,4 +313,4 @@
 
 
 if __name__ == "__main__":
-    asyncio.run(run_async_server("."), debug=True)
+    asyncio.run(run_async_server(), debug=True)
diff --git a/examples/server_sync.py b/examples/server_sync.py
--- a/examples/server_sync.py
+++ b/examples/server_sync.py
@@ -313,5 +313,5 @@
 
 
 if __name__ == "__main__":
-    server = run_sync_server(".")
+    server = run_sync_server()
     server.shutdown()

```

diff --git a/plugin/definition.py b/plugin/definition.py
--- a/plugin/definition.py
+++ b/plugin/definition.py
@@ -5,6 +5,7 @@
 from .core.documents import get_document_position, get_position, is_at_word
 from .core.url import uri_to_filename
 from .core.logging import debug
+from Default.history_list import get_jump_history_for_view  # type: ignore
 try:
     from typing import List, Dict, Optional, Any
     assert List and Dict and Optional and Any
@@ -34,6 +35,9 @@
     def handle_response(self, response: 'Optional[Any]', position) -> None:
         window = sublime.active_window()
         if response:
+            # save to jump back history
+            get_jump_history_for_view(self.view).push_selection(self.view)
+
             location = response if isinstance(response, dict) else response[0]
             file_path = uri_to_filename(location.get("uri"))
             start = Point.from_lsp(location['range']['start'])

{"golden_diff": "diff --git a/plugin/definition.py b/plugin/definition.py\n--- a/plugin/definition.py\n+++ b/plugin/definition.py\n@@ -5,6 +5,7 @@\n from .core.documents import get_document_position, get_position, is_at_word\n from .core.url import uri_to_filename\n from .core.logging import debug\n+from Default.history_list import get_jump_history_for_view  # type: ignore\n try:\n     from typing import List, Dict, Optional, Any\n     assert List and Dict and Optional and Any\n@@ -34,6 +35,9 @@\n     def handle_response(self, response: 'Optional[Any]', position) -> None:\n         window = sublime.active_window()\n         if response:\n+            # save to jump back history\n+            get_jump_history_for_view(self.view).push_selection(self.view)\n+\n             location = response if isinstance(response, dict) else response[0]\n             file_path = uri_to_filename(location.get(\"uri\"))\n             start = Point.from_lsp(location['range']['start'])\n", "issue": "LSP needs a LspJumpBackCommand\nWhen executing LSP goto definition, \r\nand then executing the built in `jump_back` command, \r\nthe cursor won't be placed in the previous place, as I expect.\r\n\r\nTo fix this, we can introduce a `LspJumpBackCommand`.\r\nWe can do the same thing as TernForSublime [did](https://github.com/ternjs/tern_for_sublime/blob/91a27a39b1b0a33a9043aa685e1ee48c64a58274/tern.py#L564).  \n", "before_files": [{"content": "import sublime\n\nfrom .core.registry import client_for_view, LspTextCommand\nfrom .core.protocol import Request, Point\nfrom .core.documents import get_document_position, get_position, is_at_word\nfrom .core.url import uri_to_filename\nfrom .core.logging import debug\ntry:\n    from typing import List, Dict, Optional, Any\n    assert List and Dict and Optional and Any\nexcept ImportError:\n    pass\n\n\nclass LspSymbolDefinitionCommand(LspTextCommand):\n    def __init__(self, view):\n        super().__init__(view)\n\n    def is_enabled(self, event=None):\n        if self.has_client_with_capability('definitionProvider'):\n            return is_at_word(self.view, event)\n        return False\n\n    def run(self, edit, event=None) -> None:\n        client = client_for_view(self.view)\n        if client:\n            pos = get_position(self.view, event)\n            document_position = get_document_position(self.view, pos)\n            if document_position:\n                request = Request.definition(document_position)\n                client.send_request(\n                    request, lambda response: self.handle_response(response, pos))\n\n    def handle_response(self, response: 'Optional[Any]', position) -> None:\n        window = sublime.active_window()\n        if response:\n            location = response if isinstance(response, dict) else response[0]\n            file_path = uri_to_filename(location.get(\"uri\"))\n            start = Point.from_lsp(location['range']['start'])\n            file_location = \"{}:{}:{}\".format(file_path, start.row + 1, start.col + 1)\n            debug(\"opening location\", location)\n            window.open_file(file_location, sublime.ENCODED_POSITION)\n            # TODO: can add region here.\n        else:\n            window.run_command(\"goto_definition\")\n\n    def want_event(self):\n        return True\n", "path": "plugin/definition.py"}], "after_files": [{"content": "import sublime\n\nfrom .core.registry import client_for_view, LspTextCommand\nfrom .core.protocol import Request, Point\nfrom .core.documents import get_document_position, get_position, is_at_word\nfrom .core.url import uri_to_filename\nfrom .core.logging import debug\nfrom Default.history_list import get_jump_history_for_view  # type: ignore\ntry:\n    from typing import List, Dict, Optional, Any\n    assert List and Dict and Optional and Any\nexcept ImportError:\n    pass\n\n\nclass LspSymbolDefinitionCommand(LspTextCommand):\n    def __init__(self, view):\n        super().__init__(view)\n\n    def is_enabled(self, event=None):\n        if self.has_client_with_capability('definitionProvider'):\n            return is_at_word(self.view, event)\n        return False\n\n    def run(self, edit, event=None) -> None:\n        client = client_for_view(self.view)\n        if client:\n            pos = get_position(self.view, event)\n            document_position = get_document_position(self.view, pos)\n            if document_position:\n                request = Request.definition(document_position)\n                client.send_request(\n                    request, lambda response: self.handle_response(response, pos))\n\n    def handle_response(self, response: 'Optional[Any]', position) -> None:\n        window = sublime.active_window()\n        if response:\n            # save to jump back history\n            get_jump_history_for_view(self.view).push_selection(self.view)\n\n            location = response if isinstance(response, dict) else response[0]\n            file_path = uri_to_filename(location.get(\"uri\"))\n            start = Point.from_lsp(location['range']['start'])\n            file_location = \"{}:{}:{}\".format(file_path, start.row + 1, start.col + 1)\n            debug(\"opening location\", location)\n            window.open_file(file_location, sublime.ENCODED_POSITION)\n            # TODO: can add region here.\n        else:\n            window.run_command(\"goto_definition\")\n\n    def want_event(self):\n        return True\n", "path": "plugin/definition.py"}]}