browserstartup

package
v1.5.131 Latest Latest
Warning

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

Go to latest
Published: Nov 22, 2026 License: MIT Imports: 11 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 browserstartup carries bounded startup diagnostics between a browser pane and its launcher. It records no post-CDP browser output or user input.

Index

Constants

View Source
const Limit = 16 << 10

Variables

This section is empty.

Functions

func FailureKind

func FailureKind(phase, text string) string

func Sanitize

func Sanitize(r *redact.Redactor, text string) string

Types

type Report

type Report struct {
	Phase    string `json:"phase"`
	State    string `json:"state"`
	Kind     string `json:"kind,omitempty"`
	Error    string `json:"error,omitempty"`
	Output   string `json:"output,omitempty"`
	ExitCode int    `json:"exit_code,omitempty"`
}

func Read

func Read(path string) (Report, error)

func (Report) Message

func (r Report) Message() string

Message is untrusted, bounded, redacted diagnostic text, never instructions.

type Reporter

type Reporter struct {
	// contains filtered or unexported fields
}

func New

func New(path string) (*Reporter, error)

func (*Reporter) ErrorText

func (s *Reporter) ErrorText(err error) string

func (*Reporter) Fail

func (s *Reporter) Fail(err error, code int)

func (*Reporter) Phase

func (s *Reporter) Phase(phase string)

func (*Reporter) Snapshot

func (s *Reporter) Snapshot() Report

func (*Reporter) Write

func (s *Reporter) Write(p []byte) (int, error)

Write retains only the FIRST bounded portion of startup stderr, never a growing log. Truncation happens before persistence, and incomplete trailing lines are discarded so a cut secret is not written without its rule prefix.

Jump to

Keyboard shortcuts

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