BabylonJS/Babylon.js · error · Error

Invalid FBX property list length for node '${name}' at offse

Error message

Invalid FBX property list length for node '${name}' at offset ${offset}

What it means

After the node header and name, the property list spans propertyListLen bytes; the parser computes propertiesEnd = propertiesStart + propertyListLen and requires it not to exceed the node's endOffset. If the declared property list length overruns the node record, the header fields are inconsistent and the file is malformed.

Source

Thrown at packages/dev/loaders/src/FBX/parsers/fbxBinaryParser.ts:86

    }

    // Null sentinel: all header fields are zero
    if (endOffset === 0) {
        return null;
    }
    if (endOffset <= offset || endOffset > limit) {
        throw new Error(`Invalid FBX node end offset ${endOffset} at offset ${offset}`);
    }

    const nameLen = bytes[offset + headerSize - 1];
    ensureRange(bytes, offset + headerSize, nameLen, endOffset, "FBX node name");
    const name = decodeASCII(bytes, offset + headerSize, nameLen);

    let cursor = offset + headerSize + nameLen;
    const propertiesStart = cursor;
    const propertiesEnd = propertiesStart + propertyListLen;
    if (propertiesEnd > endOffset) {
        throw new Error(`Invalid FBX property list length for node '${name}' at offset ${offset}`);
    }

    // Parse properties
    const properties: FBXProperty[] = [];
    for (let i = 0; i < numProperties; i++) {
        const result = parseProperty(view, bytes, cursor, propertiesEnd);
        properties.push(result.property);
        cursor = result.nextOffset;
    }
    if (cursor !== propertiesEnd) {
        throw new Error(`Invalid FBX property list length for node '${name}' at offset ${offset}`);
    }

    // Parse nested child nodes (between end of properties and endOffset)
    const children: FBXNode[] = [];
    if (cursor < endOffset) {
        while (cursor < endOffset) {
            const child = parseNode(view, bytes, cursor, is64Bit, endOffset);

View on GitHub (pinned to 0592b347b8)

Solutions

  1. Re-download or re-export the FBX — the length field is inconsistent with the record size
  2. Verify header layout: confirm version ≥7500 correctly switches to 64-bit endOffset/offset fields
  3. Hexdump the node record at the reported offset and compare field values against the FBX binary spec
  4. Reject the file up front with a checksum/size sanity check before parsing
Defensive patterns

Strategy: try-catch

Validate before calling

// sanity check a few top-level node records before full parse
const view = new DataView(buffer);
let off = 27;
const end = buffer.byteLength;
while (off < end) {
  const endOffset = view.getUint32(off, true); // 32-bit layout
  if (endOffset === 0) break;
  if (endOffset <= off || endOffset > end) throw new Error("Corrupt top-level FBX record");
  off = endOffset;
}

Try / catch

try {
  const doc = parseBinaryFBX(buffer);
} catch (e) {
  if (/Invalid FBX property list length/.test(e.message)) {
    console.error("Node property list overruns its record — corrupt or non-conformant FBX; re-export");
  } else throw e;
}

Prevention

When it happens

Trigger: parseNode (via `result`/`child`) reading a node whose propertyListLen field pushes propertiesEnd past endOffset — corrupt length field, wrong header layout (32/64-bit mismatch), or garbage interpreted as a length.

Common situations: Corrupted or truncated downloads; exporters writing 64-bit headers with 32-bit lengths or vice versa; hand-crafted/fuzzed FBX files used as fixtures.

Related errors


AI-assisted analysis of BabylonJS/Babylon.js@0592b347b8 (2026-08-30). Data as JSON: /api/errors/e525098fd4bbc733. Report an issue: GitHub.