pentaho/pentaho-kettle · error · RuntimeException
An error was detected in the step attributes' definition…
Error message
An error was detected in the step attributes' definition: the parent was not found for attribute {0} What it means
Thrown by BaseStepMeta.getStepInjectionMetadataEntries when building the step injection metadata tree. Each KettleAttribute may declare a parent attribute key; if the parent's entry cannot be found among the entries already built, the attribute hierarchy is inconsistent. This is a bug in the step metadata definition, not a user configuration error.
Solutions
- Check the custom step's attribute definitions and ensure every parentId/key references an attribute that exists in the list before the child.
- Fix typos in the parent key string or remove the stale parentId from the child attribute.
- Ensure the parent attribute is registered/added before its children so findParentEntry can locate it.
- If loading from a JSON step attributes file, verify the file contains the parent attribute definition.
Example fix
// before
new KettleAttribute("rows_limit", "ROWS_LIMIT", null, "Row limit", "", ValueMetaInterface.TYPE_INTEGER, findParent(attributes, "row_lmit"));
// after
new KettleAttribute("rows_limit", "ROWS_LIMIT", null, "Row limit", "", ValueMetaInterface.TYPE_INTEGER, findParent(attributes, "row_limit")); Defensive patterns
Strategy: validation
Validate before calling
// Validate attribute hierarchy before building injection entries
for (KettleAttribute attr : attributes) {
if (attr.getParent() != null) {
boolean found = attributes.stream().anyMatch(a -> a.getKey().equals(attr.getParent().getKey()));
if (!found) throw new IllegalStateException("Missing parent for attribute " + attr.getKey());
}
} Try / catch
try { entries = meta.getStepInjectionMetadataEntries(); } catch (RuntimeException e) { if (e.getMessage().contains("parent was not found")) { log.error("Broken attribute hierarchy in step meta: " + e.getMessage()); } else { throw e; } } Prevention
- Always register the parent attribute before its children
- Extract parent key strings into constants to avoid typos
- Add a unit test that builds injection metadata entries for every custom step meta
When it happens
Trigger: Calling getStepInjectionMetadataEntries() on a step meta whose KettleAttribute list references a parent key that is not present in the attributes list, or whose parent entry appears after the child in iteration order so findParentEntry() misses it.
Common situations: Custom step plugin developers define a KettleAttribute with a parentId that was never registered (typo in the key, parent attribute removed during refactoring, or attributes loaded from an incomplete STEP_ATTRIBUTES_FILE).
Understand the failure class
Background: "Not found" and "does not exist" errors: why "Task not found", "No such folder", and "Can't find" fire when a lookup comes back empty — this error's family across 14 libraries.
Related errors
- AccessInputMeta.Exception.ErrorReadingRepository
- AggregateRowsMeta.Exception.UnexpectedErrorWhileReadingStepInfo
- AggregateRowsMeta.Exception.UnableToLoadStepInfo
- AggregateRowsMeta.Exception.UnableToSaveStepInfo
- ConcatFieldsMeta.CheckResult.TargetFieldNameMissing
AI-assisted analysis of pentaho/pentaho-kettle@f3058517a1 (2026-09-13).
Data as JSON: /api/errors/2862d5342fc4d11d.
Report an issue: GitHub.
Appendix: source
Thrown at engine/src/main/java/org/pentaho/di/trans/step/BaseStepMeta.java:927
protected StepInjectionMetaEntry createEntry( KettleAttributeInterface attr, Class<?> PKG ) {
return new StepInjectionMetaEntry( attr.getKey(), attr.getType(), BaseMessages.getString( PKG, attr
.getDescription() ) );
}
/**
* Describe the metadata attributes that can be injected into this step metadata object.
*/
public List<StepInjectionMetaEntry> getStepInjectionMetadataEntries( Class<?> PKG ) {
List<StepInjectionMetaEntry> entries = new ArrayList<StepInjectionMetaEntry>();
for ( KettleAttributeInterface attr : attributes ) {
if ( attr.getParent() == null ) {
entries.add( createEntry( attr, PKG ) );
} else {
StepInjectionMetaEntry entry = createEntry( attr, PKG );
StepInjectionMetaEntry parentEntry = findParentEntry( entries, attr.getParent().getKey() );
if ( parentEntry == null ) {
throw new RuntimeException(
"An error was detected in the step attributes' definition: the parent was not found for attribute "
+ attr );
}
parentEntry.getDetails().add( entry );
}
}
return entries;
}
/**
* Load step attributes.
*
* @throws KettleException the kettle exception
*/
protected void loadStepAttributes() throws KettleException {
try ( InputStream inputStream = getClass().getResourceAsStream( STEP_ATTRIBUTES_FILE ) ) {
if ( inputStream != null ) {View on GitHub (pinned to f3058517a1)