{"record":{"id":"cae789333c46ffe3","repo":"pentaho/pentaho-kettle","slug":"filterrowsmeta-exception-unabletoloadstepinfofromxml","errorCode":"FilterRowsMeta.Exception..UnableToLoadStepInfoFromXML","errorMessage":"FilterRowsMeta.Exception..UnableToLoadStepInfoFromXML","messagePattern":"FilterRowsMeta\\.Exception\\.\\.UnableToLoadStepInfoFromXML","errorType":"exception","errorClass":"KettleXMLException","httpStatus":null,"severity":"error","filePath":"engine/src/main/java/org/pentaho/di/trans/steps/filterrows/FilterRowsMeta.java","lineNumber":187,"sourceCode":"            String comparator = XMLHandler.getTagValue( knode, \"condition\" );\n\n            Condition subc = new Condition();\n            if ( i > 0 ) {\n              subc.setOperator( Condition.OPERATOR_OR );\n            } else {\n              subc.setOperator( Condition.OPERATOR_NONE );\n            }\n            subc.setLeftValuename( key );\n            subc.setFunction( Condition.getFunction( comparator ) );\n            subc.setRightValuename( field );\n            subc.setRightExact( new ValueMetaAndData( \"value\", value ) );\n\n            condition.addCondition( subc );\n          }\n        }\n      }\n    } catch ( Exception e ) {\n      throw new KettleXMLException( BaseMessages.getString(\n        PKG, \"FilterRowsMeta.Exception..UnableToLoadStepInfoFromXML\" ), e );\n    }\n  }\n\n  public void setDefault() {\n    allocate();\n  }\n\n  public void readRep( Repository rep, IMetaStore metaStore, ObjectId id_step, List<DatabaseMeta> databases ) throws KettleException {\n    try {\n      allocate();\n\n      setTrueStepname( rep.getStepAttributeString( id_step, \"send_true_to\" ) );\n      setFalseStepname( rep.getStepAttributeString( id_step, \"send_false_to\" ) );\n\n      condition = rep.loadConditionFromStepAttribute( id_step, \"id_condition\" );\n\n    } catch ( Exception e ) {","sourceCodeStart":169,"sourceCodeEnd":205,"githubUrl":"https://github.com/pentaho/pentaho-kettle/blob/f3058517a153da500bf4551f46d79b91bf8ec552/engine/src/main/java/org/pentaho/di/trans/steps/filterrows/FilterRowsMeta.java#L169-L205","documentation":"FilterRowsMeta.readData recursively parses the Condition XML (including nested sub-conditions) when loading the step from a .ktr. Any exception during that parse is wrapped in a KettleXMLException with this message, meaning the filter's step info could not be loaded from the transformation XML.","triggerScenarios":"loadXML -> readData: XMLHandler/Condition construction throws while parsing the <condition> node - malformed or hand-edited condition XML, unknown/nested elements, or incompatible condition serialization from another version.","commonSituations":"Hand-edited or merged .ktr files where the <condition> block is inconsistent; transformations produced by third-party generators; version upgrade changed the condition XML schema.","solutions":["Inspect the <condition> XML block of the Filter step in the .ktr and fix malformed structure.","Delete and re-create the Filter step in Spoon if the condition cannot be parsed.","Restore the .ktr from backup/version control and re-apply changes carefully."],"exampleFix":"// before (malformed condition)\n<condition><negated>Y</condition>\n// after\n<condition><negated>Y</negated></condition>","handlingStrategy":"try-catch","validationCode":"// Sanity-check the condition XML before load:\nNode stepnode = XMLHandler.getSubNode(doc, \"transformation\", \"step\");\nif (XMLHandler.getSubNode(stepnode, \"condition\") == null) {\n  throw new IllegalArgumentException(\"Filter step has no <condition> element\");\n}","typeGuard":null,"tryCatchPattern":"try {\n  TransMeta tm = new TransMeta(\"trans.ktr\");\n} catch (KettleXMLException e) {\n  if (e.getMessage().contains(\"UnableToLoadStepInfoFromXML\")) {\n    log.error(\"Filter step condition XML invalid - inspect <condition> block\", e);\n  }\n  throw e;\n}","preventionTips":["Avoid hand-editing or programmatically generating condition XML; build steps via the meta API.","Version-control .ktr files so corrupt conditions can be reverted.","Round-trip load every generated transformation in Spoon before distributing it."],"tags":["kettle","xml-parse","step-metadata"],"backgroundTag":"xml-parse-error","analyzedSha":"f3058517a153da500bf4551f46d79b91bf8ec552","analyzedAt":"2026-09-13T14:04:16.340Z","contentChangedAt":"2026-09-13T14:04:16.340Z","schemaVersion":2},"datasetVersion":"2026-09-20T23:17:15.980Z"}