tsenart/vegeta · error

vegeta dump has been deprecated and succeeded by the vegeta

Error message

vegeta dump has been deprecated and succeeded by the vegeta encode command

What it means

The `vegeta dump` command has been removed and permanently returns this deprecation error; its functionality was replaced by `vegeta encode`. Any invocation of dump fails with this message by design.

Source

Thrown at dump.go:9

package main

import (
	"fmt"
)

func dumpCmd() command {
	return command{fn: func([]string) error {
		return fmt.Errorf("vegeta dump has been deprecated and succeeded by the vegeta encode command")
	}}
}

View on GitHub (pinned to cf58112690)

Solutions

  1. Replace `vegeta dump` with `vegeta encode`, specifying `-from`/`-to` encodings as needed.
  2. Update scripts/CI to call `vegeta encode` (e.g. `vegeta encode -from=gob -to=json`).
  3. Pin an older vegeta version only as a last resort if the legacy dump behavior is truly required.

Example fix

// before
vegeta dump -from=gob -to=json < results.gob > results.json
// after
vegeta encode -from=gob -to=json < results.gob > results.json
Defensive patterns

Strategy: fallback

Validate before calling

if cmd == "dump" {
    cmd = "encode" // dump is deprecated; map to encode
}

Try / catch

out, err := exec.Command("vegeta", "dump", args...).CombinedOutput()
if err != nil && strings.Contains(string(out), "deprecated") {
    out, err = exec.Command("vegeta", "encode", args...).CombinedOutput()
}

Prevention

When it happens

Trigger: Running `vegeta dump` in any form on a vegeta version that ships the deprecated stub command (dump.go returns the error unconditionally).

Common situations: Scripts or CI pipelines migrated from old vegeta versions that still call `vegeta dump`; documentation or tutorials predating the encode command.

Related errors


AI-assisted analysis of tsenart/vegeta@cf58112690 (2026-08-31). Data as JSON: /api/errors/42a31387192225c7. Report an issue: GitHub.