Skip to content

pdfjs-dist crashing the plugin #37

@znahas

Description

@znahas

Error:

Warning: Cannot access the require function: "TypeError: process.getBuiltinModule is not a function. (In 'process.getBuiltinModule("module")', 'process.getBuiltinModule' is undefined)".
Warning: Cannot polyfill DOMMatrix, rendering may be broken.
Warning: Cannot polyfill ImageData, rendering may be broken.
Warning: Cannot polyfill Path2D, rendering may be broken.
message: "(ReferenceError) Can't find variable: DOMMatrix"
stack: [
"ReferenceError: Can't find variable: DOMMatrix",
"at /home/ziad/git/AItools/eliza_test_project/node_modules/@elizaos/plugin-knowledge/node_modules/pdfjs-dist/legacy/build/pdf.mjs:13750:26",
"at moduleEvaluation (native)",
"at moduleEvaluation (native)",
"at (native:2)",
"at processTicksAndRejections (native:7:39)"
]

Steps to reproduce:

load some memories using the plugin-knowledge (load some RAG files)
then you clear the memories using "elizaos agent clear-memories --name {youragent}"
then you run the project again using like "elizaos dev"
the error will appear and the plugin-knowledge would never work!

Version:

"@elizaos/cli": "^1.3.2",
"@elizaos/core": "^1.3.2",
"@elizaos/plugin-bootstrap": "^1.3.2",
"@elizaos/plugin-knowledge": "^1.2.1",

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions