1

I've developed a task in my Hardhat Project but I'm getting some errors when I try to pass an array parameter (something in @ethersproject/strings/src.ts/utf8.ts says that Cannot read properties of undefined (reading 'length'))

So I tried to debug this task with VS Code but I'm not successful so far. Using the following launch.json I've got the error: HardhatError: HH5: HardhatContext is not created.

{
  "version": "0.2.0",
  "configurations": [
    {
      "name": "Debug Task: registerIssuer",
      "type": "node",
      "request": "launch",
      "cwd": "${workspaceRoot}/packages/ntt/",
      "runtimeArgs": ["-r", "ts-node/register"],
      "args": ["${workspaceRoot}/packages/ntt/tasks/registerIssuer.ts"]
    },
  ]
}

1 Answer 1

0

You can try the verbose logging mode of hardhat. This mode will print a series of output that can be useful for debugging:

See: https://hardhat.org/hardhat-runner/docs/troubleshooting/verbose-logging

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.