nrwl / nx

Smart Monorepos · Fast CI
https://nx.dev
MIT License
23.84k stars 2.38k forks source link

[Nest]: Upgrade to NestJS 8 #6671

Closed pacexy closed 2 years ago

pacexy commented 3 years ago

Just used nest application generator and found the version is 7.0.0, please upgrade to 8 (released last month). https://docs.nestjs.com/migration-guide https://trilon.io/blog/announcing-nestjs-8-whats-new

mburger81 commented 3 years ago

Did anyone of you try to upgrade to v8 manually?

Is this something we can do or something which should never be done?

pacexy commented 3 years ago

Did anyone of you try to upgrade to v8 manually?

Is this something we can do or something which should never be done?

If you want to upgrade to v8 from the template generated by nx, just install the latest packages, otherwise(e.g. you have written your own code) please read the migration guide in nestjs official docs.

eliellis commented 3 years ago

Was also wondering the same thing as @mburger81. Is it advisable to update dependencies like NestJS inside of an Nx workspace separate from an update performed automatically by nx migrate latest, or is it best to wait until the version bump is generally available? More "Am I going to break something?" than "Is it possible?" Needless to say, would be great to see this land in Nx soon. 🙂

ArjunAtlast commented 3 years ago

I am also trying to see this since when I try to install extra packages like @nestjs/microservices it is using version 8. So its a bit annoying sometimes when it throws peer dependency issues.

PhilippSeitz commented 3 years ago

v7 also contains a highly vulnerable axios version (https://github.com/nestjs/nest/issues/8048) CVE-2021-3749 which got fixed in v8 https://github.com/nestjs/nest/issues/8153.

philBodycad commented 3 years ago

When I moved to v8 within my Nx repo everything went fine except for the jest tests.

They started to have problems loading the modules when their services were loaded using ts paths, ie :

This loads fine : import { QueryService } from './query.service';

This fails to load : import { QueryService } from '@my-application-services/query.service';

nartc commented 3 years ago

@philBodycad It'd be great if you could open a new issue and provide a sample reproduce

warnellw commented 3 years ago

Looks like a migration will be provided when Nx v13.2 is released. See this PR: https://github.com/nrwl/nx/pull/6284

github-actions[bot] commented 1 year ago

This issue has been closed for more than 30 days. If this issue is still occuring, please open a new issue with more recent context.