pywebbrowser

package
v1.1.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 21, 2026 License: MIT Imports: 14 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Overview

Package pywebbrowser opens URLs the way the CPython 3.14 webbrowser module does

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Open

func Open(url string, new int) (bool, error)

Shows the url in the first browser of the try order that accepts it, new 0 same window, 1 window, 2 tab

func ScriptForTests

func ScriptForTests(env map[string]string, onPath ...string) (restore func())

ScriptForTests builds the registry anew from a scripted environment and search path until the returned restore runs

Types

type Controller

type Controller struct {
	Name     string
	Basename string
}

Name and basename of a resolved controller

func Get

func Get() (Controller, error)

First controller of the try order that resolves, an Error when none does

type Error

type Error struct{ Msg string }

Failure webbrowser.Error reports, no runnable browser or a bad new value

func (*Error) Error

func (e *Error) Error() string

func (*Error) PyTypeName

func (e *Error) PyTypeName() string

Python exception class of the failure

type IndexError

type IndexError struct{ Msg string }

Failure of a blank BROWSER entry whose first word is read

func (*IndexError) Error

func (e *IndexError) Error() string

func (*IndexError) PyTypeName

func (e *IndexError) PyTypeName() string

Python exception class of the failure

type ValueError

type ValueError struct{ Msg string }

Refusal of a url whose first non blank character is a dash

func (*ValueError) Error

func (e *ValueError) Error() string

func (*ValueError) PyTypeName

func (e *ValueError) PyTypeName() string

Python exception class of the refusal

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL