[Path] Sanity fixed another bug found in testing

This commit is contained in:
Syres916
2023-09-25 14:18:38 +01:00
committed by GitHub
parent 0b6b72059a
commit 4c666d1454

View File

@@ -1202,6 +1202,11 @@ class CommandPathSanity:
if foundSub:
filepath = self.resolveOutputFile(obj)
Path.Log.debug("filepath: {}".format(filepath))
# Make sure the filepath is fully qualified
if os.path.basename(filepath) == filepath:
filepath = f"{os.path.dirname(FreeCAD.ActiveDocument.FileName)}/{filepath}"
Path.Log.debug("filepath: {}".format(filepath))
base_name = os.path.splitext(filepath)[0]
reporthtml = base_name + ".html"
else: