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

Bump @types/node from 13.13.52 to 18.7.10 #2119

Merged
merged 4 commits into from
Aug 23, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@
"@types/jest": "^27.0.2",
"@types/json-schema": "^7.0.9",
"@types/lodash": "^4.14.175",
"@types/node": "^13.1.1",
"@types/node": "^18.7.10",
"@types/node-fetch": "2.5.10",
"@types/pino": "6.3.8",
"@types/postman-collection": "^3.5.7",
Expand Down
4 changes: 2 additions & 2 deletions packages/cli/src/util/createServer.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import { createLogger } from '@stoplight/prism-core';
import { IHttpConfig, IHttpRequest } from '@stoplight/prism-http';
import { createServer as createHttpServer } from '@stoplight/prism-http-server';
import * as chalk from 'chalk';
import * as cluster from 'cluster';
import cluster from 'node:cluster';
import * as E from 'fp-ts/Either';
import { pipe } from 'fp-ts/function';
import { LogDescriptor, Logger, LoggerOptions } from 'pino';
Expand Down Expand Up @@ -46,7 +46,7 @@ const createMultiProcessPrism: CreatePrism = async options => {

return createPrismServerWithLogger(options, logInstance).catch((e: Error) => {
logInstance.fatal(e.message);
cluster.worker.kill();
cluster.worker?.kill();
throw e;
});
}
Expand Down
6 changes: 4 additions & 2 deletions packages/http/src/__tests__/memory-leak-prevention.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -33,12 +33,14 @@ describe('Checks if memory leaks', () => {

for (let i = 0; i < 5000; i++) {
round(client);
if (i % 100 === 0) {
if (i % 100 === 0 && global.gc) {
global.gc();
}
}

global.gc();
if (global.gc) {
global.gc();
}
expect(process.memoryUsage().heapUsed).toBeLessThanOrEqual(baseMemoryUsage * 1.03);
});
});
8 changes: 4 additions & 4 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -2246,10 +2246,10 @@
"@types/node" "*"
form-data "^3.0.0"

"@types/node@*", "@types/node@^13.1.1":
version "13.13.52"
resolved "https://registry.yarnpkg.com/@types/node/-/node-13.13.52.tgz#03c13be70b9031baaed79481c0c0cfb0045e53f7"
integrity sha512-s3nugnZumCC//n4moGGe6tkNMyYEdaDBitVjwPxXmR5lnMG5dHePinH2EdxkG3Rh1ghFHHixAG4NJhpJW1rthQ==
"@types/node@*", "@types/node@^18.7.10":
version "18.7.10"
resolved "https://registry.yarnpkg.com/@types/node/-/node-18.7.10.tgz#f642dc9ded1bdd8c2cd847246466e71182b0fd67"
integrity sha512-SST7B//wF7xlGoLo1IEVB0cQ4e7BgXlDk5IaPgb5s0DlYLjb4if07h8+0zbQIvahfPNXs6e7zyT0EH1MqaS+5g==

"@types/normalize-package-data@^2.4.0":
version "2.4.1"
Expand Down