[BUG] Modifying packages and building the application results in the build using dependencies from npm
instead of from within the monorepo.
#1732
Labels
npm
instead of from within the monorepo.
#1732
Describe the bug
When I created my fork to add some new tools and extensions, I ran into issues with the build process not picking up my changes. This turned out to be because e.g.
flowise-components
has been published to npm and/or becauseyarn
v1 is rather limited when it comes to controlling resolution of dependencies within a monorepo. The server's dependency is just"flowise-components": "*"
, and since this package exists in the npm registry, it would pull that package instead of the local version from inside the monorepo. To avoid this, I had to useyarn link
, and also add this as an additional step to the dockerfile to ensure it used my modifiedflowise-components
package.To Reproduce
flowise-components
flowise-components
are not in your build.Expected behavior
I expect the monorepo to depend on the packages within the monorepo instead of the versions in npm.
I personally don't think there is any particularly compelling reason for
flowise-components
to be published to npm, but I can see why one might want to do it, and either way, it is already done.Potential solutions
Transition to yarn berry or pnpm(which would be my choice), where you can use
workspace:
protocol in your package.json to ensure that the packages within the monorepo depend on each other instead of the ones published to npm.If you are interested, I'd be willing to try making a pull request to transition to pnpm.
The text was updated successfully, but these errors were encountered: