uxlog

package
v0.7.0 Latest Latest
Warning

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

Go to latest
Published: Jun 11, 2026 License: MIT Imports: 9 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 uxlog is the shared UX shell for the scripts/ live runners (live-smoke). It standardises the N/M step framing, the end-of-run summary block, and the error-to-hint mapping so the orchestrators stay surface-compatible without copy-paste.

Not part of the public SDK -- script-local on purpose. Stderr output only; stdout stays clean for subprocess composition.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func HintForError

func HintForError(err error) string

HintForError maps a typed SDK error to a one-line operator hint. Empty string when no specific guidance applies; callers should fall back to the raw error text in that case rather than synthesising fake advice.

func Redact

func Redact(email string) string

Redact keeps just the @domain part of an email for log breadcrumbs. Same shape as scripts/live-smoke's local helper, lifted here so both orchestrators share one implementation.

func Step

func Step(logger *slog.Logger, idx, total int, name string, fn func() error) error

Step runs fn as one labelled step. The N/M counter, name, ok/FAILED suffix and elapsed time get logged uniformly. Returns fn's error so the caller can decide whether to abort or continue.

func Summary

func Summary(scriptName, accountRedacted string, started time.Time, passed, failed, skipped []string, nextHint string)

Summary is the end-of-run block printed to stderr. Plain ASCII so it stays readable in CI logs and subprocess pipes. nextHint may be empty.

Types

This section is empty.

Jump to

Keyboard shortcuts

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