mirror of
https://github.com/Abdess/retroarch_system.git
synced 2026-11-23 10:07:48 -06:00
16 lines
528 B
Python
16 lines
528 B
Python
"""The headless Chromium that rasterises the committed icons and sharing cards."""
|
|
|
|
from __future__ import annotations
|
|
|
|
from typing import Any
|
|
|
|
|
|
def require_playwright() -> Any:
|
|
"""Playwright's sync_playwright, or an exit naming what to install: the
|
|
image tools need it, the site build never does."""
|
|
try:
|
|
from playwright.sync_api import sync_playwright
|
|
except ImportError as exc:
|
|
raise SystemExit("Playwright with Chromium is needed: pip install playwright") from exc
|
|
return sync_playwright
|