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

Error: Netlify CLI has terminated unexpectedly #6773

Open
farhanmatics opened this issue Aug 1, 2024 · 0 comments
Open

Error: Netlify CLI has terminated unexpectedly #6773

farhanmatics opened this issue Aug 1, 2024 · 0 comments
Labels
type: bug code to address defects in shipped code

Comments

@farhanmatics
Copy link

Describe the bug

while submitting a form through netlify API I get this error:

» Error: Netlify CLI has terminated unexpectedly
This is a problem with the Netlify CLI, not with your application.
If you recently updated the CLI, consider reverting to an older version by running:

npm install -g netlify-cli@VERSION

You can use any version from https://ntl.fyi/cli-versions.

Please report this problem at https://ntl.fyi/cli-error including the error details below.

Error: Positional replacement (?) 0 has no entry in the replacement map (replacements[0] is undefined).
at injectReplacements (E:\devnew\tourista-netlify-api\node_modules\sequelize\lib\utils\sql.js:151:15)
at Sequelize.query (E:\devnew\tourista-netlify-api\node_modules\sequelize\lib\sequelize.js:286:13)
at module.exports.submit_form_post (E:\devnew\tourista-netlify-api\controllers\apiController.js:49:35)
at Layer.handle [as handle_request] (E:\devnew\tourista-netlify-api\node_modules\express\lib\router\layer.js:95:5)
at next (E:\devnew\tourista-netlify-api\node_modules\express\lib\router\route.js:149:13)
at Route.dispatch (E:\devnew\tourista-netlify-api\node_modules\express\lib\router\route.js:119:3)
at Layer.handle [as handle_request] (E:\devnew\tourista-netlify-api\node_modules\express\lib\router\layer.js:95:5)
at E:\devnew\tourista-netlify-api\node_modules\express\lib\router\index.js:284:15
at Function.process_params (E:\devnew\tourista-netlify-api\node_modules\express\lib\router\index.js:346:12)
at next (E:\devnew\tourista-netlify-api\node_modules\express\lib\router\index.js:280:10)

System:
OS: Windows 10 10.0.19045
CPU: (8) x64 Intel(R) Core(TM) i7-8650U CPU @ 1.90GHz
Binaries:
Node: 21.1.0 - C:\Program Files\nodejs\node.EXE
Yarn: 1.22.22 - C:\Program Files\nodejs\yarn.CMD
npm: 10.8.1 - C:\Program Files\nodejs\npm.CMD
Browsers:
Edge: Chromium (127.0.2651.74)

Steps to reproduce

this is a basic express app with a post api that has the following values:
{"fullname":"Md Farhan Asif","mobile":"07472881031","email":"[email protected]","country":235,"profession":"7","comment":"hi","visatype":"Tourist Visa","helptype":"Visa Assistance"}

the db connection is remote and used mysql2 and sequelize

Configuration

[build]
functions = "netlify/functions"

[functions]

If you need to include specific external modules

external_node_modules = [
"express",
"serverless-http",
"mysql2",
"dotenv",
"nodemailer",
"sequelize",
"body-parser",
"cookie-parser",
"cors",
"csurf"
]

Environment

System:
OS: Windows 10 10.0.19045
CPU: (8) x64 Intel(R) Core(TM) i7-8650U CPU @ 1.90GHz
Memory: 4.45 GB / 15.56 GB
Binaries:
Node: 21.1.0 - C:\Program Files\nodejs\node.EXE
Yarn: 1.22.22 - C:\Program Files\nodejs\yarn.CMD
npm: 10.8.1 - C:\Program Files\nodejs\npm.CMD

@farhanmatics farhanmatics added the type: bug code to address defects in shipped code label Aug 1, 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