Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

404 Error with NPM #112

Open
thrace19 opened this issue Feb 10, 2021 · 4 comments
Open

404 Error with NPM #112

thrace19 opened this issue Feb 10, 2021 · 4 comments

Comments

@thrace19
Copy link

thrace19 commented Feb 10, 2021

--> npm install @json/presences @utils/cleanup @utils/utils @utils/responses @utils/schema node-fetch
npm ERR! code E404
npm ERR! 404 Not Found - GET https://registry.npmjs.org/@utils%2fcleanup - Not found
npm ERR! 404 
npm ERR! 404  '@utils/cleanup@latest' is not in the npm registry.
npm ERR! 404 You should bug the author to publish it (or use the name yourself!)
npm ERR! 404 
npm ERR! 404 Note that you can also install from a
npm ERR! 404 tarball, folder, http url, or git url.

npm ERR! A complete log of this run can be found in:
npm ERR!     /home/runner/.npm/_logs/2021-02-10T14_04_48_604Z-debug.log
exit status 1

Package.json

  "_moduleAliases": {
    "@utils": "src/utils",
    "@structures": "src/structures",
    "@json": "assets/json",
    "@languages": "src/languages"
  }

I also tried in my index file

const moduleAlias = require("module-alias");

moduleAlias.addAliases({
  "@utils":   __dirname + "/src/utils",
  "@structures": __dirname + "/src/structures",
  "@json":  __dirname + "/assets/json",
  "@languages": __dirname + "/src/languages"
});
@Kehrlann
Copy link
Collaborator

Kehrlann commented Feb 10, 2021

Hi 👋 I'm not sure I understand that npm install... Why is it trying to install from your sources? If I understand correctly, these files are local to your project, they don't need to be npm install'ed. node-fetch makes sense but the rest, I'm not sure.

Could you please share the full package.json ?

@thrace19
Copy link
Author

{
  "name": "princess",
  "version": "2.0.1",
  "description": "lel",
  "main": "index.js",
  "scripts": {
    "test": "echo \"Error: no test specified\" && exit 1"
  },
  "author": "inhydrox",
  "license": "Apache 2.0",
  "dependencies": {
    "@top-gg/sdk": "^3.0.7",
    "axios": "^0.21.1",
    "canvas": "^2.6.1",
    "canvas-constructor": "^4.1.0",
    "cheerio": "^1.0.0-rc.3",
    "dblapi.js": "^2.4.0",
    "discord.js": "^12.2.0",
    "dotenv": "^8.2.0",
    "fast-levenshtein": "^2.0.6",
    "image-size": "^0.9.1",
    "img-api": "^1.0.4",
    "module-alias": "^2.2.2",
    "moment": "^2.28.0",
    "moment-timezone": "^0.5.31",
    "mongodb": "^3.6.0",
    "ms": "^2.1.2"
  },
  "_moduleAliases": {
    "@utils": "src/utils",
    "@structures": "src/structures",
    "@json": "assets/json",
    "@languages": "src/languages"
  }
}

@Kehrlann
Copy link
Collaborator

This is surprising to me. Where does this npm install @json/presences @utils/cleanup @utils/utils @utils/responses @utils/schema node-fetch come from ? You don't have node-fetch in your dependencies, or any of the @utils etc.

Is this happening locally ? Which command are you running when this happens ?

@thrace19
Copy link
Author

It's only happening on repl.it it's working fine locally

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants