risingwavelabs/risingwave · error
Invalid actor traces format
Error message
Invalid actor traces format
What it means
The `risectl` await-tree dump command validates the --actor-traces-format flag and only accepts "text" or "json" (omitting it defaults to json). Any other string causes this anyhow error, aborting before contacting the meta node.
Solutions
- Pass exactly "text" or "json" as the format value.
- Omit the flag entirely to use the default (json).
- Check script variables feeding the flag for empty/misspelled values.
Example fix
// before risectl await-tree dump --actor-traces-format pretty // after risectl await-tree dump --actor-traces-format text
Defensive patterns
Strategy: validation
Validate before calling
fn validate_traces_format(v: &Option<String>) -> bool {
matches!(v.as_deref(), None | Some("text") | Some("json"))
} Try / catch
let res = risectl::cmd_impl::await_tree::dump(&ctx, fmt).await;
if let Err(e) = res {
eprintln!("await-tree dump failed: {e}; use --actor-traces-format text|json");
} Prevention
- Only pass "text" or "json" to --actor-traces-format
- Omit the flag for the json default
- Guard shell variables feeding the flag against empty values
When it happens
Trigger: Running `risectl await-tree dump --actor-traces-format <value>` with a value other than "text" or "json", e.g. "Text", "pretty", "txt" or an empty-but-set string.
Common situations: Typo or wrong casing in the CLI flag value; copying a format name from another tool; scripts passing a variable that is empty or malformed.
Understand the failure class
Background: "Must be a positive integer", "Invalid value", "Unsupported": the invalid-argument-value error family, when a library rejects the value you pass — this error's family across 35 libraries.
Related errors
- exactly one of job_id or fragment_id must be provided
- cannot decode user key
- error parsing with props json
- missing 'connector' in with clause
- No offsets provided to inject
AI-assisted analysis of risingwavelabs/risingwave@6469eb736d (2026-09-11).
Data as JSON: /api/errors/0b03636998ab3f48.
Report an issue: GitHub.
Appendix: source
Thrown at src/ctl/src/cmd_impl/await_tree.rs:30
// See the License for the specific language governing permissions and
// limitations under the License.
use risingwave_common::util::StackTraceResponseExt;
use risingwave_pb::common::WorkerType;
use risingwave_pb::id::WorkerId;
use risingwave_pb::monitor_service::StackTraceRequest;
use risingwave_pb::monitor_service::stack_trace_request::ActorTracesFormat;
use risingwave_rpc_client::MonitorClientPool;
use rw_diagnose_tools::await_tree::AnalyzeSummary;
use thiserror_ext::AsReport as _;
use crate::CtlContext;
pub async fn dump(context: &CtlContext, actor_traces_format: Option<String>) -> anyhow::Result<()> {
let actor_traces_format = match actor_traces_format.as_deref() {
Some("text") => ActorTracesFormat::Text,
Some("json") | None => ActorTracesFormat::Json,
_ => return Err(anyhow::anyhow!("Invalid actor traces format")),
};
// Query the meta node for the await tree of all nodes in the cluster.
let meta_client = context.meta_client().await?;
let all = meta_client
.get_cluster_stack_trace(actor_traces_format)
.await?;
if all.actor_traces.is_empty()
&& all.rpc_traces.is_empty()
&& all.batch_traces.is_empty()
&& all.compaction_task_traces.is_empty()
&& all.inflight_barrier_traces.is_empty()
{
eprintln!("No actors are running, or `--async-stack-trace` not set?");
}
println!("{}", all.output());
View on GitHub (pinned to 6469eb736d)