Js Driver Error on CALL apoc - Neo4jError: The transaction has been closed

Hello,

When running the following code using a JS driver I get an exception Neo4JError: The transaction has been closed.

await session.run(CALL apoc.cypher.runFile('import.cypher'));

The import.cypher contains

CREATE(n:Persona {code: 'person_1', name: 'Alexander Kirilov'})
RETURN n;

Please advise

There's not enough information to help out here.

Please post the full error message with stacktrace. Also, I think usually when you use runFile you need to specify some config to tell your system where to find the file, and this could be going wrong. Paste the appropriate neo4j config for cypher that you put, and try running the query in the browser too. I suspect that the file is not being found or something similar to this