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

Running locally doesn't work #69

Open
dividor opened this issue Dec 14, 2024 · 3 comments
Open

Running locally doesn't work #69

dividor opened this issue Dec 14, 2024 · 3 comments

Comments

@dividor
Copy link

dividor commented Dec 14, 2024

I am following the instructions to run locally.

npm install fails ...

npm ERR! code ERESOLVE
npm ERR! ERESOLVE unable to resolve dependency tree
npm ERR! 
npm ERR! While resolving: cognitive-search-static-web-apps-demo@0.1.0
npm ERR! Found: react@17.0.2
npm ERR! node_modules/react
npm ERR!   react@"^17.0.2" from the root project
npm ERR! 
npm ERR! Could not resolve dependency:
npm ERR! peer react@"^16.8.0 || 16.9.0-alpha.0" from mobx-react@6.3.1
npm ERR! node_modules/mobx-react
npm ERR!   mobx-react@"^6.3.1" from the root project
npm ERR! 
npm ERR! Fix the upstream dependency conflict, or retry
npm ERR! this command with --force or --legacy-peer-deps
npm ERR! to accept an incorrect (and potentially broken) dependency resolution.
npm ERR! 
npm ERR! 
npm ERR! For a full report see:
npm ERR! /home/codespace/.npm/_logs/2024-12-14T18_27_50_280Z-eresolve-report.txt

npm ERR! A complete log of this run can be found in: /home/codespace/.npm/_logs/2024-12-14T18_27_50_280Z-debug-0.log

I can install with npm install --legacy-peer-deps, but on starting the app, but running npm run start-with-backend just gives lots and lots of errors. Below is a small excerpt.

../node_modules/@types/express/node_modules/@types/express-serve-static-core/index.d.ts:1193:18 - error TS1005: ';' expected.

1193      * Check if `setting` is disabled.
                      ~~~~~~~

../node_modules/@types/express/node_modules/@types/express-serve-static-core/index.d.ts:1204:17 - error TS1005: ';' expected.

1204     /** Enable `setting`. */
                     ~~~~~~~

../node_modules/@types/express/node_modules/@types/express-serve-static-core/index.d.ts:1207:18 - error TS1005: ';' expected.

1207     /** Disable `setting`. */
                      ~~~~~~~

../node_modules/@types/express/node_modules/@types/express-serve-static-core/index.d.ts:1211:31 - error TS1005: ';' expected.

1211      * Render the given view `name` name with `options`
                                   ~~~~

../node_modules/@types/express/node_modules/@types/express-serve-static-core/index.d.ts:1211:48 - error TS1005: ';' expected.

1211      * Render the given view `name` name with `options`
                                                    ~~~~~~~

../node_modules/@types/express/node_modules/@types/express-serve-static-core/index.d.ts:1227:16 - error TS1005: ';' expected.

1227      * A node `http.Server` is returned, with this
                    ~~~~

../node_modules/@types/express/node_modules/@types/express-serve-static-core/index.d.ts:1228:33 - error TS1005: ';' expected.

1228      * application (which is a `Function`) as its
                                     ~~~~~~~~

../node_modules/@types/express/node_modules/@types/express-serve-static-core/index.d.ts:1296:1 - error TS1160: Unterminated template literal.

I am using versions:

node: v18.20.4
npm: 9.8.1

Though I also tried with node 19 and 20, resetting my env each time.

Is there something I'm doing wrong perhaps?

@scale-tone
Copy link
Owner

@dividor , there should not even be such a folder - ../node_modules/@types/express/node_modules/.. (a node_modules inside another node_modules)- on your drive, and I do not have any ideas on where it might come from.

I suggest you try cloning this repo into some other place, then execute npm install --legacy-peer-deps and npm run build there (in the root folder) and see, if it produces same or different results.

@scale-tone
Copy link
Owner

@dividor , do you still need help on this?

@dividor
Copy link
Author

dividor commented Dec 31, 2024

Sorry for the delay, will try your suggestion next week when back in. Thanks!

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