MCPcopy
hub / github.com/scrapy/scrapy / _get_commands_from_module

Function _get_commands_from_module

scrapy/cmdline.py:54–60  ·  view source on GitHub ↗
(module: str, inproject: bool)

Source from the content-addressed store, hash-verified

52
53
54def _get_commands_from_module(module: str, inproject: bool) -> dict[str, ScrapyCommand]:
55 d: dict[str, ScrapyCommand] = {}
56 for cmd in _iter_command_classes(module):
57 if inproject or not cmd.requires_project:
58 cmdname = cmd.__module__.split(".")[-1]
59 d[cmdname] = cmd()
60 return d
61
62
63def _get_commands_from_entry_points(

Callers 1

_get_commands_dictFunction · 0.85

Calls 1

_iter_command_classesFunction · 0.85

Tested by

no test coverage detected