From 59b284e18bfbc3c9e89c4c5ebac67a63b016161a Mon Sep 17 00:00:00 2001 From: grossmj Date: Tue, 7 Nov 2023 19:11:57 +1000 Subject: [PATCH 1/9] Development in 2.2.45.dev3 --- gns3/version.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gns3/version.py b/gns3/version.py index fb116b59b..b626549e5 100644 --- a/gns3/version.py +++ b/gns3/version.py @@ -23,8 +23,8 @@ # or negative for a release candidate or beta (after the base version # number has been incremented) -__version__ = "2.2.44.1" -__version_info__ = (2, 2, 44, -99) +__version__ = "2.2.45.dev3" +__version_info__ = (2, 2, 45, 99) if "dev" in __version__: try: From fc54b76ee1b756fea6fcde33e7dc27e590771ab2 Mon Sep 17 00:00:00 2001 From: grossmj Date: Wed, 22 Nov 2023 10:32:51 +1000 Subject: [PATCH 2/9] Upgrade sentry-sdk and aiohttp --- requirements.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/requirements.txt b/requirements.txt index c9cd5f20c..770a04e08 100644 --- a/requirements.txt +++ b/requirements.txt @@ -1,6 +1,6 @@ jsonschema>=4.17.3,<4.18; python_version >= '3.7' # v4.17.3 is the last version to support Python 3.7 jsonschema==3.2.0; python_version < '3.7' # v3.2.0 is the last version to support Python 3.6 -sentry-sdk==1.34.0,<1.35 +sentry-sdk==1.36.0,<1.37 psutil==5.9.6 distro>=1.8.0 truststore>=0.8.0; python_version >= '3.10' From 04fb449b44780039132b16c8b90fcbab0c738fce Mon Sep 17 00:00:00 2001 From: grossmj Date: Tue, 28 Nov 2023 11:23:20 +1000 Subject: [PATCH 3/9] Add --suppressApplicationTitle for Windows terminal. Fixes https://github.com/GNS3/gns3-gui/issues/3544 --- gns3/settings.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gns3/settings.py b/gns3/settings.py index 42e655019..47fecb3d2 100644 --- a/gns3/settings.py +++ b/gns3/settings.py @@ -65,7 +65,7 @@ 'SecureCRT (personal profile)': r'"{}\AppData\Local\VanDyke Software\SecureCRT\SecureCRT.exe" /T /N "{{name}}" /TELNET {{host}} {{port}}'.format(userprofile), 'TeraTerm Pro': r'"{}\teraterm\ttermpro.exe" /W="{{name}}" /M="ttstart.macro" /T=1 {{host}} {{port}}'.format(program_files_x86), 'Telnet': 'telnet {host} {port}', - 'Windows Terminal': 'wt.exe -w 1 new-tab --title {name} telnet {host} {port}', + 'Windows Terminal': 'wt.exe -w 1 new-tab --suppressApplicationTitle --title {name} telnet {host} {port}', 'Xshell 4': r'"{}\NetSarang\Xshell 4\xshell.exe" -url telnet://{{host}}:{{port}}'.format(program_files_x86), 'Xshell 5': r'"{}\NetSarang\Xshell 5\xshell.exe" -url telnet://{{host}}:{{port}} -newtab {{name}}'.format(program_files_x86), 'ZOC 6': r'"{}\ZOC6\zoc.exe" "/TELNET:{{host}}:{{port}}" /TABBED "/TITLE:{{name}}"'.format(program_files_x86)} From 3df374e78463b70872a1d89ea2b83cf82a8e9cdb Mon Sep 17 00:00:00 2001 From: grossmj Date: Tue, 5 Dec 2023 21:24:41 +1000 Subject: [PATCH 4/9] Add custom executable paths on Windows --- gns3/main.py | 1 + 1 file changed, 1 insertion(+) diff --git a/gns3/main.py b/gns3/main.py index 80ff45578..b84aefdbe 100644 --- a/gns3/main.py +++ b/gns3/main.py @@ -142,6 +142,7 @@ def main(): frozen_dirs = [ frozen_dir, os.path.normpath(os.path.join(frozen_dir, 'dynamips')), + os.path.normpath(os.path.join(frozen_dir, 'ubridge')), os.path.normpath(os.path.join(frozen_dir, 'vpcs')), os.path.normpath(os.path.join(frozen_dir, 'traceng')) ] From fefda5037854de620da857243939e00da7966b07 Mon Sep 17 00:00:00 2001 From: grossmj Date: Thu, 11 Jan 2024 22:57:14 +1100 Subject: [PATCH 5/9] Add debug for PATH env variable --- gns3/main.py | 1 + 1 file changed, 1 insertion(+) diff --git a/gns3/main.py b/gns3/main.py index b84aefdbe..5afc93704 100644 --- a/gns3/main.py +++ b/gns3/main.py @@ -148,6 +148,7 @@ def main(): ] os.environ["PATH"] = os.pathsep.join(frozen_dirs) + os.pathsep + os.environ.get("PATH", "") + log.debug("PATH content: {}".format(os.environ["PATH"])) if options.project: os.chdir(frozen_dir) From 18be274fed76da445927bcdd2ca60cad5120c082 Mon Sep 17 00:00:00 2001 From: grossmj Date: Fri, 12 Jan 2024 13:22:48 +1100 Subject: [PATCH 6/9] Handle moved project notifications on controller stream --- gns3/controller.py | 10 ++++++++++ gns3/project.py | 9 ++++++--- 2 files changed, 16 insertions(+), 3 deletions(-) diff --git a/gns3/controller.py b/gns3/controller.py index 2daa6f653..a70557c44 100644 --- a/gns3/controller.py +++ b/gns3/controller.py @@ -479,6 +479,16 @@ def _event_received(self, result, *args, **kwargs): elif result["action"] == "compute.created" or result["action"] == "compute.updated": from .compute_manager import ComputeManager ComputeManager.instance().computeDataReceivedCallback(result["event"]) + elif result["action"] == "project.closed": + from .topology import Topology + project = Topology.instance().project() + if project and project.id() == result["event"]["project_id"]: + Topology.instance().setProject(None) + elif result["action"] == "project.updated": + from .topology import Topology + project = Topology.instance().project() + if project and project.id() == result["event"]["project_id"]: + project.projectUpdatedCallback(result["event"]) elif result["action"] == "log.error": log.error(result["event"]["message"]) elif result["action"] == "log.warning": diff --git a/gns3/project.py b/gns3/project.py index 7b38fdbb4..cab47dd3b 100644 --- a/gns3/project.py +++ b/gns3/project.py @@ -475,9 +475,9 @@ def update(self): "variables": self._variables, "supplier": self._supplier } - self.put("", self._projectUpdatedCallback, body=body) + self.put("", self.projectUpdatedCallback, body=body) - def _projectUpdatedCallback(self, result, error=False, **kwargs): + def projectUpdatedCallback(self, result, error=False, **kwargs): if error: self.project_creation_error_signal.emit(result["message"]) return @@ -712,10 +712,13 @@ def _event_received(self, result, *args, **kwargs): drawing = Topology.instance().getDrawingFromUuid(result["event"]["drawing_id"]) if drawing is not None: drawing.delete(skip_controller=True) + # project.closed and project.updated notifications have been moved to the controller + # because they are not project specific, keeping it there for backward compatibility + # when connected to an older controller version elif result["action"] == "project.closed": Topology.instance().setProject(None) elif result["action"] == "project.updated": - self._projectUpdatedCallback(result["event"]) + self.projectUpdatedCallback(result["event"]) elif result["action"] == "snapshot.restored": Topology.instance().restoreSnapshot(result["event"]["project_id"]) elif result["action"] == "log.error": From 88ed9407b9acc22ac758b3ecb597d3045a9745b2 Mon Sep 17 00:00:00 2001 From: grossmj Date: Fri, 12 Jan 2024 15:46:20 +1100 Subject: [PATCH 7/9] Move PATH debug message --- gns3/main.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/gns3/main.py b/gns3/main.py index 5afc93704..8d5847c9f 100644 --- a/gns3/main.py +++ b/gns3/main.py @@ -148,11 +148,11 @@ def main(): ] os.environ["PATH"] = os.pathsep.join(frozen_dirs) + os.pathsep + os.environ.get("PATH", "") - log.debug("PATH content: {}".format(os.environ["PATH"])) if options.project: os.chdir(frozen_dir) + def exceptionHook(exception, value, tb): if exception == KeyboardInterrupt: @@ -262,6 +262,7 @@ def exceptionHook(exception, value, tb): log.info("GNS3 GUI version {}".format(__version__)) log.info("Copyright (c) 2007-{} GNS3 Technologies Inc.".format(current_year)) log.info("Application started with {}".format(" ".join(sys.argv))) + log.debug("PATH={}".format(os.environ["PATH"])) # update the exception file path to have it in the same directory as the settings file. exception_file_path = os.path.join(LocalConfig.instance().configDirectory(), exception_file_path) From 2a72ad5e0b228138b5b935673e3e56cc23fe6d19 Mon Sep 17 00:00:00 2001 From: grossmj Date: Fri, 12 Jan 2024 16:39:06 +1100 Subject: [PATCH 8/9] Add missing console_type values in appliance_v8.json. Ref https://github.com/GNS3/gns3-registry/issues/849 --- gns3/schemas/appliance_v8.json | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/gns3/schemas/appliance_v8.json b/gns3/schemas/appliance_v8.json index 55c245b57..043ef26ec 100644 --- a/gns3/schemas/appliance_v8.json +++ b/gns3/schemas/appliance_v8.json @@ -57,7 +57,8 @@ "telnet", "vnc", "http", - "https" + "https", + "none" ], "title": "Type of console" }, @@ -502,7 +503,8 @@ "telnet", "vnc", "spice", - "spice+agent" + "spice+agent", + "none" ], "title": "Type of console connection for the administration of the appliance" }, From bbc5b3e4ac1c6c40441adc1474a9d3cfe98b7db3 Mon Sep 17 00:00:00 2001 From: grossmj Date: Fri, 12 Jan 2024 21:38:26 +1100 Subject: [PATCH 9/9] Release v2.2.45 --- CHANGELOG | 9 +++++++++ gns3/crash_report.py | 2 +- gns3/version.py | 4 ++-- 3 files changed, 12 insertions(+), 3 deletions(-) diff --git a/CHANGELOG b/CHANGELOG index 4fe306b2c..a8c6c0b9c 100644 --- a/CHANGELOG +++ b/CHANGELOG @@ -1,5 +1,14 @@ # Change Log +## 2.2.45 12/01/2024 + +* Add missing console_type values in appliance_v8.json. Ref https://github.com/GNS3/gns3-registry/issues/849 +* Handle moved project notifications on controller stream +* Add debug for PATH env variable +* Add custom executable paths on Windows +* Add --suppressApplicationTitle for Windows terminal. Fixes https://github.com/GNS3/gns3-gui/issues/3544 +* Upgrade sentry-sdk and aiohttp + ## 2.2.44.1 07/11/2023 * No changes diff --git a/gns3/crash_report.py b/gns3/crash_report.py index 0c12cef85..8759d5ac2 100644 --- a/gns3/crash_report.py +++ b/gns3/crash_report.py @@ -50,7 +50,7 @@ class CrashReport: Report crash to a third party service """ - DSN = "https://7163314dc7e72cc6528f3e200a9224ec@o19455.ingest.sentry.io/38506" + DSN = "https://85829ec3496883de83c445deb55eecc8@o19455.ingest.sentry.io/38506" _instance = None def __init__(self): diff --git a/gns3/version.py b/gns3/version.py index b626549e5..49cad6f42 100644 --- a/gns3/version.py +++ b/gns3/version.py @@ -23,8 +23,8 @@ # or negative for a release candidate or beta (after the base version # number has been incremented) -__version__ = "2.2.45.dev3" -__version_info__ = (2, 2, 45, 99) +__version__ = "2.2.45" +__version_info__ = (2, 2, 45, 0) if "dev" in __version__: try: