Skip to content

Surface capture degradation in the dashboard instead of stderr #280

Closed

Description

@vishnuv688

Part of #277

bidi.py, snapshot.py, screencast.py, lifecycle.py and
__init__.py warn with print(file=sys.stderr). terminal.py tees stdout only,
by design, and logcapture.py forwards records from the selenium_devtools
logger, so a raw stderr print reaches neither channel. Losing BiDi therefore
leaves the Console and Network panels silently empty with no explanation anywhere
in the UI.

Acceptance criteria

Every degradation warning routes through
logging.getLogger("selenium_devtools"). A run with BiDi unavailable states the
reason in the dashboard Console. A unit test asserts a warning reaches the
capturer.

Activity

  1. self-assigned this
    on Aug 12, 2026
  2. vishnuv688 commented on Aug 17, 2026

    @vishnuv688
    MemberAuthor

    Fixed on main in c043f0a + 8e50fcb.

    Every degradation warning now logs to the package logger (`selenium_devtools.`), so `LogCapturer` forwards it to the dashboard Console. Verified with `DEVTOOLS_BIDI=0`: the run states the reason instead of leaving Console and Network silently empty.

    Terminal visibility is unchanged without a dashboard, since `logging.lastResort` still puts a WARNING on stderr. `wait_for_dashboard_close` keeps its print deliberately: it explains why the terminal is blocking, so it has to be on the terminal, and lastResort ignores INFO.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

bugSomething isn't workingselenium-devtools-pyPython Selenium adapter for the DevTools dashboard

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions