MCPcopy Create free account
hub / github.com/microsoft/Webwright / main

Function main

src/webwright/run/cli.py:138–163  ·  view source on GitHub ↗
(
    task: str = typer.Option(
        ..., "-t", "--task", help="Natural language task description."
    ),
    task_id: str | None = typer.Option(
        None, "--task-id", help="Optional identifier used in the output directory name."
    ),
    start_url: str | None = typer.Option(
        None, "--start-url", help="Optional starting URL for the task."
    ),
    config_spec: list[str] = typer.Option(DEFAULT_CONFIGS, "-c", "--config"),
    output_dir: Path | None = typer.Option(None, "-o", "--output-dir"),
    debug: bool = typer.Option(
        False,
        "--debug",
        help="Launch headed local Playwright with devtools and keep it open for inspection.",
    ),
)

Source from the content-addressed store, hash-verified

136
137@app.command()
138def main(
139 task: str = typer.Option(
140 ..., "-t", "--task", help="Natural language task description."
141 ),
142 task_id: str | None = typer.Option(
143 None, "--task-id", help="Optional identifier used in the output directory name."
144 ),
145 start_url: str | None = typer.Option(
146 None, "--start-url", help="Optional starting URL for the task."
147 ),
148 config_spec: list[str] = typer.Option(DEFAULT_CONFIGS, "-c", "--config"),
149 output_dir: Path | None = typer.Option(None, "-o", "--output-dir"),
150 debug: bool = typer.Option(
151 False,
152 "--debug",
153 help="Launch headed local Playwright with devtools and keep it open for inspection.",
154 ),
155) -> Any:
156 return run_one(
157 task=task,
158 task_id=task_id,
159 start_url=start_url,
160 config_spec=config_spec,
161 output_dir=output_dir,
162 debug=debug,
163 )
164
165
166@app.command()

Callers

nothing calls this directly

Calls 1

run_oneFunction · 0.85

Tested by

no test coverage detected