{"record":{"id":"99ef987ed3d36b9d","repo":"pentaho/pentaho-kettle","slug":"execprocessmeta-exception-unexpectederrorreadingstepinfo","errorCode":null,"errorMessage":"ExecProcessMeta.Exception.UnexpectedErrorReadingStepInfo","messagePattern":"ExecProcessMeta\\.Exception\\.UnexpectedErrorReadingStepInfo","errorType":"exception","errorClass":"KettleException","httpStatus":null,"severity":"error","filePath":"engine/src/main/java/org/pentaho/di/trans/steps/execprocess/ExecProcessMeta.java","lineNumber":294,"sourceCode":"    try {\n      processfield = rep.getStepAttributeString( id_step, \"processfield\" );\n      resultfieldname = rep.getStepAttributeString( id_step, \"resultfieldname\" );\n      errorfieldname = rep.getStepAttributeString( id_step, \"errorfieldname\" );\n      exitvaluefieldname = rep.getStepAttributeString( id_step, \"exitvaluefieldname\" );\n      failwhennotsuccess = rep.getStepAttributeBoolean( id_step, \"failwhennotsuccess\" );\n      outputLineDelimiter = rep.getStepAttributeString( id_step, \"outputlinedelimiter\" );\n      if ( outputLineDelimiter == null ) {\n        outputLineDelimiter = \"\"; // default to empty string for backward compatibility\n      }\n      argumentsInFields = rep.getStepAttributeBoolean( id_step, \"argumentsInFields\" );\n\n      int argCount = rep.countNrStepAttributes( id_step, \"argumentFieldName\" );\n      argumentFieldNames = new String[argCount];\n      for ( int i = 0; i < argCount; i++ ) {\n        argumentFieldNames[i] = rep.getStepAttributeString( id_step, i, \"argumentFieldName\" );\n      }\n    } catch ( Exception e ) {\n      throw new KettleException( BaseMessages.getString(\n        PKG, \"ExecProcessMeta.Exception.UnexpectedErrorReadingStepInfo\" ), e );\n    }\n  }\n\n  @Override\n  public void saveRep( Repository rep, IMetaStore metaStore, ObjectId id_transformation, ObjectId id_step ) throws KettleException {\n    try {\n      rep.saveStepAttribute( id_transformation, id_step, \"processfield\", processfield );\n      rep.saveStepAttribute( id_transformation, id_step, \"resultfieldname\", resultfieldname );\n      rep.saveStepAttribute( id_transformation, id_step, \"errorfieldname\", errorfieldname );\n      rep.saveStepAttribute( id_transformation, id_step, \"exitvaluefieldname\", exitvaluefieldname );\n      rep.saveStepAttribute( id_transformation, id_step, \"failwhennotsuccess\", failwhennotsuccess );\n      rep.saveStepAttribute( id_transformation, id_step, \"outputlinedelimiter\", outputLineDelimiter );\n      rep.saveStepAttribute( id_transformation, id_step, \"argumentsInFields\", argumentsInFields );\n      for ( int i = 0; i < argumentFieldNames.length; i++ ) {\n        rep.saveStepAttribute( id_transformation, id_step, i, \"argumentFieldName\", argumentFieldNames[i] );\n      }\n    } catch ( Exception e ) {","sourceCodeStart":276,"sourceCodeEnd":312,"githubUrl":"https://github.com/pentaho/pentaho-kettle/blob/f3058517a153da500bf4551f46d79b91bf8ec552/engine/src/main/java/org/pentaho/di/trans/steps/execprocess/ExecProcessMeta.java#L276-L312","documentation":"KettleException thrown by ExecProcessMeta.readRep() when an unexpected Exception occurs while reading the ExecProcess step's settings from the repository (e.g. counting/reading argumentFieldName attributes). It wraps the original exception so the step's metadata cannot be loaded from a repository. The library throws it as a catch-all around repository reads in readRep().","triggerScenarios":"Calling readRep() on an ExecProcessMeta when Repository.countNrStepAttributes() or Repository.getStepAttributeString(id_step, i, \"argumentFieldName\") throws — corrupt repository rows, DB connection failure, or bad id_step.","commonSituations":"Repository database partially migrated or corrupted; transformation loaded from an incompatible repository schema version; transient JDBC connection drop while loading a transformation containing an Execute a process step.","solutions":["Inspect the wrapped cause exception (KettleException.getCause()) to find the real repository/JDBC error.","Verify repository connectivity and re-test with a database health check.","Re-save the affected transformation step in Spoon to rewrite its repository attributes.","If repository schema is stale, run the repository upgrade/migration scripts matching your Pentaho version."],"exampleFix":"// before: opaque failure\nTransMeta tm = new TransMeta(rep, transName, directory);\n// after: log the root cause\ntry {\n  TransMeta tm = new TransMeta(rep, transName, directory);\n} catch (KettleException e) {\n  log.error(\"Step meta load failed\", e.getCause());\n}","handlingStrategy":"try-catch","validationCode":"if (rep == null || id_step == null) throw new IllegalArgumentException(\"repository and id_step required\");","typeGuard":null,"tryCatchPattern":"try { meta.readRep(rep, metaStore, id_step, databases); } catch (KettleException e) { log.error(\"step meta read failed: \" + e.getCause(), e); }","preventionTips":["Keep repository database healthy and migrations current","Always inspect getCause() on wrapped KettleExceptions","Back up repository before upgrades"],"tags":["repository","metadata-load","kettle"],"backgroundTag":"database-query-failed","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"}