Help us shape the future of Go! Take the 2026 Go Developer Survey

span

package
v0.1.121 Latest Latest
Warning

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

Go to latest
Published: Sep 21, 2026 License: AGPL-3.0 Imports: 15 Imported by: 0

Documentation

Overview

Package span implements the `polycli heimdall span` umbrella command (alias `sp`) and its subcommands targeting Heimdall v2's `x/bor` module: params, latest, get, list, producers, seed, votes, downtime, scores, find.

Per HEIMDALLCAST_REQUIREMENTS.md §3.2.2 these endpoints live under a single umbrella rather than at the top level. The umbrella also accepts a bare integer (`span 5982`) as a shorthand for `span get 5982`.

Index

Constants

This section is empty.

Variables

View Source
var SpanCmd = &cobra.Command{
	Use:     "span [ID]",
	Aliases: []string{"sp"},
	Short:   "Query bor/span module endpoints.",
	Long:    usage,
	Args:    cobra.MaximumNArgs(1),

	RunE: func(cmd *cobra.Command, args []string) error {
		if len(args) == 0 {
			return cmd.Help()
		}
		if _, err := strconv.ParseUint(args[0], 10, 64); err != nil {
			return &client.UsageError{Msg: fmt.Sprintf("unknown span subcommand or id %q", args[0])}
		}
		return runGet(cmd, args[0])
	},
}

SpanCmd is the umbrella `span` command. Subcommands are attached by Register.

Functions

func Register

func Register(parent *cobra.Command, f *config.Flags)

Register attaches the span umbrella command and all of its subcommands to parent, wiring in the shared flag struct.

Every span subcommand is read-only, so we apply render.EnableWatchTree once here and every descendant gets a `--watch DURATION` flag.

Types

This section is empty.

Jump to

Keyboard shortcuts

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