Skip to content

[Bug Report] Module not found error #1471

@granpacho

Description

@granpacho

Describe the bug

This is my first time starting this bot so I am not sure if I did something wrong, however I am receiving an Module not found error of index.js when starting the bot

To Reproduce

I put the release into the server, did the npm install commands and start the bot

Expected behavior

I expected the server to turn on

Screenshots

Image

Operating System

Pterodactyl Server

Additional context

Error as text:

`> [email protected] start /home/container

node --es-module-specifier-resolution=node -r dotenv/config .
(node:47) ExperimentalWarning: The Node.js specifier resolution flag is experimental. It could change or be removed at any time.
(Use node --trace-warnings ... to show where the warning was created)
[INFO] Starting the bot...
node:internal/errors:496
ErrorCaptureStackTrace(err);
^
Error [ERR_MODULE_NOT_FOUND]: Cannot find module '/home/container/dist/index.js' imported from /home/container/index.js
at new NodeError (node:internal/errors:405:5)
at finalizeResolution (node:internal/modules/esm/resolve:306:15)
at moduleResolve (node:internal/modules/esm/resolve:980:10)
at defaultResolve (node:internal/modules/esm/resolve:1206:11)
at ModuleLoader.defaultResolve (node:internal/modules/esm/loader:404:12)
at ModuleLoader.resolve (node:internal/modules/esm/loader:373:25)
at ModuleLoader.getModuleJob (node:internal/modules/esm/loader:250:38)
at ModuleLoader.import (node:internal/modules/esm/loader:336:34)
at importModuleDynamically (node:internal/modules/esm/translators:143:35)
at importModuleDynamicallyCallback (node:internal/modules/esm/utils:176:14) {
url: 'module',
code: 'ERR_MODULE_NOT_FOUND'
}
Node.js v18.20.8
 ELIFECYCLE  Command failed with exit code 1.`

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions