Why i can’t use package ? ALways this error: GoError: The moduleSpecifier “uuid-random” couldn’t be retrieved from the resolved url “https://uuid-random”. Error : “Get https://uuid-random: dial tcp: lookup uuid-random on 127.0.0.53:53: server misbehaving”
While k6 scripts do indeed run in a JavaScript virtual machine, they do not run NodeJS, or support the NodeJS node module resolution algorithm. Due to this, using node modules will require some (minor) additional effort in comparison to what you might be used to from writing pure NodeJS applications.
This example from the documentation shows one way to solve it: