MCPcopy Create free account
hub / github.com/aboutcode-org/vulnerablecode / get_advisory_url

Function get_advisory_url

vulnerabilities/utils.py:563–569  ·  view source on GitHub ↗

Return the advisory URL constructed by combining the base URL with the relative file path.

(file, base_path, url)

Source from the content-addressed store, hash-verified

561
562
563def get_advisory_url(file, base_path, url):
564 """
565 Return the advisory URL constructed by combining the base URL with the relative file path.
566 """
567 relative_path = str(file.relative_to(base_path)).strip("/")
568 advisory_url = urljoin(url, relative_path)
569 return advisory_url
570
571
572def purl_to_dict(purl: Union[PackageURL, str], with_empty: bool = True):

Callers 15

parse_gitlab_advisoryFunction · 0.90
collect_advisoriesMethod · 0.90
collect_advisoriesMethod · 0.90
parse_advisory_dataFunction · 0.90
collect_advisoriesMethod · 0.90
collect_advisoriesMethod · 0.90
parse_advisoryFunction · 0.90
parse_gitlab_advisoryFunction · 0.90
collect_advisoriesMethod · 0.90
collect_advisoriesMethod · 0.90
collect_advisoriesMethod · 0.90
collect_advisoriesMethod · 0.90

Calls

no outgoing calls

Tested by

no test coverage detected