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

Can anyone of you please explain me why this error is showing? #6552

Open
rohit-nayak123 opened this issue May 3, 2024 · 0 comments
Open
Labels
type: bug code to address defects in shipped code

Comments

@rohit-nayak123
Copy link

Describe the bug

I am making an api using express js and want to host it on netlify. However suddenly I got the following Error

// Before that this is my following code

import express from "express";
import serverless from "serverless-http";
const app = express();
const router = express.Router();
router.get("/", (req, res) => {
res.send("App is now running..");
});
router.get("/hello", (req, res) => {
res.send("Hello World!");
});
app.use("/.netlify/functions/api", router);

export default serverless(app);

// This is the error

Error: EPERM: operation not permitted, symlink 'D:\github Repo\compressimages\node_modules.pnpm\content-type@1.0.5\node_modules\content-type' -> 'D:\github Repo\compressimages.netlify\functions-serve\api\node_modules.pnpm\express@4.19.2\node_modules\content-type'

System:
OS: Windows 10 10.0.22000
CPU: (12) x64 12th Gen Intel(R) Core(TM) i5-1235U
Binaries:
Node: 20.12.2 - D:\nodejs\node.EXE
npm: 10.3.0 - D:\nodejs\npm.CMD
Browsers:
Chrome: 124.0.6367.119
Edge: Spartan (44.22000.120.0), Chromium (123.0.2420.97)

// Also this is the package.json file

{
"name": "c",
"version": "1.0.0",
"type": "module",
"description": "",
"main": "index.js",
"scripts": {
"build": "netlify deploy --prod",
"dev": "netlify dev"
},
"keywords": [],
"author": "",
"license": "ISC",
"dependencies": {
"@netlify/functions": "^2.6.0",
"express": "^4.19.2",
"hono": "^4.3.0",
"serverless-http": "^3.2.0"
},
"devDependencies": {
"@types/express": "^4.17.21"
}
}

Steps to reproduce

I just did "netlify dev" in the terminal and boom got the error

Configuration

[build]
functions = "functions"

Environment

System:
OS: Windows 11 10.0.22000
CPU: (12) x64 12th Gen Intel(R) Core(TM) i5-1235U
Memory: 1.20 GB / 7.68 GB
Binaries:
Node: 20.12.2 - D:\nodejs\node.EXE
npm: 10.3.0 - D:\nodejs\npm.CMD
pnpm: 9.0.6 - ~\AppData\Local\pnpm\pnpm.CMD

@rohit-nayak123 rohit-nayak123 added the type: bug code to address defects in shipped code label May 3, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type: bug code to address defects in shipped code
Projects
None yet
Development

No branches or pull requests

1 participant