X Tutup
The Wayback Machine - https://web.archive.org/web/20250613184151/https://github.com/python/cpython/issues/92683
Skip to content

Opening a new unfocused tab in Chrome with webbrowser.open #92683

Open
@fredericomattos

Description

@fredericomattos

OS → Microsoft Windows 11
Chrome Version → 101.0.4951.54 (official version) 64 bits

I have Google website open and I want to open the Stackoverflow website in a new tab but the screen keeps showing the Google website.

All possible combinations I've tried to use but the page still opens and pulls the focus to it, my attempts were:

sof = 'https://stackoverflow.com'
webbrowser.open(sof, new=0, autoraise=False)
webbrowser.open(sof, new=2, autoraise=False)
webbrowser.open(sof, new=0, autoraise=True)
webbrowser.open(sof, new=2, autoraise=True)

All indications of use for such a function, lead me to the webbrowser + autoraise, I believe there is a problem.

Metadata

Metadata

Assignees

No one assigned

    Labels

    OS-windowsstdlibPython modules in the Lib dirtype-bugAn unexpected behavior, bug, or error

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      X Tutup