Browse Source

Location.canonical_path: fix protocol, see #8446

 % borg repo-info
Location: rclone://None/./pcloud:justtesting
...
Thomas Waldmann 8 months ago
parent
commit
333663c39c
1 changed files with 2 additions and 1 deletions
  1. 2 1
      src/borg/helpers/parseformat.py

+ 2 - 1
src/borg/helpers/parseformat.py

@@ -616,7 +616,8 @@ class Location:
                 path = "/./" + self.path  # /./x = path x relative to cwd
             else:
                 path = self.path
-            return "ssh://{}{}{}{}".format(
+            return "{}://{}{}{}{}".format(
+                self.proto if self.proto else "???",
                 f"{self.user}@" if self.user else "",
                 self._host,  # needed for ipv6 addrs
                 f":{self.port}" if self.port else "",