diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 123222c0d..ff47d3271 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -17,7 +17,7 @@ jobs: runs-on: ubuntu-latest strategy: matrix: - node-version: [14.x, 16.x, 18.x, 20.x, 22.x] + node-version: [16.x, 18.x, 20.x, 22.x] steps: - uses: actions/checkout@v4 if: github.event.inputs.git-ref == '' @@ -52,7 +52,7 @@ jobs: env: CI: true - name: Send codecov.io stats - if: matrix.node-version == '14.x' + if: matrix.node-version == '16.x' uses: codecov/codecov-action@v4 with: token: ${{ secrets.CODECOV_TOKEN }} @@ -63,10 +63,10 @@ jobs: runs-on: ubuntu-latest steps: - uses: actions/checkout@v4 - - name: Use Node.js 18 + - name: Use Node.js 20 uses: actions/setup-node@v4 with: - node-version: 18.x + node-version: 20.x - name: Install node_modules run: yarn install - name: Build diff --git a/CHANGELOG.md b/CHANGELOG.md index 520a95e55..9b9cbbc33 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,105 @@ +## [10.0.0-beta.5](https://github.com/typegoose/mongodb-memory-server/compare/v10.0.0-beta.4...v10.0.0-beta.5) (2024-07-18) + + +### ⚠ BREAKING CHANGES + +* **resolveConfig:** Default binary version is now "7.0.11" + +### Features + +* **resolveConfig:** update default binary version to 7.x ([9d569ac](https://github.com/typegoose/mongodb-memory-server/commit/9d569ac63e7f6bd729e0d98254226f4ed18acb0a)) + +## [10.0.0-beta.4](https://github.com/typegoose/mongodb-memory-server/compare/v10.0.0-beta.3...v10.0.0-beta.4) (2024-07-18) + + +### Features + +* **index:** also top-level export "DryMongoBinary" and all errors ([d11abaa](https://github.com/typegoose/mongodb-memory-server/commit/d11abaaa9e7207756bd6d599b2455e7d5761f638)) + + +### Dependencies + +* **semver:** upgrade to version 7.6.3 ([100e571](https://github.com/typegoose/mongodb-memory-server/commit/100e57100c1c334c29a38ab8efaed0f7942e3235)) + + +### Dev-Dependencies + +* **eslint-plugin-prettier:** upgrade to version 5.2.1 ([15990b9](https://github.com/typegoose/mongodb-memory-server/commit/15990b97549a6a8632bab303d4a10204d91d90fe)) + +## [10.0.0-beta.3](https://github.com/typegoose/mongodb-memory-server/compare/v10.0.0-beta.2...v10.0.0-beta.3) (2024-07-15) + + +### Features + +* **MongoMemoryServer:** allow setting if port generation is enabeld or not ([6c4daed](https://github.com/typegoose/mongodb-memory-server/commit/6c4daedf82ab86920037c5bb1dd2a15ba4031bbe)), closes [#816](https://github.com/typegoose/mongodb-memory-server/issues/816) + + +### Style + +* **MongoMemoryReplSet:** fix lint ([bd8941b](https://github.com/typegoose/mongodb-memory-server/commit/bd8941b331eec9f4317ef8456142db69917528a3)) + + +### Dependencies + +* **https-proxy-agent:** upgrade to version 7.0.5 ([4d5be4d](https://github.com/typegoose/mongodb-memory-server/commit/4d5be4d5aa8330ab73dff8d0c1f5d0090b20e39b)) + + +### Dev-Dependencies + +* **prettier:** upgrade to version 3.3.3 ([5aba25a](https://github.com/typegoose/mongodb-memory-server/commit/5aba25a865f08184b1db1f433c35f35242d91b55)) +* **rimraf:** upgrade to version 5.0.9 ([a6d706a](https://github.com/typegoose/mongodb-memory-server/commit/a6d706a75ab9560beb8c8053ddb7fabf42c453ca)) +* **ts-jest:** upgrade to version 29.2.2 ([839e432](https://github.com/typegoose/mongodb-memory-server/commit/839e432c19d878cc4260114604274a439d0be626)) + +## [10.0.0-beta.2](https://github.com/typegoose/mongodb-memory-server/compare/v10.0.0-beta.1...v10.0.0-beta.2) (2024-07-13) + + +### Fixes + +* **MongoBinaryDownloadUrl:** add mapping for Linux Mint 22 ([2ffc024](https://github.com/typegoose/mongodb-memory-server/commit/2ffc024ab6608d2f2d7da230f5ddf7dc4bbf4065)) +* trigger release ([8c48020](https://github.com/typegoose/mongodb-memory-server/commit/8c48020816fe19fbcc4f886fcfb96302eaff8714)) + +## [10.0.0-beta.1](https://github.com/nodkz/mongodb-memory-server/compare/v9.4.0...v10.0.0-beta.1) (2024-06-24) + + +### ⚠ BREAKING CHANGES + +* **resolveConfig:** Default binary version is now "7.0.9" +* **tsconfig:** potentially breaking change upgrading "target" to "es2021" in tsconfig +* Lowest supported NodeJS version is now 16.20.1 + +* **tsconfig:** update "target" to "es2021" ([abde8ca](https://github.com/nodkz/mongodb-memory-server/commit/abde8ca2ff2ebc077666d496520b3ce0f684ef99)) + + +### Features + +* add support for "Explicit Resource Management" ([ab7a73c](https://github.com/nodkz/mongodb-memory-server/commit/ab7a73c14fa80e51ec407d08b120b4ae6ee77ece)), closes [#794](https://github.com/nodkz/mongodb-memory-server/issues/794) +* **getport:** use net0listen by default ([887f1a1](https://github.com/nodkz/mongodb-memory-server/commit/887f1a1e932a8993ef3fd69cf1f65b700c89a77b)), closes [#827](https://github.com/nodkz/mongodb-memory-server/issues/827) +* **resolveConfig:** update default binary version to 7.x ([2436d63](https://github.com/nodkz/mongodb-memory-server/commit/2436d6300bd863efa3300103a3223d3849d0bda3)) +* set lowest supported nodejs version to 16.20.1 ([30b302e](https://github.com/nodkz/mongodb-memory-server/commit/30b302e5518c3df92c4b229035b2b229639dfb3c)), closes [#805](https://github.com/nodkz/mongodb-memory-server/issues/805) + + +### Fixes + +* **MongoBinaryDownloadUrl:** change default elementary version to 7 ([ecc4ffe](https://github.com/nodkz/mongodb-memory-server/commit/ecc4ffe2bbf47f3a2cd196d2ffa9a0e22aa4c94d)) +* **MongoBinaryDownloadUrl:** change default mint version to 21 ([df97ea8](https://github.com/nodkz/mongodb-memory-server/commit/df97ea8f9edfb97c24a53f9bc6638697df70d85e)) +* remove deprecated boolean cleanup argument (stop / cleanup) ([eef706f](https://github.com/nodkz/mongodb-memory-server/commit/eef706f7fef6ffe5caa0f0f8b3b99b168d8d7d2a)) + + +### Dependencies + +* **@types/node:** upgrade to version 16.11.7 ([c8a008a](https://github.com/nodkz/mongodb-memory-server/commit/c8a008aacff628ac0e8e7c77683987659411c8a1)) +* **async-mutex:** upgrade to version 0.5.0 ([c9f45c9](https://github.com/nodkz/mongodb-memory-server/commit/c9f45c9f032918cbdc73c0953ecc95936c246bac)) +* **mongodb:** upgrade to version 6.7.0 ([57e575c](https://github.com/nodkz/mongodb-memory-server/commit/57e575ce49344c79f2ae337da6aa43ada6738746)), closes [#804](https://github.com/nodkz/mongodb-memory-server/issues/804) +* **typescript:** upgrade to version 5.3.3 ([329d79e](https://github.com/nodkz/mongodb-memory-server/commit/329d79e484bf2f7da9e3d0ccf991bdd2cb4282a8)) + + +### Dev-Dependencies + +* **@typescript-eslint/*:** upgrade to version 6.21.0 ([b4055a7](https://github.com/nodkz/mongodb-memory-server/commit/b4055a715ee369f675a15059fb88cef38c1aec39)) +* **lint-staged:** upgrade to version 14.0.1 ([0f54d29](https://github.com/nodkz/mongodb-memory-server/commit/0f54d29fe8ab51a806bb103609a7e34346c2b220)) +* **prettier:** upgrade to version 3.3.0 ([fe1d62d](https://github.com/nodkz/mongodb-memory-server/commit/fe1d62d4fff1849e3fd76d0db745337e6fb693d7)) +* **typedoc:** upgrade to version 0.25.13 ([0775c60](https://github.com/nodkz/mongodb-memory-server/commit/0775c60f14ec3026849ed70d24535c013b1d3aa7)) + ## [9.4.1](https://github.com/typegoose/mongodb-memory-server/compare/v9.4.0...v9.4.1) (2024-07-13) diff --git a/README.md b/README.md index 5e523e3eb..f429451f5 100644 --- a/README.md +++ b/README.md @@ -68,8 +68,8 @@ Choose any package, because they are the same. They differ only in the default c ### Requirements -- NodeJS: 14.20.1+ -- Typescript: 5.0+ (if used) +- NodeJS: 16.20.1+ +- Typescript: 5.3+ (if used) And one of those (on Linux): @@ -86,7 +86,7 @@ On Linux, you will also need `libcurl4` (or `libcurl3` on some older distro vers ### Configuring which mongod binary to use -The default behavior is that version `6.0.14` for your OS will be downloaded. By setting [Environment variables](https://typegoose.github.io/mongodb-memory-server/docs/api/config-options) you are able to specify which version and binary will be downloaded: +The default behavior is that version `7.0.11` for your OS will be downloaded. By setting [Environment variables](https://typegoose.github.io/mongodb-memory-server/docs/api/config-options) you are able to specify which version and binary will be downloaded: ```sh export MONGOMS_DOWNLOAD_URL=https://fastdl.mongodb.org/linux/mongodb-linux-x86_64-ubuntu1804-4.2.8.tgz @@ -128,7 +128,7 @@ const mongod = new MongoMemoryServer({ auth?: boolean, // add "--auth" argument, dont use this directly use top-level "auth" }, binary?: { - version?: string, // by default '6.0.14' + version?: string, // by default '7.0.11' downloadDir?: string, // see the documentation on what is chosen by default https://typegoose.github.io/mongodb-memory-server/docs/api/config-options#download_dir platform?: string, // by default os.platform() arch?: string, // by default os.arch() diff --git a/docs/api/config-options.md b/docs/api/config-options.md index c85e1c3e5..d4bbd7a11 100644 --- a/docs/api/config-options.md +++ b/docs/api/config-options.md @@ -93,7 +93,7 @@ Example: `ubuntu-18.04` Option `VERSION` is used to set what mongodb version should be downloaded -Default: `6.0.14` (see [Mongodb Server Versions](../guides/mongodb-server-versions.md) for a complete list and policy) +Default: `7.0.11` (see [Mongodb Server Versions](../guides/mongodb-server-versions.md) for a complete list and policy) This Option does not have a effect when [`ARCHIVE_NAME`](#archive_name) or [`DOWNLOAD_URL`](#download_url) is defined. @@ -269,20 +269,6 @@ Also see [ARCHIVE_NAME](#archive_name). Keep in mind that downloaded binaries will never be automatically deleted. ::: -### EXP_NET0LISTEN - -| Environment Variable | PackageJson | -| :------------------: | :---------: | -| `MONGOMS_EXP_NET0LISTEN` | `expNet0Listen` | - -Option `EXP_NET0LISTEN` is used to use the experimental (non-predictable) port generation of `net.listen`. - -This option will use a random open port, which will lessen the "port is already in use" errors, but will not eliminate them. - -This is a experimental option, it maybe removed, renamed or have changed behavior in the future. - -Default: `false` - ## How to use them in the package.json To use the config options in the `package.json`, they need to be camelCased (and without `_`), and need to be in the property `config.mongodbMemoryServer` diff --git a/docs/api/interfaces/mongo-dispose-opts.md b/docs/api/interfaces/mongo-dispose-opts.md new file mode 100644 index 000000000..2b3e851bd --- /dev/null +++ b/docs/api/interfaces/mongo-dispose-opts.md @@ -0,0 +1,20 @@ +--- +id: mongo-memory-dispose-opts +title: 'DisposeOptions' +--- + +API Documentation of `DisposeOptions`-Interface + +## Values for `DisposeOptions` + +### enabled + +Typings: `enabled?: boolean` + +Set whether to stop the manager on `[Symbol.asyncDispose]` calls. + +### cleanup + +Typings: `cleanup?: Cleanup` + +Set custom cleanup options to be used for disposal, see [`cleanup` function](../classes/mongo-memory-server.md#cleanup) (the same options apply for the replset). diff --git a/docs/api/interfaces/mongo-memory-server-opts.md b/docs/api/interfaces/mongo-memory-server-opts.md index 28cd8de5e..3a0a66a53 100644 --- a/docs/api/interfaces/mongo-memory-server-opts.md +++ b/docs/api/interfaces/mongo-memory-server-opts.md @@ -9,12 +9,16 @@ API Documentation of `MongoMemoryServerOpts`-Interface ### instance -Typings: `instance?: MemoryServerInstanceOpts` +Typings: `instance?: MemoryServerInstanceOpts & ExtraOptions` Set custom options based on [`MongoMemoryInstanceOpts`](./mongo-memory-instance-opts.md), but ignores some properties: - `auth` is ignored because it is set via [auth](#auth) property. +Extra options specific to [`MongoMemoryServer` class](../classes/mongo-memory-server.md): + +- `portGeneration`: enable / disable port generation, enabled by default. + ### binary Typings: `binary?: MongoBinaryOpts` @@ -32,3 +36,9 @@ Set custom spawn options for spawning processes, uses [`SpawnOptions`](https://n Typings: `auth?: AutomaticAuth` Set custom Authentication options for the instance, uses [`AutomaticAuth`](./mongo-memory-server-automaticauth.md). + +### dispose + +Typings: `dispose?: DisposeOptions` + +Set custom behavior for when `[Symbol.asyncDispose]` is called, uses [`DisposeOptions`](./mongo-dispose-opts.md). diff --git a/docs/api/interfaces/replset-opts.md b/docs/api/interfaces/replset-opts.md index 665d0183f..27e7f57f9 100644 --- a/docs/api/interfaces/replset-opts.md +++ b/docs/api/interfaces/replset-opts.md @@ -91,3 +91,9 @@ Set how many ReplSet members to spawn, this number will be deducted from length :::tip It is recommended to set this number to a **odd** number, and try to never have it be **even**, see [MongoDB Deploy an Odd Number of Members](https://www.mongodb.com/docs/v5.2/core/replica-set-architectures/#deploy-an-odd-number-of-members). ::: + +### dispose + +Typings: `dispose?: DisposeOptions` + +Set custom behavior for when `[Symbol.asyncDispose]` is called, uses [`DisposeOptions`](./mongo-dispose-opts.md). diff --git a/docs/guides/faq.md b/docs/guides/faq.md index 883fc3512..d43648c2d 100644 --- a/docs/guides/faq.md +++ b/docs/guides/faq.md @@ -21,3 +21,14 @@ Since `8.4.0` objects can also be used instead of just booleans for parameter in For Example `.stop({ doCleanup: false })` can be used instead of `.stop(false)`. ::: + +### Does this package support Explicit Resource Management? + +Yes, `[Symbol.asyncDispose]` is implemented for all manager classes, behavior can be configured via `dispose` options: + +- [`MongoMemoryServerOpts.dispose`](../api/interfaces/mongo-memory-server-opts.md#dispose) +- [`ReplSetOpts.dispose`](../api/interfaces/replset-opts.md#dispose) + +:::note +Note that when using `await using server =` that `[Symbol.asyncDispose]` is called at the end of the scope even if the value is reassigned to something out of the current scope. +::: diff --git a/docs/guides/integration-examples/test-runners.md b/docs/guides/integration-examples/test-runners.md index 2c006dae1..636624718 100644 --- a/docs/guides/integration-examples/test-runners.md +++ b/docs/guides/integration-examples/test-runners.md @@ -56,7 +56,7 @@ export = async function globalSetup() { process.env.MONGO_URI = `mongodb://${config.IP}:${config.Port}`; } - // The following is to make sure the database is clean before an test starts + // The following is to make sure the database is clean before a test suite starts const conn = await mongoose.connect(`${process.env.MONGO_URI}/${config.Database}`); await conn.connection.db.dropDatabase(); await mongoose.disconnect(); @@ -89,7 +89,7 @@ beforeAll(async () => { }); afterAll(async () => { - // put your client disconnection code here, example with mongodb: + // put your client disconnection code here, example with mongoose: await mongoose.disconnect(); }); ``` @@ -109,17 +109,16 @@ Keep in mind that jest's global-setup and global-teardown do **not** share a env Start Mocha with `--timeout 60000` cause first download of MongoDB binaries may take a time. -```js +```ts import mongoose from 'mongoose'; import { MongoMemoryServer } from 'mongodb-memory-server'; let mongoServer; -const opts = { useMongoClient: true }; // remove this option if you use mongoose 5 and above before(async () => { mongoServer = await MongoMemoryServer.create(); const mongoUri = mongoServer.getUri(); - await mongoose.connect(mongoUri, opts); + await mongoose.connect(mongoUri); }); after(async () => { @@ -130,7 +129,7 @@ after(async () => { describe('...', () => { it('...', async () => { const User = mongoose.model('User', new mongoose.Schema({ name: String })); - const cnt = await User.count(); + const cnt = await User.countDocuments(); expect(cnt).to.equal(0); }); }); @@ -138,8 +137,8 @@ describe('...', () => { ## AVA test runner -For AVA written [detailed tutorial](https://github.com/zellwk/ava/blob/8b7ccba1d80258b272ae7cae6ba4967cd1c13030/docs/recipes/endpoint-testing-with-mongoose.md) how to test mongoose models by @zellwk. +For AVA there is a [detailed written tutorial](https://github.com/zellwk/ava/blob/8b7ccba1d80258b272ae7cae6ba4967cd1c13030/docs/recipes/endpoint-testing-with-mongoose.md) on how to test mongoose models with mongodb-memory-server by [@zellwk](https://github.com/zellwk). :::note -Note that this mentioned tutorial is pre 7.x +Note that this tutorial is pre mongodb-memory-server 7.x. ::: diff --git a/docs/guides/migration/migrate10.md b/docs/guides/migration/migrate10.md new file mode 100644 index 000000000..880f80426 --- /dev/null +++ b/docs/guides/migration/migrate10.md @@ -0,0 +1,48 @@ +--- +id: migrate10 +title: 'Migrate to version 10.0.0' +--- + +Here are the Important changes made for 10.0.0 + +:::caution Important, Read this first +This Guide is written for migration from version `9.4.1` to `10.0.0`, for versions `>10.0.0 <11.0.0`, please consult the [CHANGELOG](https://github.com/typegoose/mongodb-memory-server/blob/master/CHANGELOG.md) +::: + +## Breaking Changes + +### Minimal NodeJS version is now `16` + +With 10.0.0 the minimal nodejs required is `16.20.1`. + +### Mongodb Driver Version upgraded to 6.x + +The used MongoDB Driver version is now `6.7.0`. + +### Default binary version is now 7.x + +The default binary version has been upgraded from `6.0.x` to `7.0.x`. For more specifics see [mongodb-server-versions](../mongodb-server-versions.md). + +:::note +In mongodb `7.0.0` storage engine `ephemeralForTest` has been removed, mongodb-memory-server will automatically translate any occurrence to `wiredTiger` with a warning. + +It is recommended to run the tests against a tmpfs or equivalent (default `/tmp` on linux / macos). +::: + +## Non-Breaking changes / Additions + +### Compiler target is now `es2021` + +The tsconfig `target` option has been updated to `es2021`, which will result in less polyfills. +This should be a non-breaking change. + +### Getport now uses `net0listen` by default + +This means a port is now generated by the engine (like nodejs) itself, previously known as `EXP_NET0LISTEN`. +This should reduce amount of `Max port tries exceeded` errors. + +### Allow setting port generation in MongoMemoryServer + +Starting with 10.0 there is a new option to set whether port generation is enabled or not on `MongoMemoryServer` called `portGeneration`. (default: `true`) + +(Note that the `forceSamePort` parameter in `.start` will overwrite this option) diff --git a/docs/guides/mongodb-server-versions.md b/docs/guides/mongodb-server-versions.md index 54a60e4d4..70be330b8 100644 --- a/docs/guides/mongodb-server-versions.md +++ b/docs/guides/mongodb-server-versions.md @@ -31,6 +31,7 @@ Starting with MongoDB version 5.0, the default versions for `mongodb-memory-serv | `mongodb-memory-server-core` Version | Default MongoDB Version | | :----------------------------------: | :---------------------: | +| 10.0.x - 10.0.x | 7.0.11 | | 9.2.x - 9.2.x | 6.0.14 | | 9.0.x - 9.1.x | 6.0.9 | | 8.14.x - 8.16.x | 5.0.19 | diff --git a/docs/guides/quick-start-guide.md b/docs/guides/quick-start-guide.md index f49797f98..16b9f9ccb 100644 --- a/docs/guides/quick-start-guide.md +++ b/docs/guides/quick-start-guide.md @@ -19,8 +19,8 @@ If Top-Level async-await is not available for your case, the code can in most ca ## Requirements -- NodeJS: 14.20.1+ -- Typescript: 5.0+ (if used) +- NodeJS: 16.20.1+ +- Typescript: 5.3+ (if used) When on Linux, one of the following are required: diff --git a/docs/guides/supported-systems.md b/docs/guides/supported-systems.md index e26bf2b51..78dc92d1e 100644 --- a/docs/guides/supported-systems.md +++ b/docs/guides/supported-systems.md @@ -118,7 +118,7 @@ Default version is `1` (uses mongodb's `ubuntu` release)
Lowest supported Distribution version is `3` (or `0.3`)
Highest version is `7`
-Default version is `6` +Default version is `7` ### Linux Mint @@ -126,8 +126,8 @@ Default version is `6` (uses mongodb's `ubuntu` release)
Lowest supported Distribution version is `17`
-Highest version is `21`
-Default version is `20` +Highest version is `22`
+Default version is `21` ### Suse diff --git a/package.json b/package.json index 6f058e033..24bada3a0 100644 --- a/package.json +++ b/package.json @@ -11,22 +11,22 @@ "@commitlint/cli": "17.8.1", "@commitlint/config-conventional": "17.8.1", "@types/jest": "^29.5.12", - "@types/node": "~14.18.63", - "@typescript-eslint/eslint-plugin": "5.59.9", - "@typescript-eslint/parser": "5.59.9", + "@types/node": "~16.11.7", + "@typescript-eslint/eslint-plugin": "6.21.0", + "@typescript-eslint/parser": "6.21.0", "commitlint": "17.8.1", "cross-env": "7.0.3", "doctoc": "2.2.1", "eslint": "8.57.0", "eslint-config-prettier": "^9.1.0", - "eslint-plugin-prettier": "5.1.3", + "eslint-plugin-prettier": "5.2.1", "husky": "8.0.3", "jest": "29.7.0", - "lint-staged": "13.2.3", - "prettier": "3.2.5", - "ts-jest": "29.1.4", - "typedoc": "^0.24.8", - "typescript": "5.0.4" + "lint-staged": "14.0.1", + "prettier": "3.3.3", + "ts-jest": "29.2.2", + "typedoc": "^0.25.13", + "typescript": "~5.3.3" }, "workspaces": { "packages": [ diff --git a/packages/mongodb-memory-server-core/package.json b/packages/mongodb-memory-server-core/package.json index f41c80aac..a0367fae7 100644 --- a/packages/mongodb-memory-server-core/package.json +++ b/packages/mongodb-memory-server-core/package.json @@ -1,6 +1,6 @@ { "name": "mongodb-memory-server-core", - "version": "9.4.1", + "version": "10.0.0-beta.5", "description": "MongoDB Server for testing (core package, without autodownload). The server will allow you to connect your favourite ODM or client library to the MongoDB Server and run parallel integration tests isolated from each other.", "main": "lib/index", "types": "lib/index.d.ts", @@ -11,7 +11,7 @@ "directory": "packages/mongodb-memory-server-core" }, "engines": { - "node": ">=14.20.1" + "node": ">=16.20.1" }, "files": [ "lib", @@ -39,19 +39,19 @@ "@types/tar-stream": "^3.1.3", "@types/yauzl": "^2.10.3", "@types/yazl": "^2.4.5", - "rimraf": "^5.0.7", + "rimraf": "^5.0.9", "yazl": "^2.5.1" }, "dependencies": { - "async-mutex": "^0.4.1", + "async-mutex": "^0.5.0", "camelcase": "^6.3.0", "debug": "^4.3.5", "find-cache-dir": "^3.3.2", "follow-redirects": "^1.15.6", - "https-proxy-agent": "^7.0.4", - "mongodb": "^5.9.2", + "https-proxy-agent": "^7.0.5", + "mongodb": "^6.7.0", "new-find-package-json": "^2.0.0", - "semver": "^7.6.2", + "semver": "^7.6.3", "tar-stream": "^3.1.7", "tslib": "^2.6.3", "yauzl": "^3.1.3" diff --git a/packages/mongodb-memory-server-core/src/MongoMemoryReplSet.ts b/packages/mongodb-memory-server-core/src/MongoMemoryReplSet.ts index 393b0d85d..974568f8a 100644 --- a/packages/mongodb-memory-server-core/src/MongoMemoryReplSet.ts +++ b/packages/mongodb-memory-server-core/src/MongoMemoryReplSet.ts @@ -1,5 +1,10 @@ import { EventEmitter } from 'events'; -import { MongoMemoryServer, AutomaticAuth, MongoMemoryServerOpts } from './MongoMemoryServer'; +import { + MongoMemoryServer, + AutomaticAuth, + MongoMemoryServerOpts, + DisposeOptions, +} from './MongoMemoryServer'; import { assertion, authDefault, @@ -92,6 +97,10 @@ export interface ReplSetOpts { * @default {} */ configSettings?: MongoMemoryReplSetConfigSettings; + /** + * Options for automatic dispose for "Explicit Resource Management" + */ + dispose?: DisposeOptions; } /** @@ -140,6 +149,7 @@ export enum MongoMemoryReplSetEvents { stateChange = 'stateChange', } +// eslint-disable-next-line @typescript-eslint/no-unsafe-declaration-merging export interface MongoMemoryReplSet extends EventEmitter { // Overwrite EventEmitter's definitions (to provide at least the event names) emit(event: MongoMemoryReplSetEvents, ...args: any[]): boolean; @@ -150,6 +160,7 @@ export interface MongoMemoryReplSet extends EventEmitter { /** * Class for managing an replSet */ +// eslint-disable-next-line @typescript-eslint/no-unsafe-declaration-merging export class MongoMemoryReplSet extends EventEmitter implements ManagerAdvanced { /** * All servers this ReplSet instance manages @@ -262,6 +273,7 @@ export class MongoMemoryReplSet extends EventEmitter implements ManagerAdvanced spawn: {}, storageEngine, configSettings: {}, + dispose: {}, }; // force overwrite "storageEngine" because it is transformed already this._replSetOpts = { ...defaults, ...val, storageEngine }; @@ -522,11 +534,6 @@ export class MongoMemoryReplSet extends EventEmitter implements ManagerAdvanced /** Default to cleanup temporary, but not custom dbpaths */ let cleanup: Cleanup = { doCleanup: true, force: false }; - // TODO: for next major release (10.0), this should be removed - if (typeof cleanupOptions === 'boolean') { - throw new Error('Unsupported argument type: boolean'); - } - // handle the new way of setting what and how to cleanup if (typeof cleanupOptions === 'object') { cleanup = cleanupOptions; @@ -577,11 +584,6 @@ export class MongoMemoryReplSet extends EventEmitter implements ManagerAdvanced /** Default to doing cleanup, but not forcing it */ let cleanup: Cleanup = { doCleanup: true, force: false }; - // TODO: for next major release (10.0), this should be removed - if (typeof options === 'boolean') { - throw new Error('Unsupported argument type: boolean'); - } - // handle the new way of setting what and how to cleanup if (typeof options === 'object') { cleanup = options; @@ -661,7 +663,7 @@ export class MongoMemoryReplSet extends EventEmitter implements ManagerAdvanced const isInMemory = this.servers[0].instanceInfo?.storageEngine === 'ephemeralForTest'; const extraOptions = this._ranCreateAuth - ? this.servers[0].instanceInfo?.instance.extraConnectionOptions ?? {} + ? (this.servers[0].instanceInfo?.instance.extraConnectionOptions ?? {}) : {}; const con: MongoClient = await MongoClient.connect(uris[0], { @@ -797,6 +799,13 @@ export class MongoMemoryReplSet extends EventEmitter implements ManagerAdvanced log('_waitForPrimary: detected one primary instance '); } + + // Symbol for "Explicit Resource Management" + async [Symbol.asyncDispose]() { + if (this.replSetOpts.dispose?.enabled ?? true) { + await this.stop(this.replSetOpts.dispose?.cleanup); + } + } } export default MongoMemoryReplSet; diff --git a/packages/mongodb-memory-server-core/src/MongoMemoryServer.ts b/packages/mongodb-memory-server-core/src/MongoMemoryServer.ts index 1bc46b77e..8625a465b 100644 --- a/packages/mongodb-memory-server-core/src/MongoMemoryServer.ts +++ b/packages/mongodb-memory-server-core/src/MongoMemoryServer.ts @@ -18,7 +18,7 @@ import { MongoBinaryOpts } from './util/MongoBinary'; import debug from 'debug'; import { EventEmitter } from 'events'; import { promises as fspromises } from 'fs'; -import { AddUserOptions, MongoClient } from 'mongodb'; +import { MongoClient } from 'mongodb'; import { InstanceInfoError, StateError, UnknownVersionError } from './util/errors'; import * as os from 'os'; import { DryMongoBinary } from './util/DryMongoBinary'; @@ -30,7 +30,25 @@ const log = debug('MongoMS:MongoMemoryServer'); * Type with automatic options removed * "auth" is automatically handled and set via {@link AutomaticAuth} */ -export type MemoryServerInstanceOpts = Omit; +export type MemoryServerInstanceOpts = Omit & ExtraInstanceOpts; + +/** + * Extra Instance options specifically for {@link MongoMemoryServer} + */ +export interface ExtraInstanceOpts { + /** + * Change if port generation is enabled or not. + * + * If enabled and a port is set, that port is tried, if locked a new one will be generated. + * If disabled and a port is set, only that port is tried, if locked a error will be thrown. + * If disabled and no port is set, will act as if enabled. + * + * This setting will get overwritten by `start`'s `forceSamePort` parameter if set + * + * @default true + */ + portGeneration?: boolean; +} /** * MongoMemoryServer Stored Options @@ -43,6 +61,27 @@ export interface MongoMemoryServerOpts { * Defining this enables automatic user creation */ auth?: AutomaticAuth; + /** + * Options for automatic dispose for "Explicit Resource Management" + */ + dispose?: DisposeOptions; +} + +/** + * Options to configure `Symbol.asyncDispose` behavior + */ +export interface DisposeOptions { + /** + * Set whether to run the dispose hook or not. + * Note that this only applies when `Symbol.asyncDispose` is actually called + * @default true + */ + enabled?: boolean; + /** + * Pass custom options for cleanup + * @default { doCleanup: true, force: false } + */ + cleanup?: Cleanup; } export interface AutomaticAuth { @@ -143,11 +182,22 @@ export type UserRoles = | 'root' | string; +// copied from mongodb 5.9.1 as it has been removed for 6.0.0 +export interface RoleSpecification { + /** + * A role grants privileges to perform sets of actions on defined resources. + * A given role applies to the database on which it is defined and can grant access down to a collection level of granularity. + */ + role: string; + /** The database this user's role should effect. */ + db: string; +} + /** * Interface options for "db.createUser" (used for this package) * This interface is WITHOUT the custom options from this package * (Some text copied from https://docs.mongodb.com/manual/reference/method/db.createUser/#definition) - * This interface only exists, because mongodb dosnt provide such an interface for "createUser" (or as just very basic types) + * This interface only exists, because mongodb dosnt provide such an interface for "createUser" (or as just very basic types) as of 6.7.0 */ export interface CreateUserMongoDB { /** @@ -169,7 +219,7 @@ export interface CreateUserMongoDB { /** * The Roles for the user, can be an empty array */ - roles: AddUserOptions['roles']; + roles: string | string[] | RoleSpecification | RoleSpecification[]; /** * Specify the specific SCRAM mechanism or mechanisms for creating SCRAM user credentials. */ @@ -210,6 +260,7 @@ export interface MongoMemoryServerGetStartOptions { mongodOptions: Partial; } +// eslint-disable-next-line @typescript-eslint/no-unsafe-declaration-merging export interface MongoMemoryServer extends EventEmitter { // Overwrite EventEmitter's definitions (to provide at least the event names) emit(event: MongoMemoryServerEvents, ...args: any[]): boolean; @@ -217,6 +268,7 @@ export interface MongoMemoryServer extends EventEmitter { once(event: MongoMemoryServerEvents, listener: (...args: any[]) => void): this; } +// eslint-disable-next-line @typescript-eslint/no-unsafe-declaration-merging export class MongoMemoryServer extends EventEmitter implements ManagerAdvanced { /** * Information about the started instance @@ -269,10 +321,10 @@ export class MongoMemoryServer extends EventEmitter implements ManagerAdvanced { /** * Start the Mongod Instance - * @param forceSamePort Force to use the Same Port, if already an "instanceInfo" exists + * @param forceSamePort Force to use the port defined in `options.instance` (disabled port generation) * @throws if state is not "new" or "stopped" */ - async start(forceSamePort: boolean = false): Promise { + async start(forceSamePort?: boolean): Promise { this.debug('start: Called .start() method'); switch (this._state) { @@ -358,6 +410,7 @@ export class MongoMemoryServer extends EventEmitter implements ManagerAdvanced { /** * Construct Instance Starting Options + * @param forceSamePort Force to use the port defined in `options.instance` (disabled port generation) */ protected async getStartOptions( forceSamePort: boolean = false @@ -449,16 +502,18 @@ export class MongoMemoryServer extends EventEmitter implements ManagerAdvanced { /** * Internal Function to start an instance - * @param forceSamePort Force to use the Same Port, if already an "instanceInfo" exists + * @param forceSamePort Force to use the port defined in `options.instance` (disabled port generation) * @private */ - async _startUpInstance(forceSamePort: boolean = false): Promise { + async _startUpInstance(forceSamePort?: boolean): Promise { this.debug('_startUpInstance: Called MongoMemoryServer._startUpInstance() method'); + const useSamePort = forceSamePort ?? !(this.opts.instance?.portGeneration ?? true); + if (!isNullOrUndefined(this._instanceInfo)) { this.debug('_startUpInstance: "instanceInfo" already defined, reusing instance'); - if (!forceSamePort) { + if (!useSamePort) { const newPort = await this.getNewPort(this._instanceInfo.port); this._instanceInfo.instance.instanceOpts.port = newPort; this._instanceInfo.port = newPort; @@ -469,7 +524,7 @@ export class MongoMemoryServer extends EventEmitter implements ManagerAdvanced { return; } - const { mongodOptions, createAuth, data } = await this.getStartOptions(forceSamePort); + const { mongodOptions, createAuth, data } = await this.getStartOptions(useSamePort); this.debug(`_startUpInstance: Creating new MongoDB instance with options:`, mongodOptions); const instance = await MongoInstance.create(mongodOptions); @@ -516,11 +571,6 @@ export class MongoMemoryServer extends EventEmitter implements ManagerAdvanced { /** Default to cleanup temporary, but not custom dbpaths */ let cleanup: Cleanup = { doCleanup: true, force: false }; - // TODO: for next major release (10.0), this should be removed - if (typeof cleanupOptions === 'boolean') { - throw new Error('Unsupported argument type: boolean'); - } - // handle the new way of setting what and how to cleanup if (typeof cleanupOptions === 'object') { cleanup = cleanupOptions; @@ -564,11 +614,6 @@ export class MongoMemoryServer extends EventEmitter implements ManagerAdvanced { /** Default to doing cleanup, but not forcing it */ let cleanup: Cleanup = { doCleanup: true, force: false }; - // TODO: for next major release (10.0), this should be removed - if (typeof options === 'boolean') { - throw new Error('Unsupported argument type: boolean'); - } - // handle the new way of setting what and how to cleanup if (typeof options === 'object') { cleanup = options; @@ -825,6 +870,13 @@ export class MongoMemoryServer extends EventEmitter implements ManagerAdvanced { ? this.auth.enable : false; // if "this._replSetOpts.auth.enable" is not defined, default to false } + + // Symbol for "Explicit Resource Management" + async [Symbol.asyncDispose]() { + if (this.opts.dispose?.enabled ?? true) { + await this.stop(this.opts.dispose?.cleanup); + } + } } export default MongoMemoryServer; diff --git a/packages/mongodb-memory-server-core/src/__tests__/MongoMemoryReplSet.test.ts b/packages/mongodb-memory-server-core/src/__tests__/MongoMemoryReplSet.test.ts index a595d593c..ccd52218e 100644 --- a/packages/mongodb-memory-server-core/src/__tests__/MongoMemoryReplSet.test.ts +++ b/packages/mongodb-memory-server-core/src/__tests__/MongoMemoryReplSet.test.ts @@ -239,6 +239,10 @@ describe('single server replset', () => { jest.spyOn(console, 'warn').mockImplementationOnce(() => void 0); const replSet = await MongoMemoryReplSet.create({ replSet: { auth: { enable: true }, count: 3, storageEngine: 'ephemeralForTest' }, + binary: { + // 7.0 removed "ephemeralForTest", this test is explicitly for that engine + version: '6.0.14', + }, }); utils.assertion(!utils.isNullOrUndefined(replSet.replSetOpts.auth)); @@ -436,8 +440,9 @@ describe('MongoMemoryReplSet', () => { dbName: replSet.replSetOpts.dbName, // not testing this value, because its generated "randomly" ip: '127.0.0.1', spawn: {}, - storageEngine: 'ephemeralForTest', + storageEngine: 'wiredTiger', configSettings: {}, + dispose: {}, }); replSet.replSetOpts = { auth: { enable: true } }; // @ts-expect-error because "_replSetOpts" is protected @@ -451,8 +456,9 @@ describe('MongoMemoryReplSet', () => { dbName: replSet.replSetOpts.dbName, // not testing this value, because its generated "randomly" ip: '127.0.0.1', spawn: {}, - storageEngine: 'ephemeralForTest', + storageEngine: 'wiredTiger', configSettings: {}, + dispose: {}, }); }); @@ -584,22 +590,6 @@ describe('MongoMemoryReplSet', () => { } as utils.Cleanup); }); - it('should not support boolean arguments', async () => { - const replSet = new MongoMemoryReplSet(); - - try { - await replSet.stop( - // @ts-expect-error Testing a non-existing overload - true - ); - fail('Expected to fail'); - } catch (err) { - expect(err).toBeInstanceOf(Error); - assertIsError(err); - expect(err.message).toMatchSnapshot(); - } - }); - it('should call cleanup and pass-through cleanup options', async () => { const replSet = await MongoMemoryReplSet.create({ replSet: { count: 1 } }); @@ -670,22 +660,6 @@ describe('MongoMemoryReplSet', () => { } as utils.Cleanup); }); - it('should not support boolean arguments', async () => { - const replSet = new MongoMemoryReplSet(); - - try { - await replSet.cleanup( - // @ts-expect-error Testing a non-existing overload - true - ); - fail('Expected to fail'); - } catch (err) { - expect(err).toBeInstanceOf(Error); - assertIsError(err); - expect(err.message).toMatchSnapshot(); - } - }); - it('should run cleanup with cleanup options and pass-through options to lower', async () => { const replSet = await MongoMemoryReplSet.create({ replSet: { count: 1 } }); @@ -798,4 +772,81 @@ describe('MongoMemoryReplSet', () => { await server.stop(); }); }); + + describe('asyncDispose', () => { + it('should work by default', async () => { + jest.spyOn(MongoMemoryReplSet.prototype, 'start'); + jest.spyOn(MongoMemoryReplSet.prototype, 'stop'); + let outer; + // would like to test this, but jest seemingly does not support spying on symbols + // jest.spyOn(MongoMemoryReplSet.prototype, Symbol.asyncDispose); + { + await using server = await MongoMemoryReplSet.create(); + // use the value and test that it actually runs, as "getUri" will throw is not in "running" state + server.getUri(); + // reassignment still calls dispose at the *current* scope + outer = server; + } + // not "stopped" because of cleanup + expect(outer.state).toStrictEqual(MongoMemoryReplSetStates.stopped); + expect(outer.servers.length).toStrictEqual(0); + expect(MongoMemoryReplSet.prototype.start).toHaveBeenCalledTimes(1); + expect(MongoMemoryReplSet.prototype.stop).toHaveBeenCalledTimes(1); + // expect(MongoMemoryReplSet.prototype[Symbol.asyncDispose]).toHaveBeenCalledTimes(1); + }); + + it('should be able to be disabled', async () => { + jest.spyOn(MongoMemoryReplSet.prototype, 'start'); + jest.spyOn(MongoMemoryReplSet.prototype, 'stop'); + let outer; + // would like to test this, but jest seemingly does not support spying on symbols + // jest.spyOn(MongoMemoryReplSet.prototype, Symbol.asyncDispose); + { + await using server = await MongoMemoryReplSet.create({ + replSet: { dispose: { enabled: false } }, + }); + // use the value and test that it actually runs, as "getUri" will throw is not in "running" state + server.getUri(); + // reassignment still calls dispose at the *current* scope + outer = server; + } + expect(outer.state).toStrictEqual(MongoMemoryReplSetStates.running); + expect(outer.servers.length).toStrictEqual(1); + expect(MongoMemoryReplSet.prototype.start).toHaveBeenCalledTimes(1); + expect(MongoMemoryReplSet.prototype.stop).toHaveBeenCalledTimes(0); + // expect(MongoMemoryReplSet.prototype[Symbol.asyncDispose]).toHaveBeenCalledTimes(1); + await outer.stop(); + // not "stopped" because of cleanup + expect(outer.state).toStrictEqual(MongoMemoryReplSetStates.stopped); + }); + + it('should be able to set custom cleanup', async () => { + jest.spyOn(MongoMemoryReplSet.prototype, 'start'); + jest.spyOn(MongoMemoryReplSet.prototype, 'stop'); + let outer; + // would like to test this, but jest seemingly does not support spying on symbols + // jest.spyOn(MongoMemoryReplSet.prototype, Symbol.asyncDispose); + { + await using server = await MongoMemoryReplSet.create({ + replSet: { + dispose: { cleanup: { doCleanup: false } }, + }, + }); + // use the value and test that it actually runs, as "getUri" will throw is not in "running" state + server.getUri(); + // reassignment still calls dispose at the *current* scope + outer = server; + } + // not "stopped" because of cleanup + expect(outer.state).toStrictEqual(MongoMemoryReplSetStates.stopped); + expect(outer.servers.length).toStrictEqual(1); + expect(MongoMemoryReplSet.prototype.start).toHaveBeenCalledTimes(1); + expect(MongoMemoryReplSet.prototype.stop).toHaveBeenCalledTimes(1); + // expect(MongoMemoryReplSet.prototype[Symbol.asyncDispose]).toHaveBeenCalledTimes(1); + await outer.cleanup({ doCleanup: true }); + // not "stopped" because of cleanup + expect(outer.state).toStrictEqual(MongoMemoryReplSetStates.stopped); + expect(outer.servers.length).toStrictEqual(0); + }); + }); }); diff --git a/packages/mongodb-memory-server-core/src/__tests__/MongoMemoryServer.test.ts b/packages/mongodb-memory-server-core/src/__tests__/MongoMemoryServer.test.ts index cee951352..08a27b2c2 100644 --- a/packages/mongodb-memory-server-core/src/__tests__/MongoMemoryServer.test.ts +++ b/packages/mongodb-memory-server-core/src/__tests__/MongoMemoryServer.test.ts @@ -77,6 +77,10 @@ describe('MongoMemoryServer', () => { instance: { storageEngine: 'ephemeralForTest', }, + binary: { + // 7.0 removed "ephemeralForTest", this test is explicitly for that engine + version: '6.0.14', + }, }); utils.assertion(!utils.isNullOrUndefined(mongoServer.instanceInfo)); @@ -259,6 +263,10 @@ describe('MongoMemoryServer', () => { instance: { storageEngine: 'ephemeralForTest', }, + binary: { + // 7.0 removed "ephemeralForTest", this test is explicitly for that engine + version: '6.0.14', + }, }); utils.assertion(!utils.isNullOrUndefined(mongoServer.instanceInfo)); @@ -368,9 +376,6 @@ describe('MongoMemoryServer', () => { auth: { enable: false, }, - instance: { - storageEngine: 'ephemeralForTest', - }, }); utils.assertion(!utils.isNullOrUndefined(mongoServer.instanceInfo)); @@ -453,6 +458,142 @@ describe('MongoMemoryServer', () => { 'Cannot start because "instance.mongodProcess" is already defined!' ); }); + + describe('instance.portGeneration', () => { + it('should use a predefined port if "opts.instance.portGeneration" is "false"', async () => { + const predefinedPort = 30001; + + const mongoServer = new MongoMemoryServer({ + instance: { port: predefinedPort, portGeneration: false }, + }); + const newPortSpy = jest + // @ts-expect-error "getNewPort" is protected + .spyOn(mongoServer, 'getNewPort') + .mockImplementation(() => fail('Expected this function to not be called')); + + await mongoServer.start(); + + expect(newPortSpy).not.toHaveBeenCalled(); + // @ts-expect-error "_instanceInfo" is protected + expect(mongoServer._instanceInfo!.port).toStrictEqual(predefinedPort); + + await mongoServer.stop(); + }); + + it('should Error if a predefined port is already in use if "opts.instance.portGeneration" is "false"', async () => { + const predefinedPort = 30002; + + const newPortSpy = jest + // @ts-expect-error "getNewPort" is protected + .spyOn(MongoMemoryServer.prototype, 'getNewPort') + .mockImplementation(() => fail('Expected this function to not be called')); + + jest.spyOn(console, 'warn').mockImplementationOnce(() => void 0); + + const mongoServer1 = new MongoMemoryServer({ + instance: { port: predefinedPort, portGeneration: false }, + }); + + const mongoServer2 = new MongoMemoryServer({ + instance: { port: predefinedPort, portGeneration: false }, + }); + + await mongoServer1.start(); + + await expect(() => mongoServer2.start()).rejects.toMatchSnapshot(); + + expect(newPortSpy).not.toHaveBeenCalled(); + // @ts-expect-error "_instanceInfo" is protected + expect(mongoServer1._instanceInfo!.port).toStrictEqual(predefinedPort); + expect(console.warn).toHaveBeenCalledTimes(1); + + await mongoServer1.stop(); + }); + + it('should generate a new port if the predefined port is already in use and "opts.instance.portGeneration" is "true"', async () => { + const predefinedPort = 30003; + + const newPortSpy = jest + // @ts-expect-error "getNewPort" is protected + .spyOn(MongoMemoryServer.prototype, 'getNewPort'); + + const mongoServer1 = new MongoMemoryServer({ + instance: { port: predefinedPort, portGeneration: false }, + }); + + const mongoServer2 = new MongoMemoryServer({ + instance: { port: predefinedPort, portGeneration: true }, + }); + + await mongoServer1.start(); + + expect(newPortSpy).not.toHaveBeenCalled(); + + await mongoServer2.start(); + + expect(newPortSpy).toHaveBeenCalledTimes(1); + + await mongoServer1.stop(); + await mongoServer2.stop(); + }); + + it('should overwrite "opts.instance.portGeneration" if "forceSamePort" is set ("forceSamePort true" case)', async () => { + const predefinedPort = 30004; + + const newPortSpy = jest + // @ts-expect-error "getNewPort" is protected + .spyOn(MongoMemoryServer.prototype, 'getNewPort') + .mockImplementation(() => fail('Expected this function to not be called')); + + jest.spyOn(console, 'warn').mockImplementationOnce(() => void 0); + + const mongoServer1 = new MongoMemoryServer({ + instance: { port: predefinedPort, portGeneration: false }, + }); + + const mongoServer2 = new MongoMemoryServer({ + instance: { port: predefinedPort, portGeneration: true }, + }); + + await mongoServer1.start(); + + await expect(() => mongoServer2.start(true)).rejects.toMatchSnapshot(); + + expect(newPortSpy).not.toHaveBeenCalled(); + // @ts-expect-error "_instanceInfo" is protected + expect(mongoServer1._instanceInfo!.port).toStrictEqual(predefinedPort); + expect(console.warn).toHaveBeenCalledTimes(1); + + await mongoServer1.stop(); + }); + + it('should overwrite "opts.instance.portGeneration" if "forceSamePort" is set ("forceSamePort false" case)', async () => { + const predefinedPort = 30005; + + const newPortSpy = jest + // @ts-expect-error "getNewPort" is protected + .spyOn(MongoMemoryServer.prototype, 'getNewPort'); + + const mongoServer1 = new MongoMemoryServer({ + instance: { port: predefinedPort, portGeneration: false }, + }); + + const mongoServer2 = new MongoMemoryServer({ + instance: { port: predefinedPort, portGeneration: false }, + }); + + await mongoServer1.start(); + + expect(newPortSpy).not.toHaveBeenCalled(); + + await mongoServer2.start(false); + + expect(newPortSpy).toHaveBeenCalledTimes(1); + + await mongoServer1.stop(); + await mongoServer2.stop(); + }); + }); }); describe('ensureInstance()', () => { @@ -623,22 +764,6 @@ describe('MongoMemoryServer', () => { expect(cleanupSpy).toHaveBeenCalledWith({ doCleanup: true } as utils.Cleanup); }); - it('should not support boolean arguments', async () => { - const mongoServer = new MongoMemoryServer(); - - try { - await mongoServer.stop( - // @ts-expect-error Testing a non-existing overload - true - ); - fail('Expected to fail'); - } catch (err) { - expect(err).toBeInstanceOf(Error); - assertIsError(err); - expect(err.message).toMatchSnapshot(); - } - }); - it('should call cleanup and pass-through cleanup options', async () => { const mongoServer = new MongoMemoryServer(); @@ -791,22 +916,6 @@ describe('MongoMemoryServer', () => { expect(mongoServer.instanceInfo).toBeUndefined(); }); - it('should not support boolean arguments', async () => { - const mongoServer = new MongoMemoryServer(); - - try { - await mongoServer.cleanup( - // @ts-expect-error Testing a non-existing overload - true - ); - fail('Expected to fail'); - } catch (err) { - expect(err).toBeInstanceOf(Error); - assertIsError(err); - expect(err.message).toMatchSnapshot(); - } - }); - it('should properly cleanup with tmpDir with default no force (new)', async () => { const mongoServer = await MongoMemoryServer.create(); const dbPath = mongoServer.instanceInfo!.dbPath; @@ -1183,4 +1292,73 @@ describe('MongoMemoryServer', () => { await server.stop(); }); }); + + describe('asyncDispose', () => { + it('should work by default', async () => { + jest.spyOn(MongoMemoryServer.prototype, 'start'); + jest.spyOn(MongoMemoryServer.prototype, 'stop'); + let outer; + // would like to test this, but jest seemingly does not support spying on symbols + // jest.spyOn(MongoMemoryServer.prototype, Symbol.asyncDispose); + { + await using server = await MongoMemoryServer.create(); + // use the value and test that it actually runs, as "getUri" will throw is not in "running" state + server.getUri(); + // reassignment still calls dispose at the *current* scope + outer = server; + } + // not "stopped" because of cleanup + expect(outer.state).toStrictEqual(MongoMemoryServerStates.new); + expect(MongoMemoryServer.prototype.start).toHaveBeenCalledTimes(1); + expect(MongoMemoryServer.prototype.stop).toHaveBeenCalledTimes(1); + // expect(MongoMemoryServer.prototype[Symbol.asyncDispose]).toHaveBeenCalledTimes(1); + }); + + it('should be able to be disabled', async () => { + jest.spyOn(MongoMemoryServer.prototype, 'start'); + jest.spyOn(MongoMemoryServer.prototype, 'stop'); + let outer; + // would like to test this, but jest seemingly does not support spying on symbols + // jest.spyOn(MongoMemoryServer.prototype, Symbol.asyncDispose); + { + await using server = await MongoMemoryServer.create({ dispose: { enabled: false } }); + // use the value and test that it actually runs, as "getUri" will throw is not in "running" state + server.getUri(); + // reassignment still calls dispose at the *current* scope + outer = server; + } + expect(outer.state).toStrictEqual(MongoMemoryServerStates.running); + expect(MongoMemoryServer.prototype.start).toHaveBeenCalledTimes(1); + expect(MongoMemoryServer.prototype.stop).toHaveBeenCalledTimes(0); + // expect(MongoMemoryServer.prototype[Symbol.asyncDispose]).toHaveBeenCalledTimes(1); + await outer.stop(); + // not "stopped" because of cleanup + expect(outer.state).toStrictEqual(MongoMemoryServerStates.new); + }); + + it('should be able to set custom cleanup', async () => { + jest.spyOn(MongoMemoryServer.prototype, 'start'); + jest.spyOn(MongoMemoryServer.prototype, 'stop'); + let outer; + // would like to test this, but jest seemingly does not support spying on symbols + // jest.spyOn(MongoMemoryServer.prototype, Symbol.asyncDispose); + { + await using server = await MongoMemoryServer.create({ + dispose: { cleanup: { doCleanup: false } }, + }); + // use the value and test that it actually runs, as "getUri" will throw is not in "running" state + server.getUri(); + // reassignment still calls dispose at the *current* scope + outer = server; + } + // not "stopped" because of cleanup + expect(outer.state).toStrictEqual(MongoMemoryServerStates.stopped); + expect(MongoMemoryServer.prototype.start).toHaveBeenCalledTimes(1); + expect(MongoMemoryServer.prototype.stop).toHaveBeenCalledTimes(1); + // expect(MongoMemoryServer.prototype[Symbol.asyncDispose]).toHaveBeenCalledTimes(1); + await outer.cleanup({ doCleanup: true }); + // not "stopped" because of cleanup + expect(outer.state).toStrictEqual(MongoMemoryServerStates.new); + }); + }); }); diff --git a/packages/mongodb-memory-server-core/src/__tests__/__snapshots__/MongoMemoryReplSet.test.ts.snap b/packages/mongodb-memory-server-core/src/__tests__/__snapshots__/MongoMemoryReplSet.test.ts.snap index 2f56aa611..a66bd6fc0 100644 --- a/packages/mongodb-memory-server-core/src/__tests__/__snapshots__/MongoMemoryReplSet.test.ts.snap +++ b/packages/mongodb-memory-server-core/src/__tests__/__snapshots__/MongoMemoryReplSet.test.ts.snap @@ -2,10 +2,6 @@ exports[`MongoMemoryReplSet "_waitForPrimary" should throw an error if timeout is reached 1`] = `"{\\"timeout\\":1}"`; -exports[`MongoMemoryReplSet .cleanup() should not support boolean arguments 1`] = `"Unsupported argument type: boolean"`; - -exports[`MongoMemoryReplSet .stop() should not support boolean arguments 1`] = `"Unsupported argument type: boolean"`; - exports[`MongoMemoryReplSet getters & setters setter of "replSetOpts" should throw an error if count is 1 or above 1`] = `"ReplSet Count needs to be 1 or higher! (specified count: \\"0\\")"`; exports[`MongoMemoryReplSet getters & setters state errors setter of "binaryOpts" should throw an error if state is not "stopped" 1`] = ` diff --git a/packages/mongodb-memory-server-core/src/__tests__/__snapshots__/MongoMemoryServer.test.ts.snap b/packages/mongodb-memory-server-core/src/__tests__/__snapshots__/MongoMemoryServer.test.ts.snap index 075bff64b..3ebe59376 100644 --- a/packages/mongodb-memory-server-core/src/__tests__/__snapshots__/MongoMemoryServer.test.ts.snap +++ b/packages/mongodb-memory-server-core/src/__tests__/__snapshots__/MongoMemoryServer.test.ts.snap @@ -2,12 +2,6 @@ exports[`MongoMemoryServer "createAuth" should throw an error if called without "this.auth" defined 1`] = `"\\"createAuth\\" got called, but \\"this.auth\\" is undefined!"`; -exports[`MongoMemoryServer cleanup() should not support boolean arguments 1`] = ` -"Incorrect State for operation: \\"new\\", allowed States: \\"[stopped]\\" -This may be because of using a v6.x way of calling functions, look at the following guide if anything applies: -https://typegoose.github.io/mongodb-memory-server/docs/guides/migration/migrate7#no-function-other-than-start-create-ensureinstance-will-be-starting-anything" -`; - exports[`MongoMemoryServer cleanup() should throw an error if state is not "stopped" 1`] = ` "Incorrect State for operation: \\"new\\", allowed States: \\"[stopped]\\" This may be because of using a v6.x way of calling functions, look at the following guide if anything applies: @@ -53,6 +47,10 @@ This warning is because the mentioned storage engine is explicitly used and mong ] `; +exports[`MongoMemoryServer start() instance.portGeneration should Error if a predefined port is already in use if "opts.instance.portGeneration" is "false" 1`] = `[Error: Port "30002" already in use]`; + +exports[`MongoMemoryServer start() instance.portGeneration should overwrite "opts.instance.portGeneration" if "forceSamePort" is set ("forceSamePort true" case) 1`] = `[Error: Port "30004" already in use]`; + exports[`MongoMemoryServer start() should throw an error if state is not "new" or "stopped" 1`] = ` "Incorrect State for operation: \\"starting\\", allowed States: \\"[new,stopped]\\" This may be because of using a v6.x way of calling functions, look at the following guide if anything applies: @@ -64,5 +62,3 @@ exports[`MongoMemoryServer start() should throw an error if state is not "new" o This may be because of using a v6.x way of calling functions, look at the following guide if anything applies: https://typegoose.github.io/mongodb-memory-server/docs/guides/migration/migrate7#no-function-other-than-start-create-ensureinstance-will-be-starting-anything" `; - -exports[`MongoMemoryServer stop() should not support boolean arguments 1`] = `"Unsupported argument type: boolean"`; diff --git a/packages/mongodb-memory-server-core/src/__tests__/testUtils/globalSetup.ts b/packages/mongodb-memory-server-core/src/__tests__/testUtils/globalSetup.ts index 5791dd731..924553385 100644 --- a/packages/mongodb-memory-server-core/src/__tests__/testUtils/globalSetup.ts +++ b/packages/mongodb-memory-server-core/src/__tests__/testUtils/globalSetup.ts @@ -5,7 +5,7 @@ import { assertion, isNullOrUndefined } from '../../util/utils'; export = async function globalSetup(): Promise { const defaultVersion = resolveConfig(ResolveConfigVariables.VERSION); assertion(!isNullOrUndefined(defaultVersion), new Error('Default version is not defined')); - const versions = [defaultVersion, '4.0.28', '4.2.24', '4.4.28', '5.0.19', '6.0.14', '7.0.7']; + const versions = [defaultVersion, '4.0.28', '4.2.24', '4.4.28', '5.0.19', '6.0.14', '7.0.11']; // Ensure all required versions are downloaded for tests for (const version of versions) { await MongoBinary.getPath({ version }); diff --git a/packages/mongodb-memory-server-core/src/index.ts b/packages/mongodb-memory-server-core/src/index.ts index c8313b06b..8a1a72eb9 100644 --- a/packages/mongodb-memory-server-core/src/index.ts +++ b/packages/mongodb-memory-server-core/src/index.ts @@ -1,9 +1,11 @@ import './util/resolveConfig'; // import it for the side-effects (globals) import { MongoMemoryServer } from './MongoMemoryServer'; +export { DryMongoBinary } from './util/DryMongoBinary'; export { MongoBinary } from './util/MongoBinary'; export { MongoInstance } from './util/MongoInstance'; export { MongoMemoryReplSet } from './MongoMemoryReplSet'; +export * as errors from './util/errors'; export { MongoMemoryServer }; export default MongoMemoryServer; diff --git a/packages/mongodb-memory-server-core/src/util/MongoBinaryDownloadUrl.ts b/packages/mongodb-memory-server-core/src/util/MongoBinaryDownloadUrl.ts index c780d0e15..2d2fa1779 100644 --- a/packages/mongodb-memory-server-core/src/util/MongoBinaryDownloadUrl.ts +++ b/packages/mongodb-memory-server-core/src/util/MongoBinaryDownloadUrl.ts @@ -481,14 +481,14 @@ export class MongoBinaryDownloadUrl implements MongoBinaryDownloadUrlOpts { 19: '18.04', 20: '20.04', 21: '22.04', + 22: '24.04', }; ubuntuOS = { os: 'linux', dist: 'ubuntu', release: - // TODO: next-minor: change default mint release to 21 - mintToUbuntuRelease[parseInt(os.release.split('.')[0])] || mintToUbuntuRelease[20], + mintToUbuntuRelease[parseInt(os.release.split('.')[0])] || mintToUbuntuRelease[21], }; } @@ -503,13 +503,13 @@ export class MongoBinaryDownloadUrl implements MongoBinaryDownloadUrlOpts { // untangle elemenatary versioning from hell https://en.wikipedia.org/wiki/Elementary_OS#Development const [elementaryMajor, elementaryMinor] = os.release.split('.').map((el) => parseInt(el)); + // versions below 5.0 were named 0.X, and so use the minor version if major is 0 const realMajor = elementaryMajor || elementaryMinor; ubuntuOS = { os: 'linux', dist: 'ubuntu', - // TODO: next-minor: change default elemenatry release to 7 - release: elementaryToUbuntuRelease[realMajor] || elementaryToUbuntuRelease[6], + release: elementaryToUbuntuRelease[realMajor] || elementaryToUbuntuRelease[7], }; } } @@ -588,7 +588,7 @@ export class MongoBinaryDownloadUrl implements MongoBinaryDownloadUrlOpts { * Highest ubuntu year supported by mongodb binaries * @see https://www.mongodb.com/download-center/community/releases/archive */ - const highestUbuntuYear = 22; // 22 is the highest supported as of mongodb 7.0.4 + const highestUbuntuYear = 22; // 22 is the highest supported as of mongodb 7.0.11 if (ubuntuYear > highestUbuntuYear) { log( diff --git a/packages/mongodb-memory-server-core/src/util/MongoInstance.ts b/packages/mongodb-memory-server-core/src/util/MongoInstance.ts index 4ff3ce76b..b8ce98211 100644 --- a/packages/mongodb-memory-server-core/src/util/MongoInstance.ts +++ b/packages/mongodb-memory-server-core/src/util/MongoInstance.ts @@ -24,8 +24,8 @@ import { // ignore the nodejs warning for coverage /* istanbul ignore next */ -if (lt(process.version, '14.20.1')) { - console.warn('Using NodeJS below 14.20.1'); +if (lt(process.version, '16.20.1')) { + console.warn('Using NodeJS below 16.20.1'); } const log = debug('MongoMS:MongoInstance'); @@ -200,6 +200,7 @@ export interface MongodOpts { spawn: SpawnOptions; } +// eslint-disable-next-line @typescript-eslint/no-unsafe-declaration-merging export interface MongoInstance extends EventEmitter { // Overwrite EventEmitter's definitions (to provide at least the event names) emit(event: MongoInstanceEvents, ...args: any[]): boolean; @@ -211,6 +212,7 @@ export interface MongoInstance extends EventEmitter { * MongoDB Instance Handler Class * This Class starts & stops the "mongod" process directly and handles stdout, sterr and close events */ +// eslint-disable-next-line @typescript-eslint/no-unsafe-declaration-merging export class MongoInstance extends EventEmitter implements ManagerBase { // Mark these values as "readonly" & "Readonly" because modifying them after starting will have no effect // readonly is required otherwise the property can still be changed on the root level @@ -723,6 +725,11 @@ export class MongoInstance extends EventEmitter implements ManagerBase { ); } } + + /// Symbol for "Explicit Resource Management" + async [Symbol.asyncDispose]() { + await this.stop(); + } } export default MongoInstance; diff --git a/packages/mongodb-memory-server-core/src/util/__tests__/MongoBinaryDownloadUrl.test.ts b/packages/mongodb-memory-server-core/src/util/__tests__/MongoBinaryDownloadUrl.test.ts index 6c29fb5d3..029de5692 100644 --- a/packages/mongodb-memory-server-core/src/util/__tests__/MongoBinaryDownloadUrl.test.ts +++ b/packages/mongodb-memory-server-core/src/util/__tests__/MongoBinaryDownloadUrl.test.ts @@ -145,6 +145,26 @@ describe('MongoBinaryDownloadUrl', () => { describe('for linux', () => { describe('for ubuntu', () => { + it('should default to Ubuntu 22.04, if version cannot be parsed', async () => { + const spy = jest.spyOn(console, 'warn').mockImplementationOnce(() => void 0); + // TODO: try to keep this up-to-date to the latest mongodb supported ubuntu version + const du = new MongoBinaryDownloadUrl({ + platform: 'linux', + arch: 'x64', + version: '7.0.4', + os: { + os: 'linux', + dist: 'ubuntu', + release: '', + }, + }); + expect(await du.getDownloadUrl()).toBe( + 'https://fastdl.mongodb.org/linux/mongodb-linux-x86_64-ubuntu2204-7.0.4.tgz' + ); + expect(console.warn).toHaveBeenCalledTimes(1); + expect(spy.mock.calls).toMatchSnapshot(); + }); + it('for ubuntu 14.04 for 3.6', async () => { const du = new MongoBinaryDownloadUrl({ platform: 'linux', @@ -336,7 +356,7 @@ describe('MongoBinaryDownloadUrl', () => { os: { os: 'linux', dist: 'ubuntu', - release: '23.04', // highest released ubuntu version + release: '24.04', // highest released ubuntu version }, }); expect(await du.getDownloadUrl()).toBe( @@ -892,6 +912,25 @@ describe('MongoBinaryDownloadUrl', () => { }); describe('for elementary', () => { + it('should default to Elementary 7, if version cannot be found in lookup table', async () => { + const du = new MongoBinaryDownloadUrl({ + platform: 'linux', + arch: 'x64', + version: '6.0.4', + os: { + os: 'linux', + dist: 'elementary', + codename: 'horus', + release: '0', + id_like: ['ubuntu'], + }, + }); + + expect(await du.getDownloadUrl()).toBe( + 'https://fastdl.mongodb.org/linux/mongodb-linux-x86_64-ubuntu2204-6.0.4.tgz' + ); + }); + it('should return a archive name for elementary 0.3', async () => { const du = new MongoBinaryDownloadUrl({ platform: 'linux', @@ -985,11 +1024,11 @@ describe('MongoBinaryDownloadUrl', () => { }); }); - it('should default to Mint Version 20, if version cannot be found in lookup table', async () => { + it('should default to Mint Version 21, if version cannot be found in lookup table', async () => { (downloadUrl.os as LinuxOS).release = '16'; // out-of-range version downloadUrl.version = '6.0.4'; expect(await downloadUrl.getDownloadUrl()).toBe( - 'https://fastdl.mongodb.org/linux/mongodb-linux-x86_64-ubuntu2004-6.0.4.tgz' + 'https://fastdl.mongodb.org/linux/mongodb-linux-x86_64-ubuntu2204-6.0.4.tgz' ); }); @@ -1032,6 +1071,15 @@ describe('MongoBinaryDownloadUrl', () => { 'https://fastdl.mongodb.org/linux/mongodb-linux-x86_64-ubuntu2204-6.0.4.tgz' ); }); + + it('should return a archive name for Linux Mint 21', async () => { + (downloadUrl.os as LinuxOS).release = '22'; + downloadUrl.version = '7.0.11'; + // NOTE: there are currently no binaries for ubuntu 24.04, but 22.04 still work + expect(await downloadUrl.getDownloadUrl()).toBe( + 'https://fastdl.mongodb.org/linux/mongodb-linux-x86_64-ubuntu2204-7.0.11.tgz' + ); + }); }); describe('for fedora', () => { diff --git a/packages/mongodb-memory-server-core/src/util/__tests__/MongoInstance.test.ts b/packages/mongodb-memory-server-core/src/util/__tests__/MongoInstance.test.ts index 525b2b246..2823d480a 100644 --- a/packages/mongodb-memory-server-core/src/util/__tests__/MongoInstance.test.ts +++ b/packages/mongodb-memory-server-core/src/util/__tests__/MongoInstance.test.ts @@ -291,7 +291,7 @@ describe('MongodbInstance', () => { }); await mongod.start(); jest.spyOn(MongoClient, 'connect'); - process.kill(mongod.mongodProcess!.pid, 'SIGKILL'); + process.kill(mongod.mongodProcess!.pid!, 'SIGKILL'); // loop until the mongod process actually exits while (dbUtil.isAlive(mongod.mongodProcess!.pid)) { await new Promise((resolve) => setTimeout(resolve, 5)); @@ -324,7 +324,7 @@ describe('MongodbInstance', () => { jest.spyOn(MongoClient, 'connect'); jest.spyOn(MongoClient.prototype, 'db'); jest.spyOn(console, 'warn').mockImplementationOnce(() => void 0); - process.kill(mongod.mongodProcess!.pid, 'SIGKILL'); + process.kill(mongod.mongodProcess!.pid!, 'SIGKILL'); // loop until the mongod process actually exits while (dbUtil.isAlive(mongod.mongodProcess!.pid)) { await new Promise((resolve) => setTimeout(resolve, 5)); @@ -780,4 +780,28 @@ describe('MongodbInstance', () => { await mongod.stop(); } }); + + describe('asyncDispose', () => { + it('should work', async () => { + jest.spyOn(MongodbInstance.prototype, 'start'); + jest.spyOn(MongodbInstance.prototype, 'stop'); + let outer; + // would like to test this, but jest seemingly does not support spying on symbols + // jest.spyOn(MongodbInstance.prototype, Symbol.asyncDispose); + { + const gotPort = await getFreePort(27333); + await using server = await MongodbInstance.create({ + instance: { port: gotPort, dbPath: tmpDir }, + binary: { version }, + }); + expect(server.mongodProcess).toBeTruthy(); + // reassignment still calls dispose at the *current* scope + outer = server; + } + expect(outer.mongodProcess).not.toBeTruthy(); + expect(MongodbInstance.prototype.start).toHaveBeenCalledTimes(1); + expect(MongodbInstance.prototype.stop).toHaveBeenCalledTimes(1); + // expect(MongodbInstance.prototype[Symbol.asyncDispose]).toHaveBeenCalledTimes(1); + }); + }); }); diff --git a/packages/mongodb-memory-server-core/src/util/__tests__/__snapshots__/MongoBinaryDownloadUrl.test.ts.snap b/packages/mongodb-memory-server-core/src/util/__tests__/__snapshots__/MongoBinaryDownloadUrl.test.ts.snap index 2c1bce9ba..9d33b3ce4 100644 --- a/packages/mongodb-memory-server-core/src/util/__tests__/__snapshots__/MongoBinaryDownloadUrl.test.ts.snap +++ b/packages/mongodb-memory-server-core/src/util/__tests__/__snapshots__/MongoBinaryDownloadUrl.test.ts.snap @@ -36,6 +36,14 @@ exports[`MongoBinaryDownloadUrl getDownloadUrl() for linux for rhel should Error exports[`MongoBinaryDownloadUrl getDownloadUrl() for linux for rhel should throw a Error when the provided version could not be coerced [UnknownVersionError] 1`] = `"Could not coerce VERSION to a semver version (version: \\"vvv\\")"`; +exports[`MongoBinaryDownloadUrl getDownloadUrl() for linux for ubuntu should default to Ubuntu 22.04, if version cannot be parsed 1`] = ` +Array [ + Array [ + "Could not parse ubuntu year from \\"\\", using default", + ], +] +`; + exports[`MongoBinaryDownloadUrl getDownloadUrl() for linux for ubuntu should throw a Error when the provided version could not be coerced [UnknownVersionError] 1`] = `"Could not coerce VERSION to a semver version (version: \\"vvv\\")"`; exports[`MongoBinaryDownloadUrl getDownloadUrl() should throw an error if platform is unknown (getArchiveName) 1`] = `"Unknown Platform: \\"unknown\\""`; diff --git a/packages/mongodb-memory-server-core/src/util/getport/__tests__/getport.test.ts b/packages/mongodb-memory-server-core/src/util/getport/__tests__/getport.test.ts index 0e2736033..19d5ed40e 100644 --- a/packages/mongodb-memory-server-core/src/util/getport/__tests__/getport.test.ts +++ b/packages/mongodb-memory-server-core/src/util/getport/__tests__/getport.test.ts @@ -1,9 +1,4 @@ -import resolveConfig, { - ResolveConfigVariables, - defaultValues, - envToBool, - setDefaultValue, -} from '../../resolveConfig'; +import { defaultValues } from '../../resolveConfig'; import * as getPort from '../index'; import * as net from 'node:net'; @@ -71,29 +66,8 @@ describe('getport', () => { await expect(getPort.getFreePort(testPort)).resolves.toStrictEqual(testPort); }); - it('port should be predictable', async () => { - expect(envToBool(resolveConfig(ResolveConfigVariables.EXP_NET0LISTEN))).toStrictEqual(false); - - const testPort = 23232; - await expect(getPort.getFreePort(testPort)).resolves.toStrictEqual(testPort); - - const server = await new Promise((res) => { - const server = net.createServer(); - server.unref(); - server.listen(testPort, () => res(server)); - }); - - const foundPort = await getPort.getFreePort(testPort); - expect(foundPort).toStrictEqual(testPort + 2); // predictable result - - server.close(); - }); - - it('EXP_NET0LISTEN should not be predictable', async () => { - setDefaultValue(ResolveConfigVariables.EXP_NET0LISTEN, 'true'); - expect(envToBool(resolveConfig(ResolveConfigVariables.EXP_NET0LISTEN))).toStrictEqual(true); - - const testPort = 23232; + it('port should not be predictable (net0listen)', async () => { + const testPort = 23233; await expect(getPort.getFreePort(testPort)).resolves.toStrictEqual(testPort); const server = await new Promise((res) => { diff --git a/packages/mongodb-memory-server-core/src/util/getport/index.ts b/packages/mongodb-memory-server-core/src/util/getport/index.ts index 8f6c59583..63f3a5310 100644 --- a/packages/mongodb-memory-server-core/src/util/getport/index.ts +++ b/packages/mongodb-memory-server-core/src/util/getport/index.ts @@ -1,5 +1,3 @@ -import resolveConfig, { ResolveConfigVariables, envToBool } from '../resolveConfig'; -import * as crypto from 'node:crypto'; import * as net from 'node:net'; import debug from 'debug'; @@ -16,8 +14,6 @@ interface IPortsCache { timeSet: undefined | number; /** The ports that were tried */ ports: Set; - /** Store last used number, reduces amount of tries needed */ - lastNumber: number; } /** @@ -32,15 +28,14 @@ const PORTS_CACHE_CLEAN_TIME = 1000 * 10; const PORTS_CACHE: IPortsCache = { timeSet: undefined, ports: new Set(), - lastNumber: MIN_PORT, }; /** Max default tries before giving up */ const MAX_DEFAULT_TRIES = 10; /** - * Try to get a free port - * @param firstPort The first port to try or empty for semi-random port + * Try to get a free port. + * @param firstPort The first port to try or empty for a random port * @param max_tries maximum amount of tries to get a port, default to {@link MAX_DEFAULT_TRIES} * @returns A valid free port * @throws if "max_tries" is exceeded @@ -49,8 +44,8 @@ export async function getFreePort( firstPort?: number, max_tries: number = MAX_DEFAULT_TRIES ): Promise { - // Get a random value from crypto to use as first port if none is given - firstPort = firstPort || validPort(crypto.randomInt(MIN_PORT, MAX_PORT + 1)); + // use "0" as a fallback to use net0listen, which generates a random free port + firstPort = firstPort || 0; // clear ports cache after some time, but not on an interval if (PORTS_CACHE.timeSet && Date.now() - PORTS_CACHE.timeSet > PORTS_CACHE_CLEAN_TIME) { @@ -60,22 +55,12 @@ export async function getFreePort( PORTS_CACHE.timeSet = Date.now(); } - const exp_net0listen = envToBool(resolveConfig(ResolveConfigVariables.EXP_NET0LISTEN)); - log('EXP_NET0LISTEN', exp_net0listen); - let tries = 0; while (tries <= max_tries) { tries += 1; - let nextPort: number; - - if (exp_net0listen) { - // "0" means to use ".listen" random port - nextPort = tries === 1 ? firstPort : 0; - } else { - // use "startPort" at first try, otherwise increase from last number - nextPort = tries === 1 ? firstPort : validPort(PORTS_CACHE.lastNumber + tries); - } + // "0" means to use have ".listen" use a random port + const nextPort = tries === 1 ? firstPort : 0; // try next port, because it is already in the cache // unless port is "0" which will use "net.listen(0)" @@ -84,15 +69,15 @@ export async function getFreePort( } PORTS_CACHE.ports.add(nextPort); - // only set "lastNumber" if the "nextPort" was not in the cache - PORTS_CACHE.lastNumber = nextPort; const triedPort = await tryPort(nextPort); - // returned port can be different than the "nextPort" (if EXP_NET0LISTEN) - PORTS_CACHE.ports.add(nextPort); - if (triedPort > 0) { + log('getFreePort: found free port', triedPort); + + // returned port can be different than the "nextPort" (if net0listen) + PORTS_CACHE.ports.add(nextPort); + return triedPort; } } @@ -103,8 +88,8 @@ export async function getFreePort( export default getFreePort; /** - * Check that input number is within range of {@link MIN_PORT} and {@link MAX_PORT} - * If more than {@link MAX_PORT}, wrap around, if less than {@link MIN_PORT} use {@link MIN_PORT} + * Ensure that input number is within range of {@link MIN_PORT} and {@link MAX_PORT}. + * If more than {@link MAX_PORT}, wrap around, if less than {@link MIN_PORT} use {@link MIN_PORT}. * @param port The Number to check * @returns A Valid number in port range */ @@ -115,9 +100,9 @@ export function validPort(port: number): number { } /** - * Try a given port + * Try a given port. * @param port The port to try - * @returns "true" if the port is not in use, "false" if in use + * @returns the port if successful, "-1" in case of `EADDRINUSE`, all other errors reject * @throws The error given if the code is not "EADDRINUSE" */ export function tryPort(port: number): Promise { @@ -147,12 +132,11 @@ export function tryPort(port: number): Promise { } /** - * Reset the {@link PORTS_CACHE} to its initial state + * Reset the {@link PORTS_CACHE} to its initial state. * - * This function is meant for debugging and testing purposes only + * This function is meant for debugging and testing purposes only. */ export function resetPortsCache() { - PORTS_CACHE.lastNumber = MIN_PORT; PORTS_CACHE.timeSet = undefined; PORTS_CACHE.ports.clear(); } diff --git a/packages/mongodb-memory-server-core/src/util/lockfile.ts b/packages/mongodb-memory-server-core/src/util/lockfile.ts index 189626843..01cf4232f 100644 --- a/packages/mongodb-memory-server-core/src/util/lockfile.ts +++ b/packages/mongodb-memory-server-core/src/util/lockfile.ts @@ -41,6 +41,7 @@ export enum LockFileEvents { unlock = 'unlock', } +// eslint-disable-next-line @typescript-eslint/no-unsafe-declaration-merging interface LockFileEventsClass extends EventEmitter { // Overwrite EventEmitter's definitions (to provide at least the event names) emit(event: LockFileEvents, ...args: any[]): boolean; @@ -49,6 +50,7 @@ interface LockFileEventsClass extends EventEmitter { } /** Dummy class for types */ +// eslint-disable-next-line @typescript-eslint/no-unsafe-declaration-merging class LockFileEventsClass extends EventEmitter {} export class LockFile { diff --git a/packages/mongodb-memory-server-core/src/util/resolveConfig.ts b/packages/mongodb-memory-server-core/src/util/resolveConfig.ts index b150f402e..5db57d7cd 100644 --- a/packages/mongodb-memory-server-core/src/util/resolveConfig.ts +++ b/packages/mongodb-memory-server-core/src/util/resolveConfig.ts @@ -5,6 +5,12 @@ import * as path from 'path'; import { readFileSync } from 'fs'; import { isNullOrUndefined } from './utils'; +// polyfills +// @ts-expect-error they are marked "read-only", but are set-able if not implemented by the runtime +Symbol.dispose ??= Symbol('Symbol.dispose'); +// @ts-expect-error they are marked "read-only", but are set-able if not implemented by the runtime +Symbol.asyncDispose ??= Symbol('Symbol.asyncDispose'); + const log = debug('MongoMS:ResolveConfig'); /** Enum of all possible config options */ @@ -28,13 +34,12 @@ export enum ResolveConfigVariables { USE_ARCHIVE_NAME_FOR_BINARY_NAME = 'USE_ARCHIVE_NAME_FOR_BINARY_NAME', MAX_REDIRECTS = 'MAX_REDIRECTS', DISTRO = 'DISTRO', - EXP_NET0LISTEN = 'EXP_NET0LISTEN', } /** The Prefix for Environmental values */ export const ENV_CONFIG_PREFIX = 'MONGOMS_'; /** This Value exists here, because "defaultValues" can be changed with "setDefaultValue", but this property is constant */ -export const DEFAULT_VERSION = '6.0.14'; +export const DEFAULT_VERSION = '7.0.11'; /** Default values for some config options that require explicit setting, it is constant so that the default values cannot be interfered with */ export const defaultValues = new Map([ // apply app-default values here diff --git a/packages/mongodb-memory-server-core/src/util/utils.ts b/packages/mongodb-memory-server-core/src/util/utils.ts index 9ad5e4650..b01a21c10 100644 --- a/packages/mongodb-memory-server-core/src/util/utils.ts +++ b/packages/mongodb-memory-server-core/src/util/utils.ts @@ -268,6 +268,8 @@ export abstract class ManagerBase { abstract start(forceSamePort: boolean): Promise; abstract start(): Promise; abstract stop(cleanup: Cleanup): Promise; + // Symbol for "Explicit Resource Management" + abstract [Symbol.asyncDispose](): Promise; } /** diff --git a/packages/mongodb-memory-server-core/tsconfig.json b/packages/mongodb-memory-server-core/tsconfig.json index 9cf16a145..210ef1d5e 100644 --- a/packages/mongodb-memory-server-core/tsconfig.json +++ b/packages/mongodb-memory-server-core/tsconfig.json @@ -3,7 +3,7 @@ "rootDir": "./src", "outDir": "./build", "noEmit": false, - "target": "es2020", + "target": "es2021", "module": "commonjs", "sourceMap": true, "declaration": true, diff --git a/packages/mongodb-memory-server-global-4.0/package.json b/packages/mongodb-memory-server-global-4.0/package.json index a64675164..072a2ea86 100644 --- a/packages/mongodb-memory-server-global-4.0/package.json +++ b/packages/mongodb-memory-server-global-4.0/package.json @@ -1,6 +1,6 @@ { "name": "mongodb-memory-server-global-4.0", - "version": "9.4.1", + "version": "10.0.0-beta.5", "mongodb_version": "4.0.28", "description": "MongoDB Server for testing (auto-download 4.0 version to ~/.cache/mongodb-binaries).", "main": "index.js", @@ -12,7 +12,7 @@ "directory": "packages/mongodb-memory-server-global-4.4" }, "engines": { - "node": ">=14.20.1" + "node": ">=16.20.1" }, "homepage": "https://github.com/typegoose/mongodb-memory-server", "keywords": [ @@ -25,7 +25,7 @@ "mongomem" ], "dependencies": { - "mongodb-memory-server-core": "9.4.1", + "mongodb-memory-server-core": "10.0.0-beta.5", "tslib": "^2.6.3" }, "scripts": { diff --git a/packages/mongodb-memory-server-global-4.2/package.json b/packages/mongodb-memory-server-global-4.2/package.json index 487b5bad8..b83cb3db3 100644 --- a/packages/mongodb-memory-server-global-4.2/package.json +++ b/packages/mongodb-memory-server-global-4.2/package.json @@ -1,6 +1,6 @@ { "name": "mongodb-memory-server-global-4.2", - "version": "9.4.1", + "version": "10.0.0-beta.5", "mongodb_version": "4.2.24", "description": "MongoDB Server for testing (auto-download 4.2 version to ~/.cache/mongodb-binaries).", "main": "index.js", @@ -12,7 +12,7 @@ "directory": "packages/mongodb-memory-server-global-4.2" }, "engines": { - "node": ">=14.20.1" + "node": ">=16.20.1" }, "homepage": "https://github.com/typegoose/mongodb-memory-server", "keywords": [ @@ -25,7 +25,7 @@ "mongomem" ], "dependencies": { - "mongodb-memory-server-core": "9.4.1", + "mongodb-memory-server-core": "10.0.0-beta.5", "tslib": "^2.6.3" }, "scripts": { diff --git a/packages/mongodb-memory-server-global-4.4/package.json b/packages/mongodb-memory-server-global-4.4/package.json index 99a892d2f..af9ba6e1c 100644 --- a/packages/mongodb-memory-server-global-4.4/package.json +++ b/packages/mongodb-memory-server-global-4.4/package.json @@ -1,6 +1,6 @@ { "name": "mongodb-memory-server-global-4.4", - "version": "9.4.1", + "version": "10.0.0-beta.5", "mongodb_version": "4.4.28", "description": "MongoDB Server for testing (auto-download 4.4 version to ~/.cache/mongodb-binaries).", "main": "index.js", @@ -12,7 +12,7 @@ "directory": "packages/mongodb-memory-server-global-4.4" }, "engines": { - "node": ">=14.20.1" + "node": ">=16.20.1" }, "homepage": "https://github.com/typegoose/mongodb-memory-server", "keywords": [ @@ -25,7 +25,7 @@ "mongomem" ], "dependencies": { - "mongodb-memory-server-core": "9.4.1", + "mongodb-memory-server-core": "10.0.0-beta.5", "tslib": "^2.6.3" }, "scripts": { diff --git a/packages/mongodb-memory-server-global/package.json b/packages/mongodb-memory-server-global/package.json index 2c3750eee..31d79b78b 100644 --- a/packages/mongodb-memory-server-global/package.json +++ b/packages/mongodb-memory-server-global/package.json @@ -1,6 +1,6 @@ { "name": "mongodb-memory-server-global", - "version": "9.4.1", + "version": "10.0.0-beta.5", "description": "MongoDB Server for testing (auto-download latest version to ~/.cache/mongodb-binaries).", "main": "index.js", "types": "index.d.ts", @@ -11,7 +11,7 @@ "directory": "packages/mongodb-memory-server-global" }, "engines": { - "node": ">=14.20.1" + "node": ">=16.20.1" }, "homepage": "https://github.com/typegoose/mongodb-memory-server", "keywords": [ @@ -24,7 +24,7 @@ "mongomem" ], "dependencies": { - "mongodb-memory-server-core": "9.4.1", + "mongodb-memory-server-core": "10.0.0-beta.5", "tslib": "^2.6.3" }, "scripts": { diff --git a/packages/mongodb-memory-server/package.json b/packages/mongodb-memory-server/package.json index c8e1987b6..ccb160591 100644 --- a/packages/mongodb-memory-server/package.json +++ b/packages/mongodb-memory-server/package.json @@ -1,6 +1,6 @@ { "name": "mongodb-memory-server", - "version": "9.4.1", + "version": "10.0.0-beta.5", "description": "MongoDB Server for testing (auto-download latest version). The server will allow you to connect your favourite ODM or client library to the MongoDB Server and run parallel integration tests isolated from each other.", "main": "index.js", "types": "index.d.ts", @@ -11,7 +11,7 @@ "directory": "packages/mongodb-memory-server" }, "engines": { - "node": ">=14.20.1" + "node": ">=16.20.1" }, "homepage": "https://github.com/typegoose/mongodb-memory-server", "keywords": [ @@ -24,7 +24,7 @@ "mongomem" ], "dependencies": { - "mongodb-memory-server-core": "9.4.1", + "mongodb-memory-server-core": "10.0.0-beta.5", "tslib": "^2.6.3" }, "scripts": { diff --git a/website/docusaurus.config.js b/website/docusaurus.config.js index e7bac7ce6..ffc400e0c 100644 --- a/website/docusaurus.config.js +++ b/website/docusaurus.config.js @@ -13,8 +13,7 @@ if (!baseUrl.endsWith('/')) { module.exports = { title: 'mongodb-memory-server', - tagline: - 'Spinning up mongod in memory for fast tests. If you run tests in parallel this lib helps to spin up dedicated mongodb servers for every test file in MacOS, *nix, Windows or CI environments (in most cases with zero-config).', + tagline: 'Manage & spin up mongodb server binaries with zero(or slight) configuration for tests.', url: 'https://typegoose.github.io', baseUrl: baseUrl, favicon: 'img/favicon.ico', diff --git a/website/sidebars.js b/website/sidebars.js index b1df2b6d4..de3327ed0 100644 --- a/website/sidebars.js +++ b/website/sidebars.js @@ -17,6 +17,7 @@ module.exports = { 'api/interfaces/mongo-memory-instance-replicamemberconfig', 'api/interfaces/mongo-memory-binary-opts', 'api/interfaces/mongo-memory-replset-opts', + 'api/interfaces/mongo-memory-dispose-opts', 'api/interfaces/replset-opts', ], }, @@ -41,6 +42,7 @@ module.exports = { 'guides/common-issues', ], Migration: [ + 'guides/migration/migrate10', 'guides/migration/migrate9', 'guides/migration/migrate8', 'guides/migration/migrate7', diff --git a/website/src/pages/index.js b/website/src/pages/index.js index 1c32bcb82..12e877aa5 100644 --- a/website/src/pages/index.js +++ b/website/src/pages/index.js @@ -10,18 +10,28 @@ import styles from './styles.module.css'; const features = [ { title: 'Easy to Use', - description: <>mongodb-memory-server was build with "easy-to-use" in mind, + description: ( + <> + mongodb-memory-server was build with "easy-to-use" in mind and is in most common systems + zero-configuration. (except setting a custom mongodb version) + + ), }, { - title: 'Focus on What Matters', - description: <>mongodb-memory-server can be quickly added to projects on many systems, + title: 'Supports all MongoDB supports systems', + description: ( + <> + mongodb-memory-server supporst all systems there are mongodb binaries are for, including + some unofficial environments where some other binary works. + + ), }, { - title: 'Supports Many Systems', + title: 'Supports both Single-Instance and Replica Sets', description: ( <> - mongodb-memory-server supports many different systems without problems (exceptions are some - linux distributions) + mongodb-memory-server can be quickly used with single mongodb instances or spin up a entire + replicaset. ), }, @@ -59,7 +69,7 @@ function Home() { 'button button--outline button--secondary button--lg', styles.getStarted )} - to={useBaseUrl('docs/')} + to={useBaseUrl('docs/guides/quick-start-guide')} > Get Started diff --git a/yarn.lock b/yarn.lock index 6bbf5d6e1..33d787672 100644 --- a/yarn.lock +++ b/yarn.lock @@ -470,17 +470,17 @@ dependencies: "@jridgewell/trace-mapping" "0.3.9" -"@eslint-community/eslint-utils@^4.2.0": +"@eslint-community/eslint-utils@^4.2.0", "@eslint-community/eslint-utils@^4.4.0": version "4.4.0" resolved "https://registry.yarnpkg.com/@eslint-community/eslint-utils/-/eslint-utils-4.4.0.tgz#a23514e8fb9af1269d5f7788aa556798d61c6b59" integrity sha512-1/sA4dwrzBAyeUoQ6oxahHKmrZvsnLCg4RfxW3ZFGGmQkSNQPFNLV9CUEFQP1x9EYXHTo5p6xdhZM1Ne9p/AfA== dependencies: eslint-visitor-keys "^3.3.0" -"@eslint-community/regexpp@^4.4.0", "@eslint-community/regexpp@^4.6.1": - version "4.9.1" - resolved "https://registry.yarnpkg.com/@eslint-community/regexpp/-/regexpp-4.9.1.tgz#449dfa81a57a1d755b09aa58d826c1262e4283b4" - integrity sha512-Y27x+MBLjXa+0JWDhykM3+JE+il3kHKAEqabfEWq3SDhZjLYb6/BHL/JKFnH3fe207JaXkyDo685Oc2Glt6ifA== +"@eslint-community/regexpp@^4.5.1", "@eslint-community/regexpp@^4.6.1": + version "4.10.1" + resolved "https://registry.yarnpkg.com/@eslint-community/regexpp/-/regexpp-4.10.1.tgz#361461e5cb3845d874e61731c11cfedd664d83a0" + integrity sha512-Zm2NGpWELsQAD1xsJzGQpYfvICSsFkEpU0jxBjfdC6uNEWXcHnfs9hScFWtXVDVl+rBQJGrl4g1vcKIejpH9dA== "@eslint/eslintrc@^2.1.4": version "2.1.4" @@ -781,7 +781,7 @@ "@jridgewell/resolve-uri" "^3.1.0" "@jridgewell/sourcemap-codec" "^1.4.14" -"@mongodb-js/saslprep@^1.1.0": +"@mongodb-js/saslprep@^1.1.5": version "1.1.7" resolved "https://registry.yarnpkg.com/@mongodb-js/saslprep/-/saslprep-1.1.7.tgz#d1700facfd6916c50c2c88fd6d48d363a56c702f" integrity sha512-dCHW/oEX0KJ4NjDULBo3JiOaK5+6axtpBbS+ao2ZInoAL9/YRQLhXzSNAFz7hP4nzLkIqsfYAK/PDE3+XHny0Q== @@ -964,10 +964,10 @@ expect "^29.0.0" pretty-format "^29.0.0" -"@types/json-schema@^7.0.9": - version "7.0.13" - resolved "https://registry.yarnpkg.com/@types/json-schema/-/json-schema-7.0.13.tgz#02c24f4363176d2d18fc8b70b9f3c54aba178a85" - integrity sha512-RbSSoHliUbnXj3ny0CNFOoxrIDV6SUGyStHsvDqosw6CkdPV8TtWGlfecuK4ToyMEAql6pzNxgCFKanovUzlgQ== +"@types/json-schema@^7.0.12": + version "7.0.15" + resolved "https://registry.yarnpkg.com/@types/json-schema/-/json-schema-7.0.15.tgz#596a1747233694d50f6ad8a7869fcb6f56cf5841" + integrity sha512-5+fP8P8MFNC+AyZCDxrB2pkZFPGzqQWUzpSeuuVLvm8VMcorNYavBqoFcxK8bQz4Qsbn4oUEEem4wDLfcysGHA== "@types/mdast@^3.0.0": version "3.0.13" @@ -998,22 +998,17 @@ resolved "https://registry.yarnpkg.com/@types/node/-/node-20.5.1.tgz#178d58ee7e4834152b0e8b4d30cbfab578b9bb30" integrity sha512-4tT2UrL5LBqDwoed9wZ6N3umC4Yhz3W3FloMmiiG4JwmUJWpie0c7lcnUNd4gtMKuDEO4wRVS8B6Xa0uMRsMKg== -"@types/node@~14.18.63": - version "14.18.63" - resolved "https://registry.yarnpkg.com/@types/node/-/node-14.18.63.tgz#1788fa8da838dbb5f9ea994b834278205db6ca2b" - integrity sha512-fAtCfv4jJg+ExtXhvCkCqUKZ+4ok/JQk01qDKhL5BDDoS3AxKXhV5/MAVUZyQnSEd2GT92fkgZl0pz0Q0AzcIQ== +"@types/node@~16.11.7": + version "16.11.68" + resolved "https://registry.yarnpkg.com/@types/node/-/node-16.11.68.tgz#30ee923f4d940793e0380f5ce61c0bd4b7196b6c" + integrity sha512-JkRpuVz3xCNCWaeQ5EHLR/6woMbHZz/jZ7Kmc63AkU+1HxnoUugzSWMck7dsR4DvNYX8jp9wTi9K7WvnxOIQZQ== "@types/normalize-package-data@^2.4.0": version "2.4.2" resolved "https://registry.yarnpkg.com/@types/normalize-package-data/-/normalize-package-data-2.4.2.tgz#9b0e3e8533fe5024ad32d6637eb9589988b6fdca" integrity sha512-lqa4UEhhv/2sjjIQgjX8B+RBjj47eo0mzGasklVJ78UKGQY1r0VpB9XHDaZZO9qzEFDdy4MrXLuEaSmPrPSe/A== -"@types/semver@^7.3.12": - version "7.5.3" - resolved "https://registry.yarnpkg.com/@types/semver/-/semver-7.5.3.tgz#9a726e116beb26c24f1ccd6850201e1246122e04" - integrity sha512-OxepLK9EuNEIPxWNME+C6WwbRAOOI2o2BaQEGzz5Lu2e4Z5eDnEo+/aVEDMIXywoJitJ7xWd641wrGLZdtwRyw== - -"@types/semver@^7.5.8": +"@types/semver@^7.5.0", "@types/semver@^7.5.8": version "7.5.8" resolved "https://registry.yarnpkg.com/@types/semver/-/semver-7.5.8.tgz#8268a8c57a3e4abd25c165ecd36237db7948a55e" integrity sha512-I8EUhyrgfLrcTkzV3TSsGyl1tSuPrEDzr0yd5m90UgNxQkyDXULk3b6MlQqTCpZpNtWe1K0hzclnZkTcLBe2UQ== @@ -1040,12 +1035,11 @@ resolved "https://registry.yarnpkg.com/@types/webidl-conversions/-/webidl-conversions-7.0.3.tgz#1306dbfa53768bcbcfc95a1c8cde367975581859" integrity sha512-CiJJvcRtIgzadHCYXw7dqEnMNRjhGZlYK05Mj9OyktqV8uVT8fD2BFOB7S1uwBE3Kj2Z+4UyPmFw/Ixgw/LAlA== -"@types/whatwg-url@^8.2.1": - version "8.2.2" - resolved "https://registry.yarnpkg.com/@types/whatwg-url/-/whatwg-url-8.2.2.tgz#749d5b3873e845897ada99be4448041d4cc39e63" - integrity sha512-FtQu10RWgn3D9U4aazdwIE2yzphmTJREDqNdODHrbrZmmMqI0vMheC/6NE/J1Yveaj8H+ela+YwWTjq5PGmuhA== +"@types/whatwg-url@^11.0.2": + version "11.0.5" + resolved "https://registry.yarnpkg.com/@types/whatwg-url/-/whatwg-url-11.0.5.tgz#aaa2546e60f0c99209ca13360c32c78caf2c409f" + integrity sha512-coYR071JRaHa+xoEvvYqvnIHaVqaYrLPbsufM9BF63HkwI5Lgmy2QR8Q5K/lYDYo5AK82wOvSOS0UsLTpTG7uQ== dependencies: - "@types/node" "*" "@types/webidl-conversions" "*" "@types/yargs-parser@*": @@ -1074,89 +1068,91 @@ dependencies: "@types/node" "*" -"@typescript-eslint/eslint-plugin@5.59.9": - version "5.59.9" - resolved "https://registry.yarnpkg.com/@typescript-eslint/eslint-plugin/-/eslint-plugin-5.59.9.tgz#2604cfaf2b306e120044f901e20c8ed926debf15" - integrity sha512-4uQIBq1ffXd2YvF7MAvehWKW3zVv/w+mSfRAu+8cKbfj3nwzyqJLNcZJpQ/WZ1HLbJDiowwmQ6NO+63nCA+fqA== +"@typescript-eslint/eslint-plugin@6.21.0": + version "6.21.0" + resolved "https://registry.yarnpkg.com/@typescript-eslint/eslint-plugin/-/eslint-plugin-6.21.0.tgz#30830c1ca81fd5f3c2714e524c4303e0194f9cd3" + integrity sha512-oy9+hTPCUFpngkEZUSzbf9MxI65wbKFoQYsgPdILTfbUldp5ovUuphZVe4i30emU9M/kP+T64Di0mxl7dSw3MA== dependencies: - "@eslint-community/regexpp" "^4.4.0" - "@typescript-eslint/scope-manager" "5.59.9" - "@typescript-eslint/type-utils" "5.59.9" - "@typescript-eslint/utils" "5.59.9" + "@eslint-community/regexpp" "^4.5.1" + "@typescript-eslint/scope-manager" "6.21.0" + "@typescript-eslint/type-utils" "6.21.0" + "@typescript-eslint/utils" "6.21.0" + "@typescript-eslint/visitor-keys" "6.21.0" debug "^4.3.4" - grapheme-splitter "^1.0.4" - ignore "^5.2.0" - natural-compare-lite "^1.4.0" - semver "^7.3.7" - tsutils "^3.21.0" - -"@typescript-eslint/parser@5.59.9": - version "5.59.9" - resolved "https://registry.yarnpkg.com/@typescript-eslint/parser/-/parser-5.59.9.tgz#a85c47ccdd7e285697463da15200f9a8561dd5fa" - integrity sha512-FsPkRvBtcLQ/eVK1ivDiNYBjn3TGJdXy2fhXX+rc7czWl4ARwnpArwbihSOHI2Peg9WbtGHrbThfBUkZZGTtvQ== - dependencies: - "@typescript-eslint/scope-manager" "5.59.9" - "@typescript-eslint/types" "5.59.9" - "@typescript-eslint/typescript-estree" "5.59.9" + graphemer "^1.4.0" + ignore "^5.2.4" + natural-compare "^1.4.0" + semver "^7.5.4" + ts-api-utils "^1.0.1" + +"@typescript-eslint/parser@6.21.0": + version "6.21.0" + resolved "https://registry.yarnpkg.com/@typescript-eslint/parser/-/parser-6.21.0.tgz#af8fcf66feee2edc86bc5d1cf45e33b0630bf35b" + integrity sha512-tbsV1jPne5CkFQCgPBcDOt30ItF7aJoZL997JSF7MhGQqOeT3svWRYxiqlfA5RUdlHN6Fi+EI9bxqbdyAUZjYQ== + dependencies: + "@typescript-eslint/scope-manager" "6.21.0" + "@typescript-eslint/types" "6.21.0" + "@typescript-eslint/typescript-estree" "6.21.0" + "@typescript-eslint/visitor-keys" "6.21.0" debug "^4.3.4" -"@typescript-eslint/scope-manager@5.59.9": - version "5.59.9" - resolved "https://registry.yarnpkg.com/@typescript-eslint/scope-manager/-/scope-manager-5.59.9.tgz#eadce1f2733389cdb58c49770192c0f95470d2f4" - integrity sha512-8RA+E+w78z1+2dzvK/tGZ2cpGigBZ58VMEHDZtpE1v+LLjzrYGc8mMaTONSxKyEkz3IuXFM0IqYiGHlCsmlZxQ== +"@typescript-eslint/scope-manager@6.21.0": + version "6.21.0" + resolved "https://registry.yarnpkg.com/@typescript-eslint/scope-manager/-/scope-manager-6.21.0.tgz#ea8a9bfc8f1504a6ac5d59a6df308d3a0630a2b1" + integrity sha512-OwLUIWZJry80O99zvqXVEioyniJMa+d2GrqpUTqi5/v5D5rOrppJVBPa0yKCblcigC0/aYAzxxqQ1B+DS2RYsg== dependencies: - "@typescript-eslint/types" "5.59.9" - "@typescript-eslint/visitor-keys" "5.59.9" + "@typescript-eslint/types" "6.21.0" + "@typescript-eslint/visitor-keys" "6.21.0" -"@typescript-eslint/type-utils@5.59.9": - version "5.59.9" - resolved "https://registry.yarnpkg.com/@typescript-eslint/type-utils/-/type-utils-5.59.9.tgz#53bfaae2e901e6ac637ab0536d1754dfef4dafc2" - integrity sha512-ksEsT0/mEHg9e3qZu98AlSrONAQtrSTljL3ow9CGej8eRo7pe+yaC/mvTjptp23Xo/xIf2mLZKC6KPv4Sji26Q== +"@typescript-eslint/type-utils@6.21.0": + version "6.21.0" + resolved "https://registry.yarnpkg.com/@typescript-eslint/type-utils/-/type-utils-6.21.0.tgz#6473281cfed4dacabe8004e8521cee0bd9d4c01e" + integrity sha512-rZQI7wHfao8qMX3Rd3xqeYSMCL3SoiSQLBATSiVKARdFGCYSRvmViieZjqc58jKgs8Y8i9YvVVhRbHSTA4VBag== dependencies: - "@typescript-eslint/typescript-estree" "5.59.9" - "@typescript-eslint/utils" "5.59.9" + "@typescript-eslint/typescript-estree" "6.21.0" + "@typescript-eslint/utils" "6.21.0" debug "^4.3.4" - tsutils "^3.21.0" + ts-api-utils "^1.0.1" -"@typescript-eslint/types@5.59.9": - version "5.59.9" - resolved "https://registry.yarnpkg.com/@typescript-eslint/types/-/types-5.59.9.tgz#3b4e7ae63718ce1b966e0ae620adc4099a6dcc52" - integrity sha512-uW8H5NRgTVneSVTfiCVffBb8AbwWSKg7qcA4Ot3JI3MPCJGsB4Db4BhvAODIIYE5mNj7Q+VJkK7JxmRhk2Lyjw== +"@typescript-eslint/types@6.21.0": + version "6.21.0" + resolved "https://registry.yarnpkg.com/@typescript-eslint/types/-/types-6.21.0.tgz#205724c5123a8fef7ecd195075fa6e85bac3436d" + integrity sha512-1kFmZ1rOm5epu9NZEZm1kckCDGj5UJEf7P1kliH4LKu/RkwpsfqqGmY2OOcUs18lSlQBKLDYBOGxRVtrMN5lpg== -"@typescript-eslint/typescript-estree@5.59.9": - version "5.59.9" - resolved "https://registry.yarnpkg.com/@typescript-eslint/typescript-estree/-/typescript-estree-5.59.9.tgz#6bfea844e468427b5e72034d33c9fffc9557392b" - integrity sha512-pmM0/VQ7kUhd1QyIxgS+aRvMgw+ZljB3eDb+jYyp6d2bC0mQWLzUDF+DLwCTkQ3tlNyVsvZRXjFyV0LkU/aXjA== +"@typescript-eslint/typescript-estree@6.21.0": + version "6.21.0" + resolved "https://registry.yarnpkg.com/@typescript-eslint/typescript-estree/-/typescript-estree-6.21.0.tgz#c47ae7901db3b8bddc3ecd73daff2d0895688c46" + integrity sha512-6npJTkZcO+y2/kr+z0hc4HwNfrrP4kNYh57ek7yCNlrBjWQ1Y0OS7jiZTkgumrvkX5HkEKXFZkkdFNkaW2wmUQ== dependencies: - "@typescript-eslint/types" "5.59.9" - "@typescript-eslint/visitor-keys" "5.59.9" + "@typescript-eslint/types" "6.21.0" + "@typescript-eslint/visitor-keys" "6.21.0" debug "^4.3.4" globby "^11.1.0" is-glob "^4.0.3" - semver "^7.3.7" - tsutils "^3.21.0" + minimatch "9.0.3" + semver "^7.5.4" + ts-api-utils "^1.0.1" + +"@typescript-eslint/utils@6.21.0": + version "6.21.0" + resolved "https://registry.yarnpkg.com/@typescript-eslint/utils/-/utils-6.21.0.tgz#4714e7a6b39e773c1c8e97ec587f520840cd8134" + integrity sha512-NfWVaC8HP9T8cbKQxHcsJBY5YE1O33+jpMwN45qzWWaPDZgLIbo12toGMWnmhvCpd3sIxkpDw3Wv1B3dYrbDQQ== + dependencies: + "@eslint-community/eslint-utils" "^4.4.0" + "@types/json-schema" "^7.0.12" + "@types/semver" "^7.5.0" + "@typescript-eslint/scope-manager" "6.21.0" + "@typescript-eslint/types" "6.21.0" + "@typescript-eslint/typescript-estree" "6.21.0" + semver "^7.5.4" -"@typescript-eslint/utils@5.59.9": - version "5.59.9" - resolved "https://registry.yarnpkg.com/@typescript-eslint/utils/-/utils-5.59.9.tgz#adee890107b5ffe02cd46fdaa6c2125fb3c6c7c4" - integrity sha512-1PuMYsju/38I5Ggblaeb98TOoUvjhRvLpLa1DoTOFaLWqaXl/1iQ1eGurTXgBY58NUdtfTXKP5xBq7q9NDaLKg== +"@typescript-eslint/visitor-keys@6.21.0": + version "6.21.0" + resolved "https://registry.yarnpkg.com/@typescript-eslint/visitor-keys/-/visitor-keys-6.21.0.tgz#87a99d077aa507e20e238b11d56cc26ade45fe47" + integrity sha512-JJtkDduxLi9bivAB+cYOVMtbkqdPOhZ+ZI5LC47MIRrDV4Yn2o+ZnW10Nkmr28xRpSpdJ6Sm42Hjf2+REYXm0A== dependencies: - "@eslint-community/eslint-utils" "^4.2.0" - "@types/json-schema" "^7.0.9" - "@types/semver" "^7.3.12" - "@typescript-eslint/scope-manager" "5.59.9" - "@typescript-eslint/types" "5.59.9" - "@typescript-eslint/typescript-estree" "5.59.9" - eslint-scope "^5.1.1" - semver "^7.3.7" - -"@typescript-eslint/visitor-keys@5.59.9": - version "5.59.9" - resolved "https://registry.yarnpkg.com/@typescript-eslint/visitor-keys/-/visitor-keys-5.59.9.tgz#9f86ef8e95aca30fb5a705bb7430f95fc58b146d" - integrity sha512-bT7s0td97KMaLwpEBckbzj/YohnvXtqbe2XgqNvTl6RJVakY5mvENOTPvw5u66nljfZxthESpDozs86U+oLY8Q== - dependencies: - "@typescript-eslint/types" "5.59.9" - eslint-visitor-keys "^3.3.0" + "@typescript-eslint/types" "6.21.0" + eslint-visitor-keys "^3.4.1" "@ungap/structured-clone@^1.2.0": version "1.2.0" @@ -1193,14 +1189,6 @@ agent-base@^7.0.2: dependencies: debug "^4.3.4" -aggregate-error@^3.0.0: - version "3.1.0" - resolved "https://registry.yarnpkg.com/aggregate-error/-/aggregate-error-3.1.0.tgz#92670ff50f5359bdb7a3e0d40d0ec30c5737687a" - integrity sha512-4I7Td01quW/RpocfNayFdFVk1qSuoh0E7JrbRJ16nH01HhKFQ88INq9Sd+nd72zqRySlr9BmDA8xlEJ6vJMrYA== - dependencies: - clean-stack "^2.0.0" - indent-string "^4.0.0" - ajv@^6.12.4: version "6.12.6" resolved "https://registry.yarnpkg.com/ajv/-/ajv-6.12.6.tgz#baf5a62e802b07d977034586f8c3baf5adf26df4" @@ -1228,13 +1216,20 @@ anchor-markdown-header@^0.6.0: dependencies: emoji-regex "~10.1.0" -ansi-escapes@^4.2.1, ansi-escapes@^4.3.0: +ansi-escapes@^4.2.1: version "4.3.2" resolved "https://registry.yarnpkg.com/ansi-escapes/-/ansi-escapes-4.3.2.tgz#6b2291d1db7d98b6521d5f1efa42d0f3a9feb65e" integrity sha512-gKXj5ALrKWQLsYG9jlTRmR/xKluxHV+Z9QEwNIgCfM1/uwPMCuzVVnh5mwTd+OuBZcwSIMbqssNWRm1lE51QaQ== dependencies: type-fest "^0.21.3" +ansi-escapes@^5.0.0: + version "5.0.0" + resolved "https://registry.yarnpkg.com/ansi-escapes/-/ansi-escapes-5.0.0.tgz#b6a0caf0eef0c41af190e9a749e0c00ec04bb2a6" + integrity sha512-5GFMVX8HqE/TB+FuBJGuO5XG0WrsA6ptUqoODaT/n9mmUaZFkqnBueB4leqGBCmrUHnCnC4PCZTCd0E7QQ83bA== + dependencies: + type-fest "^1.0.2" + ansi-regex@^5.0.1: version "5.0.1" resolved "https://registry.yarnpkg.com/ansi-regex/-/ansi-regex-5.0.1.tgz#082cb2c89c9fe8659a311a53bd6a4dc5301db304" @@ -1314,18 +1309,18 @@ arrify@^1.0.1: resolved "https://registry.yarnpkg.com/arrify/-/arrify-1.0.1.tgz#898508da2226f380df904728456849c1501a4b0d" integrity sha512-3CYzex9M9FGQjCGMGyi6/31c8GJbgb0qGyrx5HWxPd0aCwh4cB2YjMb2Xf9UuoogrMrlO9cTqnB5rI5GHZTcUA== -astral-regex@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/astral-regex/-/astral-regex-2.0.0.tgz#483143c567aeed4785759c0865786dc77d7d2e31" - integrity sha512-Z7tMw1ytTXt5jqMcOP+OQteU1VuNK9Y02uuJtKQ1Sv69jXQKKg5cibLwGJow8yzZP+eAc18EmLGPal0bp36rvQ== - -async-mutex@^0.4.1: - version "0.4.1" - resolved "https://registry.yarnpkg.com/async-mutex/-/async-mutex-0.4.1.tgz#bccf55b96f2baf8df90ed798cb5544a1f6ee4c2c" - integrity sha512-WfoBo4E/TbCX1G95XTjbWTE3X2XLG0m1Xbv2cwOtuPdyH9CZvnaA5nCt1ucjaKEgW2A5IF71hxrRhr83Je5xjA== +async-mutex@^0.5.0: + version "0.5.0" + resolved "https://registry.yarnpkg.com/async-mutex/-/async-mutex-0.5.0.tgz#353c69a0b9e75250971a64ac203b0ebfddd75482" + integrity sha512-1A94B18jkJ3DYq284ohPxoXbfTA5HsQ7/Mf4DEhcyLx3Bz27Rh59iScbB6EPiP+B+joue6YCxcMXSbFC1tZKwA== dependencies: tslib "^2.4.0" +async@^3.2.3: + version "3.2.5" + resolved "https://registry.yarnpkg.com/async/-/async-3.2.5.tgz#ebd52a8fdaf7a2289a24df399f8d8485c8a46b66" + integrity sha512-baNZyqaaLhyLVKm/DlvdW051MSgO6b8eVfIezl9E5PqWxFgzLm/wQntEW4zOytVburDEr0JlALEpdOFwvErLsg== + b4a@^1.6.4: version "1.6.4" resolved "https://registry.yarnpkg.com/b4a/-/b4a-1.6.4.tgz#ef1c1422cae5ce6535ec191baeed7567443f36c9" @@ -1447,10 +1442,10 @@ bser@2.1.1: dependencies: node-int64 "^0.4.0" -bson@^5.5.0: - version "5.5.1" - resolved "https://registry.yarnpkg.com/bson/-/bson-5.5.1.tgz#f5849d405711a7f23acdda9a442375df858e6833" - integrity sha512-ix0EwukN2EpC0SRWIj/7B5+A6uQMQy6KMREI9qQqvgpkV2frH63T0UDVd1SYedL6dNCmDBYB3QtXi4ISk9YT+g== +bson@^6.7.0: + version "6.7.0" + resolved "https://registry.yarnpkg.com/bson/-/bson-6.7.0.tgz#51973b132cdc424c8372fda3cb43e3e3e2ae2227" + integrity sha512-w2IquM5mYzYZv6rs3uN2DZTOBe2a0zXLj53TGDqwF4l6Sz/XsISrisXOJihArF9+BZ6Cq/GjVht7Sjfmri7ytQ== buffer-crc32@~0.2.3: version "0.2.13" @@ -1496,10 +1491,10 @@ ccount@^1.0.0: resolved "https://registry.yarnpkg.com/ccount/-/ccount-1.1.0.tgz#246687debb6014735131be8abab2d93898f8d043" integrity sha512-vlNK021QdI7PNeiUh/lKkC/mNHHfV0m/Ad5JoI0TYtlBnJAslM/JIkm/tGC88bkLIwO6OQ5uV6ztS6kVAtCDlg== -chalk@5.2.0: - version "5.2.0" - resolved "https://registry.yarnpkg.com/chalk/-/chalk-5.2.0.tgz#249623b7d66869c673699fb66d65723e54dfcfb3" - integrity sha512-ree3Gqw/nazQAPuJJEy+avdl7QfZMcUvmHIKgEZkGL+xOBzRvup5Hxo6LHuMceSxOabuJLJm5Yp/92R9eMmMvA== +chalk@5.3.0: + version "5.3.0" + resolved "https://registry.yarnpkg.com/chalk/-/chalk-5.3.0.tgz#67c20a7ebef70e7f3970a01f90fa210cb6860385" + integrity sha512-dLitG79d+GV1Nb/VYcCDFivJeK1hiukt9QjRNVOsUtTy1rR1YJsmpGGTZ3qJos+uw7WmWF4wUwBd9jxjocFC2w== chalk@^2.4.2: version "2.4.2" @@ -1510,7 +1505,7 @@ chalk@^2.4.2: escape-string-regexp "^1.0.5" supports-color "^5.3.0" -chalk@^4.0.0, chalk@^4.1.0: +chalk@^4.0.0, chalk@^4.0.2, chalk@^4.1.0: version "4.1.2" resolved "https://registry.yarnpkg.com/chalk/-/chalk-4.1.2.tgz#aac4e2b7734a740867aeb16bf02aad556a1e7a01" integrity sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA== @@ -1548,25 +1543,12 @@ cjs-module-lexer@^1.0.0: resolved "https://registry.yarnpkg.com/cjs-module-lexer/-/cjs-module-lexer-1.2.3.tgz#6c370ab19f8a3394e318fe682686ec0ac684d107" integrity sha512-0TNiGstbQmCFwt4akjjBg5pLRTSyj/PkWQ1ZoO2zntmg9yLqSRxwEa4iCfQLGjqhiqBfOJa7W/E8wfGrTDmlZQ== -clean-stack@^2.0.0: - version "2.2.0" - resolved "https://registry.yarnpkg.com/clean-stack/-/clean-stack-2.2.0.tgz#ee8472dbb129e727b31e8a10a427dee9dfe4008b" - integrity sha512-4diC9HaTE+KRAMWhDhrGOECgWZxoevMc5TlkObMqNSsVU62PYzXZ/SMTjzyGAFF1YusgxGcSWTEXBhp0CPwQ1A== - -cli-cursor@^3.1.0: - version "3.1.0" - resolved "https://registry.yarnpkg.com/cli-cursor/-/cli-cursor-3.1.0.tgz#264305a7ae490d1d03bf0c9ba7c925d1753af307" - integrity sha512-I/zHAwsKf9FqGoXM4WWRACob9+SNukZTd94DWF57E4toouRulbCxcUh6RKUEOQlYTHJnzkPMySvPNaaSLNfLZw== - dependencies: - restore-cursor "^3.1.0" - -cli-truncate@^2.1.0: - version "2.1.0" - resolved "https://registry.yarnpkg.com/cli-truncate/-/cli-truncate-2.1.0.tgz#c39e28bf05edcde5be3b98992a22deed5a2b93c7" - integrity sha512-n8fOixwDD6b/ObinzTrp1ZKFzbgvKZvuz/TvejnLn1aQfC6r52XEx85FmuC+3HI+JM7coBRXUvNqEU2PHVrHpg== +cli-cursor@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/cli-cursor/-/cli-cursor-4.0.0.tgz#3cecfe3734bf4fe02a8361cbdc0f6fe28c6a57ea" + integrity sha512-VGtlMu3x/4DOtIUwEkRezxUZ2lBacNJCHash0N0WeZDBS+7Ux1dm3XWAgWYxLJFMMdOeXMHXorshEFhbMSGelg== dependencies: - slice-ansi "^3.0.0" - string-width "^4.2.0" + restore-cursor "^4.0.0" cli-truncate@^3.1.0: version "3.1.0" @@ -1619,15 +1601,15 @@ color-name@~1.1.4: resolved "https://registry.yarnpkg.com/color-name/-/color-name-1.1.4.tgz#c2a09a87acbde69543de6f63fa3995c826c536a2" integrity sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA== -colorette@^2.0.19: +colorette@^2.0.20: version "2.0.20" resolved "https://registry.yarnpkg.com/colorette/-/colorette-2.0.20.tgz#9eb793e6833067f7235902fcd3b09917a000a95a" integrity sha512-IfEDxwoWIjkeXL1eXcDiow4UbKjhLdq6/EuSVR9GMN7KVH3r9gQ83e73hsz1Nd1T3ijd5xv1wcWRYO+D6kCI2w== -commander@^10.0.0: - version "10.0.1" - resolved "https://registry.yarnpkg.com/commander/-/commander-10.0.1.tgz#881ee46b4f77d1c1dccc5823433aa39b022cbe06" - integrity sha512-y4Mg2tXshplEbSGzx7amzPwKKOCGuoSRP/CjEdwwk0FOGlUbq6lKuoyDZTNZkmxHdJtp54hdfY/JUrdL7Xfdug== +commander@11.0.0: + version "11.0.0" + resolved "https://registry.yarnpkg.com/commander/-/commander-11.0.0.tgz#43e19c25dbedc8256203538e8d7e9346877a6f67" + integrity sha512-9HMlXtt/BNoYr8ooyjjNRdIilOTkVJXB+GhxMTtOKwk0R4j4lS4NpjuqmRxroBfnfTSHQIHQB7wryHhXarNjmQ== commitlint@17.8.1: version "17.8.1" @@ -1745,6 +1727,13 @@ debug@4, debug@^4.0.0, debug@^4.1.0, debug@^4.1.1, debug@^4.3.1, debug@^4.3.2, d dependencies: ms "2.1.2" +debug@4.3.4: + version "4.3.4" + resolved "https://registry.yarnpkg.com/debug/-/debug-4.3.4.tgz#1319f6579357f2338d3337d2cdd4914bb5dcc865" + integrity sha512-PRWFHuSU3eDtQJPvnNY7Jcket1j0t5OuOsFzPPzsekD52Zl8qUfFIPEiswXqIvHWGVHOgX+7G/vCNNhehwxfkQ== + dependencies: + ms "2.1.2" + decamelize-keys@^1.1.0: version "1.1.1" resolved "https://registry.yarnpkg.com/decamelize-keys/-/decamelize-keys-1.1.1.tgz#04a2d523b2f18d80d0158a43b895d56dff8d19d8" @@ -1856,6 +1845,13 @@ eastasianwidth@^0.2.0: resolved "https://registry.yarnpkg.com/eastasianwidth/-/eastasianwidth-0.2.0.tgz#696ce2ec0aa0e6ea93a397ffcf24aa7840c827cb" integrity sha512-I88TYZWc9XiYHRQ4/3c5rjjfgkjhLyW2luGIheGERbNQ6OY7yTybanSpDXZa8y7VUP9YmDcYa+eyq4ca7iLqWA== +ejs@^3.0.0: + version "3.1.10" + resolved "https://registry.yarnpkg.com/ejs/-/ejs-3.1.10.tgz#69ab8358b14e896f80cc39e62087b88500c3ac3b" + integrity sha512-UeJmFfOrAQS8OJWPZ4qtgHyWExa088/MtK5UEyoJGFH67cDEXkZSviOiKRCZ4Xij0zxI3JECgYs3oKx+AizQBA== + dependencies: + jake "^10.8.5" + electron-to-chromium@^1.4.535: version "1.4.542" resolved "https://registry.yarnpkg.com/electron-to-chromium/-/electron-to-chromium-1.4.542.tgz#9bfe19d8ddafc2591e4a17d04e60a5f5acc54965" @@ -1923,21 +1919,13 @@ eslint-config-prettier@^9.1.0: resolved "https://registry.yarnpkg.com/eslint-config-prettier/-/eslint-config-prettier-9.1.0.tgz#31af3d94578645966c082fcb71a5846d3c94867f" integrity sha512-NSWl5BFQWEPi1j4TjVNItzYV7dZXZ+wP6I6ZhrBGpChQhZRUaElihE9uRRkcbRnNb76UMKDF3r+WTmNcGPKsqw== -eslint-plugin-prettier@5.1.3: - version "5.1.3" - resolved "https://registry.yarnpkg.com/eslint-plugin-prettier/-/eslint-plugin-prettier-5.1.3.tgz#17cfade9e732cef32b5f5be53bd4e07afd8e67e1" - integrity sha512-C9GCVAs4Eq7ZC/XFQHITLiHJxQngdtraXaM+LoUFoFp/lHNl2Zn8f3WQbe9HvTBBQ9YnKFB0/2Ajdqwo5D1EAw== +eslint-plugin-prettier@5.2.1: + version "5.2.1" + resolved "https://registry.yarnpkg.com/eslint-plugin-prettier/-/eslint-plugin-prettier-5.2.1.tgz#d1c8f972d8f60e414c25465c163d16f209411f95" + integrity sha512-gH3iR3g4JfF+yYPaJYkN7jEl9QbweL/YfkoRlNnuIEHEz1vHVlCmWOS+eGGiRuzHQXdJFCOTxRgvju9b8VUmrw== dependencies: prettier-linter-helpers "^1.0.0" - synckit "^0.8.6" - -eslint-scope@^5.1.1: - version "5.1.1" - resolved "https://registry.yarnpkg.com/eslint-scope/-/eslint-scope-5.1.1.tgz#e786e59a66cb92b3f6c1fb0d508aab174848f48c" - integrity sha512-2NxwbF/hZ0KpepYN0cNbo+FN6XoK7GaHlQhgx/hIZl6Va0bF45RQOOwhLIy8lQDbuCiadSLCBnH2CFYquit5bw== - dependencies: - esrecurse "^4.3.0" - estraverse "^4.1.1" + synckit "^0.9.1" eslint-scope@^7.2.2: version "7.2.2" @@ -2024,11 +2012,6 @@ esrecurse@^4.3.0: dependencies: estraverse "^5.2.0" -estraverse@^4.1.1: - version "4.3.0" - resolved "https://registry.yarnpkg.com/estraverse/-/estraverse-4.3.0.tgz#398ad3f3c5a24948be7725e83d11a7de28cdbd1d" - integrity sha512-39nnKffWz8xN1BU/2c79n9nB9HDzo0niYUqx6xyqUnyoAnQyyWpOTdZEeiCch8BBu515t4wp9ZmgVfVhn9EBpw== - estraverse@^5.1.0, estraverse@^5.2.0: version "5.3.0" resolved "https://registry.yarnpkg.com/estraverse/-/estraverse-5.3.0.tgz#2eea5290702f26ab8fe5370370ff86c965d21123" @@ -2039,22 +2022,12 @@ esutils@^2.0.2: resolved "https://registry.yarnpkg.com/esutils/-/esutils-2.0.3.tgz#74d2eb4de0b8da1293711910d50775b9b710ef64" integrity sha512-kVscqXk4OCp68SZ0dkgEKVi6/8ij300KBWTJq32P/dYeWTSwK41WyTxalN1eRmA5Z9UU/LX9D7FWSmV9SAYx6g== -execa@^5.0.0: - version "5.1.1" - resolved "https://registry.yarnpkg.com/execa/-/execa-5.1.1.tgz#f80ad9cbf4298f7bd1d4c9555c21e93741c411dd" - integrity sha512-8uSpZZocAZRBAPIEINJj3Lo9HyGitllczc27Eh5YYojjMFMn8yHMDMaUHE2Jqfq05D/wucwI4JGURyXt1vchyg== - dependencies: - cross-spawn "^7.0.3" - get-stream "^6.0.0" - human-signals "^2.1.0" - is-stream "^2.0.0" - merge-stream "^2.0.0" - npm-run-path "^4.0.1" - onetime "^5.1.2" - signal-exit "^3.0.3" - strip-final-newline "^2.0.0" +eventemitter3@^5.0.1: + version "5.0.1" + resolved "https://registry.yarnpkg.com/eventemitter3/-/eventemitter3-5.0.1.tgz#53f5ffd0a492ac800721bb42c66b841de96423c4" + integrity sha512-GWkBvjiSZK87ELrYOSESUYeVIc9mvLLf/nXalMOS5dYrgZq9o5OVkbZAVM06CVxYsCwH9BDZFPlQTlPA1j4ahA== -execa@^7.0.0: +execa@7.2.0: version "7.2.0" resolved "https://registry.yarnpkg.com/execa/-/execa-7.2.0.tgz#657e75ba984f42a70f38928cedc87d6f2d4fe4e9" integrity sha512-UduyVP7TLB5IcAQl+OzLyLcS/l32W/GLg+AhHJ+ow40FOk2U3SAllPwR44v4vmdFwIWqpdwxxpQbF1n5ta9seA== @@ -2069,6 +2042,21 @@ execa@^7.0.0: signal-exit "^3.0.7" strip-final-newline "^3.0.0" +execa@^5.0.0: + version "5.1.1" + resolved "https://registry.yarnpkg.com/execa/-/execa-5.1.1.tgz#f80ad9cbf4298f7bd1d4c9555c21e93741c411dd" + integrity sha512-8uSpZZocAZRBAPIEINJj3Lo9HyGitllczc27Eh5YYojjMFMn8yHMDMaUHE2Jqfq05D/wucwI4JGURyXt1vchyg== + dependencies: + cross-spawn "^7.0.3" + get-stream "^6.0.0" + human-signals "^2.1.0" + is-stream "^2.0.0" + merge-stream "^2.0.0" + npm-run-path "^4.0.1" + onetime "^5.1.2" + signal-exit "^3.0.3" + strip-final-newline "^2.0.0" + exit@^0.1.2: version "0.1.2" resolved "https://registry.yarnpkg.com/exit/-/exit-0.1.2.tgz#0632638f8d877cc82107d30a0fff1a17cba1cd0c" @@ -2154,6 +2142,13 @@ file-entry-cache@^6.0.1: dependencies: flat-cache "^3.0.4" +filelist@^1.0.4: + version "1.0.4" + resolved "https://registry.yarnpkg.com/filelist/-/filelist-1.0.4.tgz#f78978a1e944775ff9e62e744424f215e58352b5" + integrity sha512-w1cEuf3S+DrLCQL7ET6kz+gmlJdbq9J7yXCSjK/OZCPA+qEN1WyF4ZAf0YYJa4/shHJra2t/d/r8SV4Ji+x+8Q== + dependencies: + minimatch "^5.0.1" + fill-range@^7.1.1: version "7.1.1" resolved "https://registry.yarnpkg.com/fill-range/-/fill-range-7.1.1.tgz#44265d3cac07e3ea7dc247516380643754a05292" @@ -2206,9 +2201,9 @@ follow-redirects@^1.15.6: integrity sha512-wWN62YITEaOpSK584EZXJafH1AGpO8RVgElfkuXbTOrPX4fIfOyEpW/CsiNd8JdYrAoOvafRTOEnvsO++qCqFA== foreground-child@^3.1.0: - version "3.1.1" - resolved "https://registry.yarnpkg.com/foreground-child/-/foreground-child-3.1.1.tgz#1d173e776d75d2772fed08efe4a0de1ea1b12d0d" - integrity sha512-TMKDUnIte6bfb5nWv7V/caI169OHgvwjb7V4WkeUvbQQdjr5rWKqHFiKWb/fcOwB+CzBT+qbWjvj+DVwRskpIg== + version "3.2.1" + resolved "https://registry.yarnpkg.com/foreground-child/-/foreground-child-3.2.1.tgz#767004ccf3a5b30df39bed90718bab43fe0a59f7" + integrity sha512-PXUUyLqrR2XCWICfv6ukppP96sdFwWbNEnfEMt7jNsISjMsvaLNinAHNDYyvkyU+SZG2BTSbT5NjG+vZslfGTA== dependencies: cross-spawn "^7.0.0" signal-exit "^4.0.1" @@ -2283,15 +2278,16 @@ glob-parent@^6.0.2: is-glob "^4.0.3" glob@^10.3.7: - version "10.3.10" - resolved "https://registry.yarnpkg.com/glob/-/glob-10.3.10.tgz#0351ebb809fd187fe421ab96af83d3a70715df4b" - integrity sha512-fa46+tv1Ak0UPK1TOy/pZrIybNNt4HCv7SDzwyfiOZkvZLEbjsZkJBPtDHVshZjbecAoAGSC20MjLDG/qr679g== + version "10.4.5" + resolved "https://registry.yarnpkg.com/glob/-/glob-10.4.5.tgz#f4d9f0b90ffdbab09c9d77f5f29b4262517b0956" + integrity sha512-7Bv8RF0k6xjo7d4A/PxYLbUCfb6c+Vpd2/mB2yRDlew7Jb5hEXiCD9ibfO7wpk8i4sevK6DFny9h7EYbM3/sHg== dependencies: foreground-child "^3.1.0" - jackspeak "^2.3.5" - minimatch "^9.0.1" - minipass "^5.0.0 || ^6.0.2 || ^7.0.0" - path-scurry "^1.10.1" + jackspeak "^3.1.2" + minimatch "^9.0.4" + minipass "^7.1.2" + package-json-from-dist "^1.0.0" + path-scurry "^1.11.1" glob@^7.1.3, glob@^7.1.4: version "7.2.3" @@ -2341,11 +2337,6 @@ graceful-fs@^4.1.6, graceful-fs@^4.2.0, graceful-fs@^4.2.9: resolved "https://registry.yarnpkg.com/graceful-fs/-/graceful-fs-4.2.11.tgz#4183e4e8bf08bb6e05bbb2f7d2e0c8f712ca40e3" integrity sha512-RbJ5/jmFcNNCcDV5o9eTnBLJ/HszWV0P73bc+Ff4nS/rJj+YaS6IGyiOL0VoBYX+l1Wrl3k63h/KrH+nhJ0XvQ== -grapheme-splitter@^1.0.4: - version "1.0.4" - resolved "https://registry.yarnpkg.com/grapheme-splitter/-/grapheme-splitter-1.0.4.tgz#9cf3a665c6247479896834af35cf1dbb4400767e" - integrity sha512-bzh50DW9kTPM00T8y4o8vQg89Di9oLJVLW/KaOGIXJWP/iqCN6WKYkbNOF04vFLJhwcpYUh9ydh/+5vpOqV4YQ== - graphemer@^1.4.0: version "1.4.0" resolved "https://registry.yarnpkg.com/graphemer/-/graphemer-1.4.0.tgz#fb2f1d55e0e3a1849aeffc90c4fa0dd53a0e66c6" @@ -2398,10 +2389,10 @@ htmlparser2@^7.2.0: domutils "^2.8.0" entities "^3.0.1" -https-proxy-agent@^7.0.4: - version "7.0.4" - resolved "https://registry.yarnpkg.com/https-proxy-agent/-/https-proxy-agent-7.0.4.tgz#8e97b841a029ad8ddc8731f26595bad868cb4168" - integrity sha512-wlwpilI7YdjSkWaQ/7omYBMTliDcmCN8OLihO6I9B86g06lMyAoqgoDpV0XqoaPOKj+0DIdAvnsWfyAAhmimcg== +https-proxy-agent@^7.0.5: + version "7.0.5" + resolved "https://registry.yarnpkg.com/https-proxy-agent/-/https-proxy-agent-7.0.5.tgz#9e8b5013873299e11fab6fd548405da2d6c602b2" + integrity sha512-1e4Wqeblerz+tMKPIq2EMGiiWW1dIjZOksyHWSUm1rmuvw/how9hBHZ38lAGj5ID4Ik6EdkOw7NmWPy6LAwalw== dependencies: agent-base "^7.0.2" debug "4" @@ -2426,6 +2417,11 @@ ignore@^5.2.0: resolved "https://registry.yarnpkg.com/ignore/-/ignore-5.2.4.tgz#a291c0c6178ff1b960befe47fcdec301674a6324" integrity sha512-MAb38BcSbH0eHNBxn7ql2NH/kX33OkB3lZ1BNdh7ENeRChHTYsTvWrMubiIAMNS2llXEEgZ1MUOBtXChP3kaFQ== +ignore@^5.2.4: + version "5.3.1" + resolved "https://registry.yarnpkg.com/ignore/-/ignore-5.3.1.tgz#5073e554cd42c5b33b394375f538b8593e34d4ef" + integrity sha512-5Fytz/IraMjqpwfd34ke28PTVMjZjJG2MPn5t7OE4eUCUNf8BAa7b5WUS9/Qvr6mwOQS7Mk6vdsMno5he+T8Xw== + import-fresh@^3.0.0, import-fresh@^3.2.1, import-fresh@^3.3.0: version "3.3.0" resolved "https://registry.yarnpkg.com/import-fresh/-/import-fresh-3.3.0.tgz#37162c25fcb9ebaa2e6e53d5b4d88ce17d9e0c2b" @@ -2470,14 +2466,6 @@ ini@^1.3.4: resolved "https://registry.yarnpkg.com/ini/-/ini-1.3.8.tgz#a29da425b48806f34767a4efce397269af28432c" integrity sha512-JV/yugV2uzW5iMRSiZAyDtQd+nxtUnjeLt0acNdw98kKLrvuRVyB80tsREOE7yvGVgalhZ6RNXCmEHkUKBKxew== -ip-address@^9.0.5: - version "9.0.5" - resolved "https://registry.yarnpkg.com/ip-address/-/ip-address-9.0.5.tgz#117a960819b08780c3bd1f14ef3c1cc1d3f3ea5a" - integrity sha512-zHtQzGojZXTwZTHQqra+ETKd4Sn3vgi7uBmlPoXVWZqYvuKmtI0l/VZTjqGmJY9x88GGOaZ9+G9ES8hC4T4X8g== - dependencies: - jsbn "1.1.0" - sprintf-js "^1.1.3" - is-alphabetical@^1.0.0: version "1.0.4" resolved "https://registry.yarnpkg.com/is-alphabetical/-/is-alphabetical-1.0.4.tgz#9e7d6b94916be22153745d184c298cbf986a686d" @@ -2645,15 +2633,25 @@ istanbul-reports@^3.1.3: html-escaper "^2.0.0" istanbul-lib-report "^3.0.0" -jackspeak@^2.3.5: - version "2.3.6" - resolved "https://registry.yarnpkg.com/jackspeak/-/jackspeak-2.3.6.tgz#647ecc472238aee4b06ac0e461acc21a8c505ca8" - integrity sha512-N3yCS/NegsOBokc8GAdM8UcmfsKiSS8cipheD/nivzr700H+nsMOxJjQnvwOcRYVuFkdH0wGUvW2WbXGmrZGbQ== +jackspeak@^3.1.2: + version "3.4.3" + resolved "https://registry.yarnpkg.com/jackspeak/-/jackspeak-3.4.3.tgz#8833a9d89ab4acde6188942bd1c53b6390ed5a8a" + integrity sha512-OGlZQpz2yfahA/Rd1Y8Cd9SIEsqvXkLVoSw/cgwhnhFMDbsQFeZYoJJ7bIZBS9BcamUW96asq/npPWugM+RQBw== dependencies: "@isaacs/cliui" "^8.0.2" optionalDependencies: "@pkgjs/parseargs" "^0.11.0" +jake@^10.8.5: + version "10.9.1" + resolved "https://registry.yarnpkg.com/jake/-/jake-10.9.1.tgz#8dc96b7fcc41cb19aa502af506da4e1d56f5e62b" + integrity sha512-61btcOHNnLnsOdtLgA5efqQWjnSi/vow5HbI7HMdKKWqvrKR1bLK3BPlJn9gcSaP2ewuamUSMB5XEy76KUIS2w== + dependencies: + async "^3.2.3" + chalk "^4.0.2" + filelist "^1.0.4" + minimatch "^3.1.2" + jest-changed-files@^29.7.0: version "29.7.0" resolved "https://registry.yarnpkg.com/jest-changed-files/-/jest-changed-files-29.7.0.tgz#1c06d07e77c78e1585d020424dedc10d6e17ac3a" @@ -3032,11 +3030,6 @@ js-yaml@^4.1.0: dependencies: argparse "^2.0.1" -jsbn@1.1.0: - version "1.1.0" - resolved "https://registry.yarnpkg.com/jsbn/-/jsbn-1.1.0.tgz#b01307cb29b618a1ed26ec79e911f803c4da0040" - integrity sha512-4bYVV3aAMtDTTu4+xsDYa6sy9GyJ69/amsu9sYF2zqjiEoZA5xJi3BrfX3uY+/IekIu7MwdObdbDWpoZdBv3/A== - jsesc@^2.5.1: version "2.5.2" resolved "https://registry.yarnpkg.com/jsesc/-/jsesc-2.5.2.tgz#80564d2e483dacf6e8ef209650a67df3f0c283a4" @@ -3131,38 +3124,33 @@ lines-and-columns@^1.1.6: resolved "https://registry.yarnpkg.com/lines-and-columns/-/lines-and-columns-1.2.4.tgz#eca284f75d2965079309dc0ad9255abb2ebc1632" integrity sha512-7ylylesZQ/PV29jhEDl3Ufjo6ZX7gCqJr5F7PKrqc93v7fzSymt1BpwEU8nAUXs8qzzvqhbjhK5QZg6Mt/HkBg== -lint-staged@13.2.3: - version "13.2.3" - resolved "https://registry.yarnpkg.com/lint-staged/-/lint-staged-13.2.3.tgz#f899aad6c093473467e9c9e316e3c2d8a28f87a7" - integrity sha512-zVVEXLuQIhr1Y7R7YAWx4TZLdvuzk7DnmrsTNL0fax6Z3jrpFcas+vKbzxhhvp6TA55m1SQuWkpzI1qbfDZbAg== +lint-staged@14.0.1: + version "14.0.1" + resolved "https://registry.yarnpkg.com/lint-staged/-/lint-staged-14.0.1.tgz#57dfa3013a3d60762d9af5d9c83bdb51291a6232" + integrity sha512-Mw0cL6HXnHN1ag0mN/Dg4g6sr8uf8sn98w2Oc1ECtFto9tvRF7nkXGJRbx8gPlHyoR0pLyBr2lQHbWwmUHe1Sw== dependencies: - chalk "5.2.0" - cli-truncate "^3.1.0" - commander "^10.0.0" - debug "^4.3.4" - execa "^7.0.0" + chalk "5.3.0" + commander "11.0.0" + debug "4.3.4" + execa "7.2.0" lilconfig "2.1.0" - listr2 "^5.0.7" - micromatch "^4.0.5" - normalize-path "^3.0.0" - object-inspect "^1.12.3" - pidtree "^0.6.0" - string-argv "^0.3.1" - yaml "^2.2.2" + listr2 "6.6.1" + micromatch "4.0.5" + pidtree "0.6.0" + string-argv "0.3.2" + yaml "2.3.1" -listr2@^5.0.7: - version "5.0.8" - resolved "https://registry.yarnpkg.com/listr2/-/listr2-5.0.8.tgz#a9379ffeb4bd83a68931a65fb223a11510d6ba23" - integrity sha512-mC73LitKHj9w6v30nLNGPetZIlfpUniNSsxxrbaPcWOjDb92SHPzJPi/t+v1YC/lxKz/AJ9egOjww0qUuFxBpA== +listr2@6.6.1: + version "6.6.1" + resolved "https://registry.yarnpkg.com/listr2/-/listr2-6.6.1.tgz#08b2329e7e8ba6298481464937099f4a2cd7f95d" + integrity sha512-+rAXGHh0fkEWdXBmX+L6mmfmXmXvDGEKzkjxO+8mP3+nI/r/CWznVBvsibXdxda9Zz0OW2e2ikphN3OwCT/jSg== dependencies: - cli-truncate "^2.1.0" - colorette "^2.0.19" - log-update "^4.0.0" - p-map "^4.0.0" + cli-truncate "^3.1.0" + colorette "^2.0.20" + eventemitter3 "^5.0.1" + log-update "^5.0.1" rfdc "^1.3.0" - rxjs "^7.8.0" - through "^2.3.8" - wrap-ansi "^7.0.0" + wrap-ansi "^8.1.0" locate-path@^5.0.0: version "5.0.0" @@ -3238,21 +3226,27 @@ lodash@^4.17.15: resolved "https://registry.yarnpkg.com/lodash/-/lodash-4.17.21.tgz#679591c564c3bffaae8454cf0b3df370c3d6911c" integrity sha512-v2kDEe57lecTulaDIuNTPy3Ry4gLGJ6Z1O3vE1krgXZNrsQ+LFTGHVxVjcXPs17LhbZVGedAJv8XZ1tvj5FvSg== -log-update@^4.0.0: - version "4.0.0" - resolved "https://registry.yarnpkg.com/log-update/-/log-update-4.0.0.tgz#589ecd352471f2a1c0c570287543a64dfd20e0a1" - integrity sha512-9fkkDevMefjg0mmzWFBW8YkFP91OrizzkW3diF7CpG+S2EYdy4+TVfGwz1zeF8x7hCx1ovSPTOE9Ngib74qqUg== +log-update@^5.0.1: + version "5.0.1" + resolved "https://registry.yarnpkg.com/log-update/-/log-update-5.0.1.tgz#9e928bf70cb183c1f0c9e91d9e6b7115d597ce09" + integrity sha512-5UtUDQ/6edw4ofyljDNcOVJQ4c7OjDro4h3y8e1GQL5iYElYclVHJ3zeWchylvMaKnDbDilC8irOVyexnA/Slw== dependencies: - ansi-escapes "^4.3.0" - cli-cursor "^3.1.0" - slice-ansi "^4.0.0" - wrap-ansi "^6.2.0" + ansi-escapes "^5.0.0" + cli-cursor "^4.0.0" + slice-ansi "^5.0.0" + strip-ansi "^7.0.1" + wrap-ansi "^8.0.1" longest-streak@^2.0.0: version "2.0.4" resolved "https://registry.yarnpkg.com/longest-streak/-/longest-streak-2.0.4.tgz#b8599957da5b5dab64dee3fe316fa774597d90e4" integrity sha512-vM6rUVCVUJJt33bnmHiZEvr7wPT78ztX7rojL+LW51bHtLh6HTjx84LA5W4+oa6aKEJA7jJu5LR6vQRBpA5DVg== +lru-cache@^10.2.0: + version "10.4.3" + resolved "https://registry.yarnpkg.com/lru-cache/-/lru-cache-10.4.3.tgz#410fc8a17b70e598013df257c2446b7f3383f119" + integrity sha512-JNAzZcXrCt42VGLuYz0zfAzDfAvJWW6AfYlDBQyDV5DClI2m5sAmK+OIO7s59XfsRsWHp02jAJrRadPRGTt6SQ== + lru-cache@^5.1.1: version "5.1.1" resolved "https://registry.yarnpkg.com/lru-cache/-/lru-cache-5.1.1.tgz#1da27e6710271947695daf6848e847f01d84b920" @@ -3267,11 +3261,6 @@ lru-cache@^6.0.0: dependencies: yallist "^4.0.0" -"lru-cache@^9.1.1 || ^10.0.0": - version "10.0.1" - resolved "https://registry.yarnpkg.com/lru-cache/-/lru-cache-10.0.1.tgz#0a3be479df549cca0e5d693ac402ff19537a6b7a" - integrity sha512-IJ4uwUTi2qCccrioU6g9g/5rvvVl13bsdczUUcqbciD9iLr095yj8DQKdObriEvuNSx325N1rV1O0sJFszx75g== - lunr@^2.3.9: version "2.3.9" resolved "https://registry.yarnpkg.com/lunr/-/lunr-2.3.9.tgz#18b123142832337dd6e964df1a5a7707b25d35e1" @@ -3518,7 +3507,7 @@ micromark@^2.11.3, micromark@~2.11.0, micromark@~2.11.3: debug "^4.0.0" parse-entities "^2.0.0" -micromatch@^4.0.4, micromatch@^4.0.5: +micromatch@4.0.5, micromatch@^4.0.4: version "4.0.5" resolved "https://registry.yarnpkg.com/micromatch/-/micromatch-4.0.5.tgz#bc8999a7cbbf77cdc89f132f6e467051b49090c6" integrity sha512-DMy+ERcEW2q8Z2Po+WNXuw3c5YaUSFjAO5GsJqfEl7UjvtIuFKO6ZrKvcItdy98dwFI2N1tg3zNIdKaQT+aNdA== @@ -3541,6 +3530,13 @@ min-indent@^1.0.0: resolved "https://registry.yarnpkg.com/min-indent/-/min-indent-1.0.1.tgz#a63f681673b30571fbe8bc25686ae746eefa9869" integrity sha512-I9jwMn07Sy/IwOj3zVkVik2JTvgpaykDZEigL6Rx6N9LbMywwUSMtxET+7lVoDLLd3O3IXwJwvuuns8UB/HeAg== +minimatch@9.0.3: + version "9.0.3" + resolved "https://registry.yarnpkg.com/minimatch/-/minimatch-9.0.3.tgz#a6e00c3de44c3a542bfaae70abfc22420a6da825" + integrity sha512-RHiac9mvaRw0x3AYRgDC1CxAP7HTcNrrECeA8YYJeWnpo+2Q5CegtZjaotWTWxDG3UeGA1coE05iH1mPjT/2mg== + dependencies: + brace-expansion "^2.0.1" + minimatch@^3.0.4, minimatch@^3.0.5, minimatch@^3.1.1, minimatch@^3.1.2: version "3.1.2" resolved "https://registry.yarnpkg.com/minimatch/-/minimatch-3.1.2.tgz#19cd194bfd3e428f049a70817c038d89ab4be35b" @@ -3548,10 +3544,24 @@ minimatch@^3.0.4, minimatch@^3.0.5, minimatch@^3.1.1, minimatch@^3.1.2: dependencies: brace-expansion "^1.1.7" -minimatch@^9.0.0, minimatch@^9.0.1: - version "9.0.3" - resolved "https://registry.yarnpkg.com/minimatch/-/minimatch-9.0.3.tgz#a6e00c3de44c3a542bfaae70abfc22420a6da825" - integrity sha512-RHiac9mvaRw0x3AYRgDC1CxAP7HTcNrrECeA8YYJeWnpo+2Q5CegtZjaotWTWxDG3UeGA1coE05iH1mPjT/2mg== +minimatch@^5.0.1: + version "5.1.6" + resolved "https://registry.yarnpkg.com/minimatch/-/minimatch-5.1.6.tgz#1cfcb8cf5522ea69952cd2af95ae09477f122a96" + integrity sha512-lKwV/1brpG6mBUFHtb7NUmtABCb2WZZmm2wNiOA5hAb8VdCS4B3dtMWyvcoViccwAW/COERjXLt0zP1zXUN26g== + dependencies: + brace-expansion "^2.0.1" + +minimatch@^9.0.3: + version "9.0.4" + resolved "https://registry.yarnpkg.com/minimatch/-/minimatch-9.0.4.tgz#8e49c731d1749cbec05050ee5145147b32496a51" + integrity sha512-KqWh+VchfxcMNRAJjj2tnsSJdNbHsVgnkBhTNrW7AjVo6OvLtxw8zfT9oLw1JSohlFzJ8jCoTgaoXvJ+kHt6fw== + dependencies: + brace-expansion "^2.0.1" + +minimatch@^9.0.4: + version "9.0.5" + resolved "https://registry.yarnpkg.com/minimatch/-/minimatch-9.0.5.tgz#d74f9dd6b57d83d8e98cfb82133b03978bc929e5" + integrity sha512-G6T0ZX48xgozx7587koeX9Ys2NYy6Gmv//P89sEte9V9whIapMNF4idKxnW2QtCcLiTWlb/wfCabAtAFWhhBow== dependencies: brace-expansion "^2.0.1" @@ -3569,40 +3579,33 @@ minimist@^1.2.6: resolved "https://registry.yarnpkg.com/minimist/-/minimist-1.2.8.tgz#c1a464e7693302e082a075cee0c057741ac4772c" integrity sha512-2yyAR8qBkN3YuheJanUpWC5U3bb5osDywNB8RzDVlDwDHbocAJveqqj1u8+SVD7jkWT4yvsHCpWqqWqAxb0zCA== -"minipass@^5.0.0 || ^6.0.2 || ^7.0.0": - version "7.0.4" - resolved "https://registry.yarnpkg.com/minipass/-/minipass-7.0.4.tgz#dbce03740f50a4786ba994c1fb908844d27b038c" - integrity sha512-jYofLM5Dam9279rdkWzqHozUo4ybjdZmCsDHePy5V/PbBcVMiSZR97gmAy45aqi8CK1lG2ECd356FU86avfwUQ== +"minipass@^5.0.0 || ^6.0.2 || ^7.0.0", minipass@^7.1.2: + version "7.1.2" + resolved "https://registry.yarnpkg.com/minipass/-/minipass-7.1.2.tgz#93a9626ce5e5e66bd4db86849e7515e92340a707" + integrity sha512-qOOzS1cBTWYF4BH8fVePDBOO9iptMnGUEZwNc/cMWnTV2nVLZ7VoNWEPHkYczZA0pdoA7dl6e7FL659nX9S2aw== -mongodb-connection-string-url@^2.6.0: - version "2.6.0" - resolved "https://registry.yarnpkg.com/mongodb-connection-string-url/-/mongodb-connection-string-url-2.6.0.tgz#57901bf352372abdde812c81be47b75c6b2ec5cf" - integrity sha512-WvTZlI9ab0QYtTYnuMLgobULWhokRjtC7db9LtcVfJ+Hsnyr5eo6ZtNAt3Ly24XZScGMelOcGtm7lSn0332tPQ== +mongodb-connection-string-url@^3.0.0: + version "3.0.1" + resolved "https://registry.yarnpkg.com/mongodb-connection-string-url/-/mongodb-connection-string-url-3.0.1.tgz#c13e6ac284ae401752ebafdb8cd7f16c6723b141" + integrity sha512-XqMGwRX0Lgn05TDB4PyG2h2kKO/FfWJyCzYQbIhXUxz7ETt0I/FqHjUeqj37irJ+Dl1ZtU82uYyj14u2XsZKfg== dependencies: - "@types/whatwg-url" "^8.2.1" - whatwg-url "^11.0.0" + "@types/whatwg-url" "^11.0.2" + whatwg-url "^13.0.0" -mongodb@^5.9.2: - version "5.9.2" - resolved "https://registry.yarnpkg.com/mongodb/-/mongodb-5.9.2.tgz#39a73b9fbc87ac9d9c1aaf8aab5c5bb69e2b913e" - integrity sha512-H60HecKO4Bc+7dhOv4sJlgvenK4fQNqqUIlXxZYQNbfEWSALGAwGoyJd/0Qwk4TttFXUOHJ2ZJQe/52ScaUwtQ== +mongodb@^6.7.0: + version "6.7.0" + resolved "https://registry.yarnpkg.com/mongodb/-/mongodb-6.7.0.tgz#f86e51e6530e6a2ca4a99d7cfdf6f409223ac199" + integrity sha512-TMKyHdtMcO0fYBNORiYdmM25ijsHs+Njs963r4Tro4OQZzqYigAzYQouwWRg4OIaiLRUEGUh/1UAcH5lxdSLIA== dependencies: - bson "^5.5.0" - mongodb-connection-string-url "^2.6.0" - socks "^2.7.1" - optionalDependencies: - "@mongodb-js/saslprep" "^1.1.0" + "@mongodb-js/saslprep" "^1.1.5" + bson "^6.7.0" + mongodb-connection-string-url "^3.0.0" ms@2.1.2: version "2.1.2" resolved "https://registry.yarnpkg.com/ms/-/ms-2.1.2.tgz#d09d1f357b443f493382a8eb3ccd183872ae6009" integrity sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w== -natural-compare-lite@^1.4.0: - version "1.4.0" - resolved "https://registry.yarnpkg.com/natural-compare-lite/-/natural-compare-lite-1.4.0.tgz#17b09581988979fddafe0201e931ba933c96cbb4" - integrity sha512-Tj+HTDSJJKaZnfiuw+iaF9skdPpTo2GtEly5JHnWV/hfv2Qj/9RKsGISQtLh2ox3l5EAGw487hnBee0sIJ6v2g== - natural-compare@^1.4.0: version "1.4.0" resolved "https://registry.yarnpkg.com/natural-compare/-/natural-compare-1.4.0.tgz#4abebfeed7541f2c27acfb29bdbbd15c8d5ba4f7" @@ -3664,11 +3667,6 @@ npm-run-path@^5.1.0: dependencies: path-key "^4.0.0" -object-inspect@^1.12.3: - version "1.12.3" - resolved "https://registry.yarnpkg.com/object-inspect/-/object-inspect-1.12.3.tgz#ba62dffd67ee256c8c086dfae69e016cd1f198b9" - integrity sha512-geUvdk7c+eizMNUDkRpW1wJwgfOiOeHbxBR/hLXK1aT6zmVSO0jsQcs7fj6MGw89jC/cjGfLcNOrtMYtGqm81g== - once@^1.3.0: version "1.4.0" resolved "https://registry.yarnpkg.com/once/-/once-1.4.0.tgz#583b1aa775961d4b113ac17d9c50baef9dd76bd1" @@ -3730,18 +3728,16 @@ p-locate@^5.0.0: dependencies: p-limit "^3.0.2" -p-map@^4.0.0: - version "4.0.0" - resolved "https://registry.yarnpkg.com/p-map/-/p-map-4.0.0.tgz#bb2f95a5eda2ec168ec9274e06a747c3e2904d2b" - integrity sha512-/bjOqmgETBYB5BoEeGVea8dmvHb2m9GLy1E9W43yeyfP6QQCZGFNa+XRceJEuDB6zqr+gKpIAmlLebMpykw/MQ== - dependencies: - aggregate-error "^3.0.0" - p-try@^2.0.0: version "2.2.0" resolved "https://registry.yarnpkg.com/p-try/-/p-try-2.2.0.tgz#cb2868540e313d61de58fafbe35ce9004d5540e6" integrity sha512-R4nPAVTAU0B9D35/Gk3uJf/7XYbQcyohSKdvAxIRSNghFl4e71hVoGnBNQz9cWaXxO2I10KTC+3jMdvvoKw6dQ== +package-json-from-dist@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/package-json-from-dist/-/package-json-from-dist-1.0.0.tgz#e501cd3094b278495eb4258d4c9f6d5ac3019f00" + integrity sha512-dATvCeZN/8wQsGywez1mzHtTlP22H8OEfPrVMLNr4/eGa+ijtLn/6M5f0dY8UKNrC2O9UCU6SSoG3qRKnt7STw== + parent-module@^1.0.0: version "1.0.1" resolved "https://registry.yarnpkg.com/parent-module/-/parent-module-1.0.1.tgz#691d2709e78c79fae3a156622452d00762caaaa2" @@ -3796,12 +3792,12 @@ path-parse@^1.0.7: resolved "https://registry.yarnpkg.com/path-parse/-/path-parse-1.0.7.tgz#fbc114b60ca42b30d9daf5858e4bd68bbedb6735" integrity sha512-LDJzPVEEEPR+y48z93A0Ed0yXb8pAByGWo/k5YYdYgpY2/2EsOsksJrq7lOHxryrVOn1ejG6oAp8ahvOIQD8sw== -path-scurry@^1.10.1: - version "1.10.1" - resolved "https://registry.yarnpkg.com/path-scurry/-/path-scurry-1.10.1.tgz#9ba6bf5aa8500fe9fd67df4f0d9483b2b0bfc698" - integrity sha512-MkhCqzzBEpPvxxQ71Md0b1Kk51W01lrYvlMzSUaIzNsODdd7mqhiimSZlr+VegAz5Z6Vzt9Xg2ttE//XBhH3EQ== +path-scurry@^1.11.1: + version "1.11.1" + resolved "https://registry.yarnpkg.com/path-scurry/-/path-scurry-1.11.1.tgz#7960a668888594a0720b12a911d1a742ab9f11d2" + integrity sha512-Xa4Nw17FS9ApQFJ9umLiJS4orGjm7ZzwUrwamcGQuHSzDyth9boKDaycYdDcZDuqYATXw4HFXgaqWTctW/v1HA== dependencies: - lru-cache "^9.1.1 || ^10.0.0" + lru-cache "^10.2.0" minipass "^5.0.0 || ^6.0.2 || ^7.0.0" path-type@^4.0.0: @@ -3824,7 +3820,7 @@ picomatch@^2.0.4, picomatch@^2.2.3, picomatch@^2.3.1: resolved "https://registry.yarnpkg.com/picomatch/-/picomatch-2.3.1.tgz#3ba3833733646d9d3e4995946c1365a67fb07a42" integrity sha512-JU3teHTNjmE2VCGFzuY8EXzCDVwEqB2a8fsIvwaStHhAWJEeVd1o1QD80CU6+ZdEXXSLbSsuLwJjkCBWqRQUVA== -pidtree@^0.6.0: +pidtree@0.6.0: version "0.6.0" resolved "https://registry.yarnpkg.com/pidtree/-/pidtree-0.6.0.tgz#90ad7b6d42d5841e69e0a2419ef38f8883aa057c" integrity sha512-eG2dWTVw5bzqGRztnHExczNxt5VGsE6OwTeCG3fdUf9KBsZzO3R5OIIIzWR+iZA0NtZ+RDVdaoE2dK1cn6jH4g== @@ -3853,10 +3849,10 @@ prettier-linter-helpers@^1.0.0: dependencies: fast-diff "^1.1.2" -prettier@3.2.5: - version "3.2.5" - resolved "https://registry.yarnpkg.com/prettier/-/prettier-3.2.5.tgz#e52bc3090586e824964a8813b09aba6233b28368" - integrity sha512-3/GWa9aOC0YeD7LUfvOG2NiDyhOWRvt1k+rcKhOuYnMY24iiCphgneUfJDyFXd6rZCAnuLBv6UeAULtrhT/F4A== +prettier@3.3.3: + version "3.3.3" + resolved "https://registry.yarnpkg.com/prettier/-/prettier-3.3.3.tgz#30c54fe0be0d8d12e6ae61dbb10109ea00d53105" + integrity sha512-i2tDNA0O5IrMO757lfrdQZCc2jPNDVntV0m/+4whiDfWaTKfMNgR7Qz0NAeGz/nRqF4m5/6CLzbP4/liHt12Ew== pretty-format@^29.0.0, pretty-format@^29.7.0: version "29.7.0" @@ -3875,7 +3871,7 @@ prompts@^2.0.1: kleur "^3.0.3" sisteransi "^1.0.5" -punycode@^2.1.0, punycode@^2.1.1: +punycode@^2.1.0, punycode@^2.3.0: version "2.3.1" resolved "https://registry.yarnpkg.com/punycode/-/punycode-2.3.1.tgz#027422e2faec0b25e1549c3e1bd8309b9133b6e5" integrity sha512-vYt7UD1U9Wg6138shLtLOvdAu+8DsC/ilFtEVHcH+wydcSpNE20AfSOduf6MkRFahL5FY7X1oU7nKVZFtfq8Fg== @@ -4025,10 +4021,10 @@ resolve@^1.10.0, resolve@^1.20.0: path-parse "^1.0.7" supports-preserve-symlinks-flag "^1.0.0" -restore-cursor@^3.1.0: - version "3.1.0" - resolved "https://registry.yarnpkg.com/restore-cursor/-/restore-cursor-3.1.0.tgz#39f67c54b3a7a58cea5236d95cf0034239631f7e" - integrity sha512-l+sSefzHpj5qimhFSE5a8nufZYAM3sBSVMAPtYkmC+4EH2anSGaEMXSD0izRQbu9nfyQ9y5JrVmp7E8oZrUjvA== +restore-cursor@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/restore-cursor/-/restore-cursor-4.0.0.tgz#519560a4318975096def6e609d44100edaa4ccb9" + integrity sha512-I9fPXU9geO9bHOt9pHHOhOkYerIMsmVaWB0rA2AI9ERh/+x/i7MV5HKBNrg+ljO5eoPVgCcnFuRjJ9uH6I/3eg== dependencies: onetime "^5.1.0" signal-exit "^3.0.2" @@ -4050,10 +4046,10 @@ rimraf@^3.0.2: dependencies: glob "^7.1.3" -rimraf@^5.0.7: - version "5.0.7" - resolved "https://registry.yarnpkg.com/rimraf/-/rimraf-5.0.7.tgz#27bddf202e7d89cb2e0381656380d1734a854a74" - integrity sha512-nV6YcJo5wbLW77m+8KjH8aB/7/rxQy9SZ0HY5shnwULfS+9nmTtVXAJET5NdZmCzA4fPI/Hm1wo/Po/4mopOdg== +rimraf@^5.0.9: + version "5.0.9" + resolved "https://registry.yarnpkg.com/rimraf/-/rimraf-5.0.9.tgz#c3baa1b886eadc2ec7981a06a593c3d01134ffe9" + integrity sha512-3i7b8OcswU6CpU8Ej89quJD4O98id7TtVM5U4Mybh84zQXdrFmDLouWBEEaD/QfO3gDDfH+AGFCGsR7kngzQnA== dependencies: glob "^10.3.7" @@ -4064,13 +4060,6 @@ run-parallel@^1.1.9: dependencies: queue-microtask "^1.2.2" -rxjs@^7.8.0: - version "7.8.1" - resolved "https://registry.yarnpkg.com/rxjs/-/rxjs-7.8.1.tgz#6f6f3d99ea8044291efd92e7c7fcf562c4057543" - integrity sha512-AA3TVj+0A2iuIoQkWEK/tqFjBq2j+6PO6Y0zJcvzLAFhEFIO3HL0vls9hWLncZbAAbK0mar7oZ4V079I/qPMxg== - dependencies: - tslib "^2.1.0" - safe-buffer@~5.2.0: version "5.2.1" resolved "https://registry.yarnpkg.com/safe-buffer/-/safe-buffer-5.2.1.tgz#1eaf9fa9bdb1fdd4ec75f58f9cdb4e6b7827eec6" @@ -4081,7 +4070,7 @@ safe-buffer@~5.2.0: resolved "https://registry.yarnpkg.com/semver/-/semver-5.7.2.tgz#48d55db737c3287cd4835e17fa13feace1c41ef8" integrity sha512-cBznnQ9KjJqU67B52RMC65CMarK2600WFnbkcaiwWq3xy/5haFJlshgnpjovMVJ+Hff49d8GEn0b87C5pDQ10g== -semver@7.5.4, semver@^7.3.4, semver@^7.3.7, semver@^7.5.3, semver@^7.5.4: +semver@7.5.4, semver@^7.3.4, semver@^7.5.3, semver@^7.5.4: version "7.5.4" resolved "https://registry.yarnpkg.com/semver/-/semver-7.5.4.tgz#483986ec4ed38e1c6c48c34894a9182dbff68a6e" integrity sha512-1bCSESV6Pv+i21Hvpxp3Dx+pSD8lIPt8uVjRrxAUt/nbswYc+tK6Y2btiULjd4+fnq15PX+nqQDC7Oft7WkwcA== @@ -4093,10 +4082,10 @@ semver@^6.0.0, semver@^6.3.0, semver@^6.3.1: resolved "https://registry.yarnpkg.com/semver/-/semver-6.3.1.tgz#556d2ef8689146e46dcea4bfdd095f3434dffcb4" integrity sha512-BR7VvDCVHO+q2xBEWskxS6DJE1qRnb7DxzUrogb71CWoSficBxYsiAGd+Kl0mmq/MprG9yArRkyrQxTO6XjMzA== -semver@^7.6.2: - version "7.6.2" - resolved "https://registry.yarnpkg.com/semver/-/semver-7.6.2.tgz#1e3b34759f896e8f14d6134732ce798aeb0c6e13" - integrity sha512-FNAIBWCx9qcRhoHcgcJ0gvU7SN1lYU2ZXuSfl04bSC5OpvDHFyJCjdNHomPXxjQlCBU67YW64PzY7/VIEH7F2w== +semver@^7.6.3: + version "7.6.3" + resolved "https://registry.yarnpkg.com/semver/-/semver-7.6.3.tgz#980f7b5550bc175fb4dc09403085627f9eb33143" + integrity sha512-oVekP1cKtI+CTDvHWYFUcMtsK/00wmAEfyqKfNdARm8u1wNVhSgaX7A8d4UuIlUI5e84iEwOhs7ZPYRmzU9U6A== shebang-command@^2.0.0: version "2.0.0" @@ -4110,10 +4099,10 @@ shebang-regex@^3.0.0: resolved "https://registry.yarnpkg.com/shebang-regex/-/shebang-regex-3.0.0.tgz#ae16f1644d873ecad843b0307b143362d4c42172" integrity sha512-7++dFhtcx3353uBaq8DDR4NuxBetBzC7ZQOhmTQInHEd6bSrXdiEyzCvG07Z44UYdLShWUyXt5M/yhz8ekcb1A== -shiki@^0.14.1: - version "0.14.4" - resolved "https://registry.yarnpkg.com/shiki/-/shiki-0.14.4.tgz#2454969b466a5f75067d0f2fa0d7426d32881b20" - integrity sha512-IXCRip2IQzKwxArNNq1S+On4KPML3Yyn8Zzs/xRgcgOWIr8ntIK3IKzjFPfjy/7kt9ZMjc+FItfqHRBg8b6tNQ== +shiki@^0.14.7: + version "0.14.7" + resolved "https://registry.yarnpkg.com/shiki/-/shiki-0.14.7.tgz#c3c9e1853e9737845f1d2ef81b31bcfb07056d4e" + integrity sha512-dNPAPrxSc87ua2sKJ3H5dQ/6ZaY8RNnaAqK+t0eG7p0Soi2ydiqbGOTaZCqaYvA/uZYfS1LJnemt3Q+mSfcPCg== dependencies: ansi-sequence-parser "^1.1.0" jsonc-parser "^3.2.0" @@ -4140,24 +4129,6 @@ slash@^3.0.0: resolved "https://registry.yarnpkg.com/slash/-/slash-3.0.0.tgz#6539be870c165adbd5240220dbe361f1bc4d4634" integrity sha512-g9Q1haeby36OSStwb4ntCGGGaKsaVSjQ68fBxoQcutl5fS1vuY18H3wSt3jFyFtrkx+Kz0V1G85A4MyAdDMi2Q== -slice-ansi@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/slice-ansi/-/slice-ansi-3.0.0.tgz#31ddc10930a1b7e0b67b08c96c2f49b77a789787" - integrity sha512-pSyv7bSTC7ig9Dcgbw9AuRNUb5k5V6oDudjZoMBSr13qpLBG7tB+zgCkARjq7xIUgdz5P1Qe8u+rSGdouOOIyQ== - dependencies: - ansi-styles "^4.0.0" - astral-regex "^2.0.0" - is-fullwidth-code-point "^3.0.0" - -slice-ansi@^4.0.0: - version "4.0.0" - resolved "https://registry.yarnpkg.com/slice-ansi/-/slice-ansi-4.0.0.tgz#500e8dd0fd55b05815086255b3195adf2a45fe6b" - integrity sha512-qMCMfhY040cVHT43K9BFygqYbUPFZKHOg7K73mtTWJRb8pyP3fzf4Ixd5SzdEJQ6MRUg/WBnOLxghZtKKurENQ== - dependencies: - ansi-styles "^4.0.0" - astral-regex "^2.0.0" - is-fullwidth-code-point "^3.0.0" - slice-ansi@^5.0.0: version "5.0.0" resolved "https://registry.yarnpkg.com/slice-ansi/-/slice-ansi-5.0.0.tgz#b73063c57aa96f9cd881654b15294d95d285c42a" @@ -4166,19 +4137,6 @@ slice-ansi@^5.0.0: ansi-styles "^6.0.0" is-fullwidth-code-point "^4.0.0" -smart-buffer@^4.2.0: - version "4.2.0" - resolved "https://registry.yarnpkg.com/smart-buffer/-/smart-buffer-4.2.0.tgz#6e1d71fa4f18c05f7d0ff216dd16a481d0e8d9ae" - integrity sha512-94hK0Hh8rPqQl2xXc3HsaBoOXKV20MToPkcXvwbISWLEs+64sBq5kFgn2kJDHb1Pry9yrP0dxrCI9RRci7RXKg== - -socks@^2.7.1: - version "2.8.3" - resolved "https://registry.yarnpkg.com/socks/-/socks-2.8.3.tgz#1ebd0f09c52ba95a09750afe3f3f9f724a800cb5" - integrity sha512-l5x7VUUWbjVFbafGLxPWkYsHIhEvmF85tbIeFZWc8ZPtoMyybuEhL7Jye/ooC4/d48FgOjSJXgsF/AJPYCW8Zw== - dependencies: - ip-address "^9.0.5" - smart-buffer "^4.2.0" - source-map-support@0.5.13: version "0.5.13" resolved "https://registry.yarnpkg.com/source-map-support/-/source-map-support-0.5.13.tgz#31b24a9c2e73c2de85066c0feb7d44767ed52932" @@ -4232,11 +4190,6 @@ split2@^3.0.0, split2@^3.2.2: dependencies: readable-stream "^3.0.0" -sprintf-js@^1.1.3: - version "1.1.3" - resolved "https://registry.yarnpkg.com/sprintf-js/-/sprintf-js-1.1.3.tgz#4914b903a2f8b685d17fdf78a70e917e872e444a" - integrity sha512-Oo+0REFV59/rz3gfJNKQiBlwfHaSESl1pcGyABQsnnIfWOFt6JNj5gCog2U6MLZ//IGYD+nA8nI+mTShREReaA== - sprintf-js@~1.0.2: version "1.0.3" resolved "https://registry.yarnpkg.com/sprintf-js/-/sprintf-js-1.0.3.tgz#04e6926f662895354f3dd015203633b857297e2c" @@ -4257,7 +4210,7 @@ streamx@^2.15.0: fast-fifo "^1.1.0" queue-tick "^1.0.1" -string-argv@^0.3.1: +string-argv@0.3.2: version "0.3.2" resolved "https://registry.yarnpkg.com/string-argv/-/string-argv-0.3.2.tgz#2b6d0ef24b656274d957d54e0a4bbf6153dc02b6" integrity sha512-aqD2Q0144Z+/RqG52NeHEkZauTAUWJO8c6yTftGJKO3Tja5tUgIfmIl6kExvhtxSDP7fXB6DvzkfMpCd/F3G+Q== @@ -4378,10 +4331,10 @@ supports-preserve-symlinks-flag@^1.0.0: resolved "https://registry.yarnpkg.com/supports-preserve-symlinks-flag/-/supports-preserve-symlinks-flag-1.0.0.tgz#6eda4bd344a3c94aea376d4cc31bc77311039e09" integrity sha512-ot0WnXS9fgdkgIcePe6RHNk1WA8+muPa6cSjeR3V8K27q9BB1rTE3R1p7Hv0z1ZyAc8s6Vvv8DIyWf681MAt0w== -synckit@^0.8.6: - version "0.8.8" - resolved "https://registry.yarnpkg.com/synckit/-/synckit-0.8.8.tgz#fe7fe446518e3d3d49f5e429f443cf08b6edfcd7" - integrity sha512-HwOKAP7Wc5aRGYdKH+dw0PRRpbO841v2DENBtjnR5HFWoiNByAl7vrx3p0G/rCyYXQsrxqtX48TImFtPcIHSpQ== +synckit@^0.9.1: + version "0.9.1" + resolved "https://registry.yarnpkg.com/synckit/-/synckit-0.9.1.tgz#febbfbb6649979450131f64735aa3f6c14575c88" + integrity sha512-7gr8p9TQP6RAHusBOSLs46F4564ZrjV8xFmw5zCmgmhGUcw2hxsShhJ6CEiHQMgPDwAQ1fWHPM0ypc4RMAig4A== dependencies: "@pkgr/core" "^0.1.0" tslib "^2.6.2" @@ -4421,7 +4374,7 @@ through2@^4.0.0: dependencies: readable-stream "3" -"through@>=2.2.7 <3", through@^2.3.8: +"through@>=2.2.7 <3": version "2.3.8" resolved "https://registry.yarnpkg.com/through/-/through-2.3.8.tgz#0dd4c9ffaabc357960b1b724115d7e0e86a2e1f5" integrity sha512-w89qg7PI8wAdvX60bMDP+bFoD5Dvhm9oLheFp5O4a2QF0cSBGsBX4qZmadPMvVqlLJBBci+WqGGOAPvcDeNSVg== @@ -4443,12 +4396,12 @@ to-regex-range@^5.0.1: dependencies: is-number "^7.0.0" -tr46@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/tr46/-/tr46-3.0.0.tgz#555c4e297a950617e8eeddef633c87d4d9d6cbf9" - integrity sha512-l7FvfAHlcmulp8kr+flpQZmVwtu7nfRV7NZujtN0OqES8EL4O4e0qqzL0DC5gAvx/ZC/9lk6rhcUwYvkBnBnYA== +tr46@^4.1.1: + version "4.1.1" + resolved "https://registry.yarnpkg.com/tr46/-/tr46-4.1.1.tgz#281a758dcc82aeb4fe38c7dfe4d11a395aac8469" + integrity sha512-2lv/66T7e5yNyhAAC4NaKe5nVavzuGJQVVtRYLyQ2OI8tsJ61PMLlelehb0wi2Hx6+hT/OJUWZcw8MjlSRnxvw== dependencies: - punycode "^2.1.1" + punycode "^2.3.0" traverse@^0.6.7: version "0.6.7" @@ -4465,12 +4418,18 @@ trough@^1.0.0: resolved "https://registry.yarnpkg.com/trough/-/trough-1.0.5.tgz#b8b639cefad7d0bb2abd37d433ff8293efa5f406" integrity sha512-rvuRbTarPXmMb79SmzEp8aqXNKcK+y0XaB298IXueQ8I2PsrATcPBCSPyK/dDNa2iWOhKlfNnOjdAOTBU/nkFA== -ts-jest@29.1.4: - version "29.1.4" - resolved "https://registry.yarnpkg.com/ts-jest/-/ts-jest-29.1.4.tgz#26f8a55ce31e4d2ef7a1fd47dc7fa127e92793ef" - integrity sha512-YiHwDhSvCiItoAgsKtoLFCuakDzDsJ1DLDnSouTaTmdOcOwIkSzbLXduaQ6M5DRVhuZC/NYaaZ/mtHbWMv/S6Q== +ts-api-utils@^1.0.1: + version "1.3.0" + resolved "https://registry.yarnpkg.com/ts-api-utils/-/ts-api-utils-1.3.0.tgz#4b490e27129f1e8e686b45cc4ab63714dc60eea1" + integrity sha512-UQMIo7pb8WRomKR1/+MFVLTroIvDVtMX3K6OUir8ynLyzB8Jeriont2bTAtmNPa1ekAgN7YPDyf6V+ygrdU+eQ== + +ts-jest@29.2.2: + version "29.2.2" + resolved "https://registry.yarnpkg.com/ts-jest/-/ts-jest-29.2.2.tgz#0d2387bb04d39174b20a05172a968f258aedff4d" + integrity sha512-sSW7OooaKT34AAngP6k1VS669a0HdLxkQZnlC7T76sckGCokXFnvJ3yRlQZGRTAoV5K19HfSgCiSwWOSIfcYlg== dependencies: bs-logger "0.x" + ejs "^3.0.0" fast-json-stable-stringify "2.x" jest-util "^29.0.0" json5 "^2.2.3" @@ -4498,23 +4457,11 @@ ts-node@^10.8.1: v8-compile-cache-lib "^3.0.1" yn "3.1.1" -tslib@^1.8.1: - version "1.14.1" - resolved "https://registry.yarnpkg.com/tslib/-/tslib-1.14.1.tgz#cf2d38bdc34a134bcaf1091c41f6619e2f672d00" - integrity sha512-Xni35NKzjgMrwevysHTCArtLDpPvye8zV/0E4EyYn43P7/7qvQwPh9BGkHewbMulVntbigmcT7rdX3BNo9wRJg== - -tslib@^2.1.0, tslib@^2.4.0, tslib@^2.6.2, tslib@^2.6.3: +tslib@^2.4.0, tslib@^2.6.2, tslib@^2.6.3: version "2.6.3" resolved "https://registry.yarnpkg.com/tslib/-/tslib-2.6.3.tgz#0438f810ad7a9edcde7a241c3d80db693c8cbfe0" integrity sha512-xNvxJEOUiWPGhUuUdQgAJPKOOJfGnIyKySOc09XkKsgdUV/3E2zvwZYdejjmRgPCgcym1juLH3226yA7sEFJKQ== -tsutils@^3.21.0: - version "3.21.0" - resolved "https://registry.yarnpkg.com/tsutils/-/tsutils-3.21.0.tgz#b48717d394cea6c1e096983eed58e9d61715b623" - integrity sha512-mHKK3iUXL+3UF6xL5k0PEhKRUBKPBCv/+RkEOpjRWxxx27KKRBmmA60A9pgOUvMi8GKhRMPEmjBRPzs2W7O1OA== - dependencies: - tslib "^1.8.1" - type-check@^0.4.0, type-check@~0.4.0: version "0.4.0" resolved "https://registry.yarnpkg.com/type-check/-/type-check-0.4.0.tgz#07b8203bfa7056c0657050e3ccd2c37730bab8f1" @@ -4552,25 +4499,25 @@ type-fest@^0.8.1: resolved "https://registry.yarnpkg.com/type-fest/-/type-fest-0.8.1.tgz#09e249ebde851d3b1e48d27c105444667f17b83d" integrity sha512-4dbzIzqvjtgiM5rw1k5rEHtBANKmdudhGyBEajN01fEyhaAIhsoKNy6y7+IN93IfpFtwY9iqi7kD+xwKhQsNJA== -typedoc@^0.24.8: - version "0.24.8" - resolved "https://registry.yarnpkg.com/typedoc/-/typedoc-0.24.8.tgz#cce9f47ba6a8d52389f5e583716a2b3b4335b63e" - integrity sha512-ahJ6Cpcvxwaxfu4KtjA8qZNqS43wYt6JL27wYiIgl1vd38WW/KWX11YuAeZhuz9v+ttrutSsgK+XO1CjL1kA3w== +type-fest@^1.0.2: + version "1.4.0" + resolved "https://registry.yarnpkg.com/type-fest/-/type-fest-1.4.0.tgz#e9fb813fe3bf1744ec359d55d1affefa76f14be1" + integrity sha512-yGSza74xk0UG8k+pLh5oeoYirvIiWo5t0/o3zHHAO2tRDiZcxWP7fywNlXhqb6/r6sWvwi+RsyQMWhVLe4BVuA== + +typedoc@^0.25.13: + version "0.25.13" + resolved "https://registry.yarnpkg.com/typedoc/-/typedoc-0.25.13.tgz#9a98819e3b2d155a6d78589b46fa4c03768f0922" + integrity sha512-pQqiwiJ+Z4pigfOnnysObszLiU3mVLWAExSPf+Mu06G/qsc3wzbuM56SZQvONhHLncLUhYzOVkjFFpFfL5AzhQ== dependencies: lunr "^2.3.9" marked "^4.3.0" - minimatch "^9.0.0" - shiki "^0.14.1" - -typescript@5.0.4: - version "5.0.4" - resolved "https://registry.yarnpkg.com/typescript/-/typescript-5.0.4.tgz#b217fd20119bd61a94d4011274e0ab369058da3b" - integrity sha512-cW9T5W9xY37cc+jfEnaUvX91foxtHkza3Nw3wkoF4sSlKn0MONdkdEndig/qPBWXNkmplh3NzayQzCiHM4/hqw== + minimatch "^9.0.3" + shiki "^0.14.7" -"typescript@^4.6.4 || ^5.2.2": - version "5.4.5" - resolved "https://registry.yarnpkg.com/typescript/-/typescript-5.4.5.tgz#42ccef2c571fdbd0f6718b1d1f5e6e5ef006f611" - integrity sha512-vcI4UpRgg81oIRUFwR0WSIHKt11nJ7SAVlYNIu+QpqeyXP+gpQJy/Z4+F0aGxSE4MqwjyXvW/TzgkLAx2AGHwQ== +"typescript@^4.6.4 || ^5.2.2", typescript@~5.3.3: + version "5.3.3" + resolved "https://registry.yarnpkg.com/typescript/-/typescript-5.3.3.tgz#b3ce6ba258e72e6305ba66f5c9b452aaee3ffe37" + integrity sha512-pXWcraxM0uxAS+tN0AG/BF2TyqmHO014Z070UsJ+pFvYuRSq8KH8DmWpnbXe0pEPDHXZV3FcAbJkijJ5oNEnWw== underscore@^1.13.2: version "1.13.6" @@ -4706,12 +4653,12 @@ webidl-conversions@^7.0.0: resolved "https://registry.yarnpkg.com/webidl-conversions/-/webidl-conversions-7.0.0.tgz#256b4e1882be7debbf01d05f0aa2039778ea080a" integrity sha512-VwddBukDzu71offAQR975unBIGqfKZpM+8ZX6ySk8nYhVoo5CYaZyzt3YBvYtRtO+aoGlqxPg/B87NGVZ/fu6g== -whatwg-url@^11.0.0: - version "11.0.0" - resolved "https://registry.yarnpkg.com/whatwg-url/-/whatwg-url-11.0.0.tgz#0a849eebb5faf2119b901bb76fd795c2848d4018" - integrity sha512-RKT8HExMpoYx4igMiVMY83lN6UeITKJlBQ+vR/8ZJ8OCdSiN3RwCq+9gH0+Xzj0+5IrM6i4j/6LuvzbZIQgEcQ== +whatwg-url@^13.0.0: + version "13.0.0" + resolved "https://registry.yarnpkg.com/whatwg-url/-/whatwg-url-13.0.0.tgz#b7b536aca48306394a34e44bda8e99f332410f8f" + integrity sha512-9WWbymnqj57+XEuqADHrCJ2eSXzn8WXIW/YSGaZtb2WKAInQ6CHfaUUcTyyver0p8BDg5StLQq8h1vtZuwmOig== dependencies: - tr46 "^3.0.0" + tr46 "^4.1.1" webidl-conversions "^7.0.0" which@^2.0.1: @@ -4730,15 +4677,6 @@ which@^2.0.1: string-width "^4.1.0" strip-ansi "^6.0.0" -wrap-ansi@^6.2.0: - version "6.2.0" - resolved "https://registry.yarnpkg.com/wrap-ansi/-/wrap-ansi-6.2.0.tgz#e9393ba07102e6c91a3b221478f0257cd2856e53" - integrity sha512-r6lPcBGxZXlIcymEu7InxDMhdW0KDxpLgoFLcguasxCaJ/SOIZwINatK9KY/tf+ZrlywOKU0UDj3ATXUBfxJXA== - dependencies: - ansi-styles "^4.0.0" - string-width "^4.1.0" - strip-ansi "^6.0.0" - wrap-ansi@^7.0.0: version "7.0.0" resolved "https://registry.yarnpkg.com/wrap-ansi/-/wrap-ansi-7.0.0.tgz#67e145cff510a6a6984bdf1152911d69d2eb9e43" @@ -4748,7 +4686,7 @@ wrap-ansi@^7.0.0: string-width "^4.1.0" strip-ansi "^6.0.0" -wrap-ansi@^8.1.0: +wrap-ansi@^8.0.1, wrap-ansi@^8.1.0: version "8.1.0" resolved "https://registry.yarnpkg.com/wrap-ansi/-/wrap-ansi-8.1.0.tgz#56dc22368ee570face1b49819975d9b9a5ead214" integrity sha512-si7QWI6zUMq56bESFvagtmzMdGOtoxfR+Sez11Mobfc7tm+VkUckk9bW2UeffTGVUbOksxmSw0AA2gs8g71NCQ== @@ -4785,10 +4723,10 @@ yallist@^4.0.0: resolved "https://registry.yarnpkg.com/yallist/-/yallist-4.0.0.tgz#9bb92790d9c0effec63be73519e11a35019a3a72" integrity sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A== -yaml@^2.2.2: - version "2.3.2" - resolved "https://registry.yarnpkg.com/yaml/-/yaml-2.3.2.tgz#f522db4313c671a0ca963a75670f1c12ea909144" - integrity sha512-N/lyzTPaJasoDmfV7YTrYCI0G/3ivm/9wdG0aHuheKowWQwGTsK0Eoiw6utmzAnI6pkJa0DUVygvp3spqqEKXg== +yaml@2.3.1: + version "2.3.1" + resolved "https://registry.yarnpkg.com/yaml/-/yaml-2.3.1.tgz#02fe0975d23cd441242aa7204e09fc28ac2ac33b" + integrity sha512-2eHWfjaoXgTBC2jNM1LRef62VQa0umtvRiDSk6HSzW7RvS5YtkabJrwYLLEKWBc8a5U2PTSCs+dJjUTJdlHsWQ== yargs-parser@^20.2.3: version "20.2.9"