MCPcopy Create free account
hub / github.com/aboutcode-org/scancode-toolkit / parent_path

Method parent_path

src/commoncode/resource.py:1503–1507  ·  view source on GitHub ↗

Return the parent Resource object for this Resource or None.

(self)

Source from the content-addressed store, hash-verified

1501 return not self.is_root
1502
1503 def parent_path(self):
1504 """
1505 Return the parent Resource object for this Resource or None.
1506 """
1507 return self.has_parent() and parent_directory(self.path, with_trail=False)
1508
1509 def parent(self, codebase):
1510 """

Callers 3

parentMethod · 0.95
find_referenced_resourceFunction · 0.80

Calls 2

has_parentMethod · 0.95
parent_directoryFunction · 0.90

Tested by

no test coverage detected