clockworklabs/SpacetimeDB · error
unknown misc export
Error message
unknown misc export
What it means
After procedure exports are sorted out earlier in the pipeline, check_non_procedure_misc_exports (crates/schema/src/def/validate/v9.rs:1620) handles only ColumnDefaultValue; the Procedure arm is unreachable!() (proving the list is pre-filtered) and every other misc-export variant hits unimplemented!(). The branch exists to catch module ABIs carrying export kinds this host cannot interpret.
Source
Thrown at crates/schema/src/def/validate/v9.rs:1620
}
}
ErrorStream::add_extra_errors(Ok((reducers_map, procedures_map, views_map)), errors)
}
fn check_non_procedure_misc_exports(
misc_exports: Vec<RawMiscModuleExportV9>,
validator: &ModuleValidatorV9,
tables: &mut IdentifierMap<TableDef>,
) -> Result<()> {
misc_exports
.into_iter()
.map(|export| match export {
RawMiscModuleExportV9::ColumnDefaultValue(cdv) => process_column_default_value(&cdv, validator, tables),
RawMiscModuleExportV9::Procedure(_proc) => {
unreachable!("Procedure defs should already have been sorted out of `misc_exports`")
}
_ => unimplemented!("unknown misc export"),
})
.collect_all_errors::<()>()
}
fn process_column_default_value(
cdv: &RawColumnDefaultValueV9,
validator: &ModuleValidatorV9,
tables: &mut IdentifierMap<TableDef>,
) -> Result<()> {
// Validate the default value
let validated_value = validator.validate_column_default_value(tables, cdv)?;
let table_name = validator.core.resolve_identifier_with_case(cdv.table.clone())?;
let table = tables
.get_mut(&table_name)
.ok_or_else(|| ValidationError::TableNotFound {
table: cdv.table.clone(),
})?;View on GitHub (pinned to 524b4487d9)
Solutions
- Align versions: update the host, or pin the SDK to the host's version, then rebuild the module and republish
- Disable/remove preview module features that emit new export kinds
- Verify with spacetime version that module toolchain and host agree before publishing
Defensive patterns
Strategy: validation
Validate before calling
# Gate publish on version compatibility: HOST=$(spacetime version) SDK=$(cargo tree -p spacetimedb --depth 0 | grep -o 'spacetimedb v[0-9.]*') # fail the pipeline if SDK major.minor > HOST major.minor before calling spacetime publish
Prevention
- Keep one source of truth for the SpacetimeDB version across module SDK, CLI, and server
- Avoid preview module features in production publishes
- Smoke-publish to a throwaway database after any version bump
When it happens
Trigger: Publishing a module whose ABI contains a misc export other than a column default value or a procedure — typically a module produced by a newer SDK enabling a feature the host predates.
Common situations: Version skew: module built with a preview/newer spacetimedb SDK while the server runs an older minor; enabling experimental module features in Rust and publishing to a stable cluster.
Related errors
- Unknown constraint type
- Unknown index algorithm {:?}
- Index '${indexLabel}' on table '${tableLabel}' must define a
- never types are not yet supported in C# output
- cannot serialize refs without a typespace
AI-assisted analysis of clockworklabs/SpacetimeDB@524b4487d9 (2026-08-16).
Data as JSON: /api/errors/a52137c2b2d545ed.
Report an issue: GitHub.