Fixed reconnect remote instance dialog
This commit is contained in:
parent
93652cd9f7
commit
19cc97a1c4
@ -206,10 +206,10 @@ def reconnect_remote_response(self, dialog, task, entry):
|
|||||||
elif response == "close":
|
elif response == "close":
|
||||||
self.destroy()
|
self.destroy()
|
||||||
|
|
||||||
def reconnect_remote(self):
|
def reconnect_remote(self, current_url):
|
||||||
entry = Gtk.Entry(
|
entry = Gtk.Entry(
|
||||||
css_classes = ["error"],
|
css_classes = ["error"],
|
||||||
text = self.ollama_url
|
text = current_url
|
||||||
)
|
)
|
||||||
dialog = Adw.AlertDialog(
|
dialog = Adw.AlertDialog(
|
||||||
heading=_("Connection Error"),
|
heading=_("Connection Error"),
|
||||||
|
@ -785,7 +785,7 @@ class AlpacaWindow(Adw.ApplicationWindow):
|
|||||||
|
|
||||||
def connection_error(self):
|
def connection_error(self):
|
||||||
if self.run_remote:
|
if self.run_remote:
|
||||||
dialogs.reconnect_remote(self)
|
dialogs.reconnect_remote(self, connection_handler.url)
|
||||||
else:
|
else:
|
||||||
local_instance.reset(self.data_dir)
|
local_instance.reset(self.data_dir)
|
||||||
self.show_toast("error", 7, self.main_overlay)
|
self.show_toast("error", 7, self.main_overlay)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user