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

Method handle

vulnerabilities/management/commands/export.py:79–88  ·  view source on GitHub ↗
(self, *args, **options)

Source from the content-addressed store, hash-verified

77 )
78
79 def handle(self, *args, **options):
80 if path := options["path"]:
81 base_path = Path(path)
82
83 if not path or not base_path.is_dir():
84 raise CommandError("Enter a valid directory path")
85
86 self.stdout.write("Exporting vulnerablecode Package and Vulnerability data.")
87 self.export_data(base_path)
88 self.stdout.write(self.style.SUCCESS(f"Successfully exported data to {base_path}."))
89
90 def export_data(self, base_path: Path):
91 """

Callers

nothing calls this directly

Calls 2

export_dataMethod · 0.95
writeMethod · 0.80

Tested by

no test coverage detected