pentaho/pentaho-kettle · error · KettleXMLException
Unable to read Notepad info from XML
Error message
Unable to read Notepad info from XML
What it means
The NotePadMeta(Node) constructor parses the <notepad> XML node of a transformation/job file; any exception while reading its tag values (bounds, colors, fonts, shadow flag) is wrapped as KettleXMLException 'Unable to read Notepad info from XML'. It indicates a malformed or incomplete note element in the .ktr/.kjb file.
Solutions
- Open the file, locate the <notepad> element, and fix/remove the malformed attributes; the chained cause (getCause()) names the exact problem.
- If the note is dispensable, delete the whole <notepad> node from the XML and reopen the file.
- Re-save the transformation/job from Spoon to regenerate valid XML.
- Restore the file from version control or backup.
Example fix
// before <notepad> <xlocation>abc</xlocation> </notepad> // after <notepad> <xlocation>100</xlocation> <ylocation>100</ylocation> <width>200</width> <height>50</height> <fontname>Arial</fontname> </notepad>
Defensive patterns
Strategy: try-catch
Validate before calling
Node np = XMLHandler.getSubNode(transNode, "notepad");
if (np != null && Const.toInt(XMLHandler.getTagValue(np, "xlocation"), -1) < 0) {
throw new KettleXMLException("Invalid <notepad> block");
} Try / catch
try { NotePadMeta n = new NotePadMeta(notepadNode); } catch (KettleXMLException e) { logError("Skipping corrupt note: " + e.getCause(), e); } Prevention
- Do not hand-edit .ktr/.kjb note XML; edit in Spoon
- Validate kettle files with XML schema before loading programmatically
- Restore from VCS when a merge corrupts metadata
When it happens
Trigger: Constructing NotePadMeta from an XML node whose child tags (xlocation, ylocation, width, height, fontname, borderscolor, etc.) are missing, non-numeric, or the node itself is null.
Common situations: Hand-edited or externally generated .ktr/.kjb files with damaged <notepad> blocks; older file versions lacking newer attributes combined with stricter parsing; corrupted files from failed VCS merges or truncation.
Understand the failure class
Background: "failed to read file", EACCES, ENOENT and "could not read <path>" errors: when a program can't read a file from disk — this error's family across 49 libraries.
Related errors
- Error loading transformation step from XML
- Error loading transformation step from XML
- FieldSplitterMeta.Exception.UnableToLoadStepInfoFromXML
- FileExistsMeta.Exception.UnableToReadStepInfo
- FuzzyMatchMeta.Exception.UnableToLoadStepInfoFromXML
AI-assisted analysis of pentaho/pentaho-kettle@f3058517a1 (2026-09-13).
Data as JSON: /api/errors/9a6896edad198478.
Report an issue: GitHub.
Appendix: source
Thrown at engine/src/main/java/org/pentaho/di/core/NotePadMeta.java:165
this.fontcolorblue =
Const.toInt( XMLHandler.getTagValue( notepadnode, "fontcolorblue" ), COLOR_RGB_BLACK_BLUE );
// background color
this.backgroundcolorred =
Const.toInt( XMLHandler.getTagValue( notepadnode, "backgroundcolorred" ), COLOR_RGB_DEFAULT_BG_RED );
this.backgroundcolorgreen =
Const.toInt( XMLHandler.getTagValue( notepadnode, "backgroundcolorgreen" ), COLOR_RGB_DEFAULT_BG_GREEN );
this.backgroundcolorblue =
Const.toInt( XMLHandler.getTagValue( notepadnode, "backgroundcolorblue" ), COLOR_RGB_DEFAULT_BG_BLUE );
// border color
this.bordercolorred =
Const.toInt( XMLHandler.getTagValue( notepadnode, "bordercolorred" ), COLOR_RGB_DEFAULT_BORDER_RED );
this.bordercolorgreen =
Const.toInt( XMLHandler.getTagValue( notepadnode, "bordercolorgreen" ), COLOR_RGB_DEFAULT_BORDER_GREEN );
this.bordercolorblue =
Const.toInt( XMLHandler.getTagValue( notepadnode, "bordercolorblue" ), COLOR_RGB_DEFAULT_BORDER_BLUE );
this.drawshadow = "Y".equalsIgnoreCase( XMLHandler.getTagValue( notepadnode, "drawshadow" ) );
} catch ( Exception e ) {
throw new KettleXMLException( "Unable to read Notepad info from XML", e );
}
}
public ObjectId getObjectId() {
return id;
}
public void setObjectId( ObjectId id ) {
this.id = id;
}
public void setLocation( int x, int y ) {
if ( x != location.x || y != location.y ) {
setChanged();
}
location.x = x;
location.y = y;
}View on GitHub (pinned to f3058517a1)