prestodb/presto · error · TypeError
{type} no abstract type InputDistribution
Error message
{type} no abstract type InputDistribution What it means
Velox protocol serialization error: serializing an InputDistribution whose _type discriminator is not '.BaseInputDistribution' (the only known subclass). to_json falls through all recognized branches and throws TypeError, meaning an unknown InputDistribution subclass reached the native protocol layer.
Source
Thrown at presto-native-execution/presto_cpp/presto_protocol/core/presto_protocol_core.cpp:3853
p.schemaTableName,
"DeleteHandle",
"SchemaTableName",
"schemaTableName");
}
} // namespace facebook::presto::protocol
namespace facebook::presto::protocol {
void to_json(json& j, const std::shared_ptr<InputDistribution>& p) {
if (p == nullptr) {
return;
}
String type = p->_type;
if (type == ".BaseInputDistribution") {
j = *std::static_pointer_cast<BaseInputDistribution>(p);
return;
}
throw TypeError(type + " no abstract type InputDistribution ");
}
void from_json(const json& j, std::shared_ptr<InputDistribution>& p) {
String type;
try {
type = p->getSubclassKey(j);
} catch (json::parse_error& e) {
throw ParseError(
std::string(e.what()) + " InputDistribution InputDistribution");
}
if (type == ".BaseInputDistribution") {
std::shared_ptr<BaseInputDistribution> k =
std::make_shared<BaseInputDistribution>();
j.get_to(*k);
p = std::static_pointer_cast<InputDistribution>(k);
return;
}View on GitHub (pinned to 55bb57d202)
Solutions
- Ensure only BaseInputDistribution instances are used in native plans
- Add the missing subclass to the C++ protocol mapping
- Check for protocol drift between Java and presto_cpp versions
Defensive patterns
Strategy: type-guard
When it happens
Trigger: Thrown at presto-native-execution/presto_cpp/presto_protocol/core/presto_protocol_core.cpp:3853 when the library encounters an invalid state.
Common situations: See trigger scenarios.
AI-assisted analysis of prestodb/presto@55bb57d202 (2026-09-04).
Data as JSON: /api/errors/b7258d103c3719ef.
Report an issue: GitHub.