facebook / memlab

A framework for finding JavaScript memory leaks and analyzing heap snapshots
https://facebook.github.io/memlab/
MIT License
4.3k stars 116 forks source link

Keep `@memlab/*` versions in lockstep in package.json #113

Closed jeswr closed 5 months ago

jeswr commented 5 months ago

I've recently encountered the error core_1.browserInfo.recordPuppeteerConfig is not a function. This is similar to https://github.com/facebook/memlab/issues/109; and it was encountered in an automated dependabot update (https://github.com/eyereasoner/eye-js/pull/831).

Indeed running npm upgrade to bump the version of @memlab/core fixes the issue; but really I would expect that if @memlab/api uses APIs introduced in v1.1.27 of @memlab/core then @memlab/api should depend on at minimum ^1.1.27 of @memlab/core in the package.json as opposed to v1.1.10 which it is currently set at https://github.com/facebook/memlab/blob/bb1a3b6b8d54e127fab1ede768adbd9078d35633/packages/api/package.json#L30-L32 as this would then ensure that tooling like npm and dependabot will upgrade such dependencies in downstream lockfiles when trying to upgrade the version of @memlab/api.

Monorepo tooling such as lerna has native support for this kind of lockstep versioning.

JacksonGL commented 5 months ago

Thank you for reporting this issue. I have updated the minimum version of dependency and published the latest version (memlab@1.1.45).