{"record":{"id":"7b02e9858a152672","repo":"pentaho/pentaho-kettle","slug":"unexpected-error-reading-step-information-from-the-7b02e9","errorCode":null,"errorMessage":"Unexpected error reading step information from the repository","messagePattern":"Unexpected error reading step information from the repository","errorType":"exception","errorClass":"KettleException","httpStatus":null,"severity":"error","filePath":"engine/src/main/java/org/pentaho/di/trans/steps/fixedinput/FixedInputMeta.java","lineNumber":212,"sourceCode":"      for ( int i = 0; i < nrfields; i++ ) {\n        FixedFileInputField field = new FixedFileInputField();\n\n        field.setName( rep.getStepAttributeString( id_step, i, \"field_name\" ) );\n        field.setType( ValueMetaFactory.getIdForValueMeta( rep.getStepAttributeString( id_step, i, \"field_type\" ) ) );\n        field.setFormat( rep.getStepAttributeString( id_step, i, \"field_format\" ) );\n        field.setTrimType( ValueMetaString\n          .getTrimTypeByCode( rep.getStepAttributeString( id_step, i, \"field_trim_type\" ) ) );\n        field.setCurrency( rep.getStepAttributeString( id_step, i, \"field_currency\" ) );\n        field.setDecimal( rep.getStepAttributeString( id_step, i, \"field_decimal\" ) );\n        field.setGrouping( rep.getStepAttributeString( id_step, i, \"field_group\" ) );\n        field.setWidth( (int) rep.getStepAttributeInteger( id_step, i, \"field_width\" ) );\n        field.setLength( (int) rep.getStepAttributeInteger( id_step, i, \"field_length\" ) );\n        field.setPrecision( (int) rep.getStepAttributeInteger( id_step, i, \"field_precision\" ) );\n\n        fieldDefinition[i] = field;\n      }\n    } catch ( Exception e ) {\n      throw new KettleException( \"Unexpected error reading step information from the repository\", e );\n    }\n  }\n\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, \"filename\", filename );\n      rep.saveStepAttribute( id_transformation, id_step, \"line_width\", lineWidth );\n      rep.saveStepAttribute( id_transformation, id_step, \"buffer_size\", bufferSize );\n      rep.saveStepAttribute( id_transformation, id_step, \"header\", headerPresent );\n      rep.saveStepAttribute( id_transformation, id_step, \"lazy_conversion\", lazyConversionActive );\n      rep.saveStepAttribute( id_transformation, id_step, \"line_feed\", lineFeedPresent );\n      rep.saveStepAttribute( id_transformation, id_step, \"parallel\", runningInParallel );\n      rep.saveStepAttribute( id_transformation, id_step, \"file_type\", getFileTypeCode( fileType ) );\n      rep.saveStepAttribute( id_transformation, id_step, \"encoding\", encoding );\n      rep.saveStepAttribute( id_transformation, id_step, \"add_to_result_filenames\", isaddresult );\n\n      for ( int i = 0; i < fieldDefinition.length; i++ ) {\n        rep.saveStepAttribute( id_transformation, id_step, i, \"field_name\", fieldDefinition[i].getName() );","sourceCodeStart":194,"sourceCodeEnd":230,"githubUrl":"https://github.com/pentaho/pentaho-kettle/blob/f3058517a153da500bf4551f46d79b91bf8ec552/engine/src/main/java/org/pentaho/di/trans/steps/fixedinput/FixedInputMeta.java#L194-L230","documentation":"FixedInputMeta.readRep wraps any exception while restoring the fixed-file input step's settings and field definitions from the repository in a KettleException with this message. The original repository error is chained as cause.","triggerScenarios":"readRep iterating nrfields field rows when getStepAttributeInteger/String throws or a value cannot be converted (e.g., non-numeric field_length/field_precision) for this id_step.","commonSituations":"Repository rows for the step manually modified or written by an incompatible PDI version; corrupted attribute values in r_step_attribute; repository connectivity problems while loading a transformation.","solutions":["Check the chained cause exception for the exact failing attribute","Inspect r_step_attribute rows for this id_step and fix or remove non-numeric field_length/field_precision values","Recreate the step definition in Spoon and re-save it","Verify repository version compatibility between the writer and reader PDI versions"],"exampleFix":"// before\nfield.setLength( (int) rep.getStepAttributeInteger( id_step, i, \"field_length\" ) ); // throws on corrupt value\n// after\nlong len = rep.getStepAttributeInteger( id_step, i, \"field_length\" );\nfield.setLength( len > 0 ? (int) len : -1 );","handlingStrategy":"try-catch","validationCode":"// sanity check before load\nif ( rep != null && rep.isConnected() ) { transMeta = new TransMeta( rep, metaStore, transName, null ); }","typeGuard":null,"tryCatchPattern":"try {\n  stepMeta.getStepMetaInterface().readRep( rep, metaStore, idStep, databases );\n} catch ( KettleException e ) {\n  logError( \"readRep failed: \" + e.getCause(), e );\n}","preventionTips":["Inspect getCause() to find the failing attribute","Keep repository schemas and PDI versions in sync","Audit r_step_attribute values after manual DB work","Backup repository before migrations"],"tags":["pdi","kettle","repository","metadata-load"],"backgroundTag":"file-read-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"}