hospitalrun
hospitalrun copied to clipboard
Error while building the project
✓ Creating entry file 8.6 secs
(typescript) Error: D:/anaym/projects/node/f/hospitalrun/packages/components/src/components/Layout/Container.tsx(33,25): semantic error TS2769: No overload matches this call.
Overload 1 of 2, '(props: Readonly<ReplaceProps<"symbol", BsPrefixProps<"symbol"> & ContainerProps>>): Container<"symbol">', gave the following error.
Type '"symbol" | "object" | "a" | "abbr" | "address" | "area" | "article" | "aside" | "audio" | "b" | "base" | "bdi" | "bdo" | "big" | "blockquote" | "body" | "br" | "button" | "canvas" | ... 158 more ... | undefined' is not assignable to type '"symbol" | undefined'.
Type '"object"' is not assignable to type '"symbol" | undefined'.
Overload 2 of 2, '(props: ReplaceProps<"symbol", BsPrefixProps<"symbol"> & ContainerProps>, context?: any): Container<"symbol">', gave the following error.
Type '"symbol" | "object" | "a" | "abbr" | "address" | "area" | "article" | "aside" | "audio" | "b" | "base" | "bdi" | "bdo" | "big" | "blockquote" | "body" | "br" | "button" | "canvas" | ... 158 more ... | undefined' is not assignable to type '"symbol" | undefined'.
Type '"object"' is not assignable to type '"symbol" | undefined'.
Error: D:/anaym/projects/node/f/hospitalrun/packages/components/src/components/Layout/Container.tsx(33,25): semantic error TS2769: No overload matches this call.
Overload 1 of 2, '(props: Readonly<ReplaceProps<"symbol", BsPrefixProps<"symbol"> & ContainerProps>>): Container<"symbol">', gave the following error.
Type '"symbol" | "object" | "a" | "abbr" | "address" | "area" | "article" | "aside" | "audio" | "b" | "base" | "bdi" | "bdo" | "big" | "blockquote" | "body" | "br" | "button" | "canvas" | ... 158 more ... | undefined' is not assignable to type '"symbol" | undefined'.
Type '"object"' is not assignable to type '"symbol" | undefined'.
Overload 2 of 2, '(props: ReplaceProps<"symbol", BsPrefixProps<"symbol"> & ContainerProps>, context?: any): Container<"symbol">', gave the following error.
Type '"symbol" | "object" | "a" | "abbr" | "address" | "area" | "article" | "aside" | "audio" | "b" | "base" | "bdi" | "bdo" | "big" | "blockquote" | "body" | "br" | "button" | "canvas" | ... 158 more ... | undefined' is not assignable to type '"symbol" | undefined'.
Type '"object"' is not assignable to type '"symbol" | undefined'.
at error (D:\anaym\projects\node\f\hospitalrun\packages\components\node_modules\rollup\dist\shared\node-entry.js:5400:30)
at throwPluginError (D:\anaym\projects\node\f\hospitalrun\packages\components\node_modules\rollup\dist\shared\node-entry.js:11878:12)
at Object.error (D:\anaym\projects\node\f\hospitalrun\packages\components\node_modules\rollup\dist\shared\node-entry.js:12912:24)
at Object.error (D:\anaym\projects\node\f\hospitalrun\packages\components\node_modules\rollup\dist\shared\node-entry.js:12081:38)
at RollupContext.error (D:\anaym\projects\node\f\hospitalrun\packages\components\node_modules\tsdx\node_modules\rollup-plugin-typescript2\dist\rollup-plugin-typescript2.cjs.js:17194:30)
at D:\anaym\projects\node\f\hospitalrun\packages\components\node_modules\tsdx\node_modules\rollup-plugin-typescript2\dist\rollup-plugin-typescript2.cjs.js:24994:23
at arrayEach (D:\anaym\projects\node\f\hospitalrun\packages\components\node_modules\tsdx\node_modules\rollup-plugin-typescript2\dist\rollup-plugin-typescript2.cjs.js:534:11)
at forEach (D:\anaym\projects\node\f\hospitalrun\packages\components\node_modules\tsdx\node_modules\rollup-plugin-typescript2\dist\rollup-plugin-typescript2.cjs.js:9360:14)
at printDiagnostics (D:\anaym\projects\node\f\hospitalrun\packages\components\node_modules\tsdx\node_modules\rollup-plugin-typescript2\dist\rollup-plugin-typescript2.cjs.js:24967:5)
at Object.transform (D:\anaym\projects\node\f\hospitalrun\packages\components\node_modules\tsdx\node_modules\rollup-plugin-typescript2\dist\rollup-plugin-typescript2.cjs.js:29049:17)
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! @hospitalrun/[email protected] build: `tsdx build`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the @hospitalrun/[email protected] build script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\anaym\AppData\Roaming\npm-cache\_logs\2020-05-30T16_06_01_227Z-debug.log
Your Environment
- node version: 12
- os: Windows
@anaymalpani could you please provide steps to reproduce?
@anaymalpani do you use Windows or have you built with yarn?
I am facing the same issue- how did you fix this problem?
I have node v14.4.0, MacOS, yarn v1.19.1:
I completed the steps:
git clone [email protected]:HospitalRun/hospitalrun.git cd hospitalrun git submodule update --init --recursive yarn yarn workspaces run build (And received this error during run build)
This is a yarn workspace issue when using a monorepo. It's an issue of low priority because all separate submodules build correctly. The team is informed of this issue but needs time to solve it. Any contributions are welcome.
Could you clarify how to build all of the submodules to get the application to run? @tehKapa
Hi! I am going to to look into this ASAP and hopefully fix the problem definitely! @reidmeyer you are right: we miss the documentation that explains how to use all the modules without mono repo. Let’s try to understand what are the main steps that are needed to use all modules in a stand alone way.
Glad to hear @fox1t.
My guess would be to run "yarn run build" inside each package itself, but I think that is the same thing as running yarn workspaces run build. When I do this, I get errors with components and frontend.
That documentation would be super helpful.
@reidmeyer for documentation on how to contribute to the individual modules: https://github.com/HospitalRun/hospitalrun/blob/master/.github/CONTRIBUTING.md
Hi! I've looked into this. The real problem is TypeScript version > 3.9.x that changed how union types work. Our dependency is listed like "typescript": "~3.8.2"
so it wouldn't be updated to a newer minor that brakes. Do you have TS globally installed?
@fox1t I don't think I have it installed globally, as tsc isn't recognized. Although it could have been installed by visual studio. I do have a C:\Program Files (x86)\Microsoft SDKs\TypeScript\versions\03.08.03.00, but you say it only breaks at 3.9.x. This is using yarn so it might be the monorepo bugs still.
Could be a hoisting problem! Ok, lets see if my last commits fixes it! Thanks again.
Just updating you: with the current commits, I'm getting the same errors as before.
I see you're working on it though, and I didn't run the MOST recent commit, so I will test again later!
NPM14 throws me errors on "yarn" command:
NPM12 gets passed the yarn command, but then on workspaces build it similarly fails with the overload:
I am facing the same issue. Did someone get it working? How to fix this?
We are looking into a new solution for the management of the monorepo... we don't have an ETA
i'm still getting this error , anyone solved it ?
Unfortunately, yes. It is not easy to find a tool for the management of this complicated software
so how can I R run this project on my local machine ? i've tried what's available but nothing works
You have to run hospitalrun-server and hospitalrun-frontend separately