From eecc6d9ffabdb86e8e35c823f6dae6ea5cfd9e51 Mon Sep 17 00:00:00 2001 From: Peter Corke Date: Sat, 22 Aug 2026 17:35:29 +1000 Subject: [PATCH] fix: track swift's SwiftElement.py -> Elements.py rename swift renamed src/swift/SwiftElement.py -> Elements.py (avoids a module/class name collision that was confusing mypy -- the file and the SwiftElement class inside it shared a name, and the class is re-exported at swift's package top level) -- jhavl/swift#141. roboticstoolbox/backends/swift/__init__.py imported directly from the submodule path (from swift.SwiftElement import ...) rather than from the swift package's own top-level re-exports, so it needs the same one-line fix to keep working once that rename ships in a released swift-sim version. Verified by loading this file standalone (importlib) against a swift checkout with the rename already applied -- resolves Swift, Slider, SwiftElement etc. correctly from swift.Elements. --- src/roboticstoolbox/backends/swift/__init__.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/roboticstoolbox/backends/swift/__init__.py b/src/roboticstoolbox/backends/swift/__init__.py index a75ca61db..529d6346a 100644 --- a/src/roboticstoolbox/backends/swift/__init__.py +++ b/src/roboticstoolbox/backends/swift/__init__.py @@ -1,5 +1,5 @@ from swift.SwiftRoute import SwiftServer, SwiftSocket, start_servers -from swift.SwiftElement import ( +from swift.Elements import ( SwiftElement, Slider, Select,