Skip to content

Commit 5a2c455

Browse files
bump TS, make named providers require config
1 parent 1c63e68 commit 5a2c455

File tree

4 files changed

+27
-12
lines changed

4 files changed

+27
-12
lines changed

.evergreen/config.yml

Lines changed: 17 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3500,9 +3500,9 @@ tasks:
35003500
- {key: TS_VERSION, value: current}
35013501
- func: install dependencies
35023502
- func: check types
3503-
- name: check-types-typescript-4.1.6
3503+
- name: compile-driver-typescript-4.4.0
35043504
tags:
3505-
- check-types-typescript-4.1.6
3505+
- compile-driver-typescript-4.4.0
35063506
- typescript-compilation
35073507
commands:
35083508
- command: expansions.update
@@ -3511,7 +3511,21 @@ tasks:
35113511
updates:
35123512
- {key: NODE_LTS_VERSION, value: '16'}
35133513
- {key: NPM_VERSION, value: '9'}
3514-
- {key: TS_VERSION, value: 4.1.6}
3514+
- {key: TS_VERSION, value: 4.4.0}
3515+
- func: install dependencies
3516+
- func: compile driver
3517+
- name: check-types-typescript-4.4.0
3518+
tags:
3519+
- check-types-typescript-4.4.0
3520+
- typescript-compilation
3521+
commands:
3522+
- command: expansions.update
3523+
type: setup
3524+
params:
3525+
updates:
3526+
- {key: NODE_LTS_VERSION, value: '16'}
3527+
- {key: NPM_VERSION, value: '9'}
3528+
- {key: TS_VERSION, value: 4.4.0}
35153529
- func: install dependencies
35163530
- func: check types
35173531
- name: download-and-merge-coverage

.evergreen/generate_evergreen_tasks.js

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -497,9 +497,10 @@ SINGLETON_TASKS.push(
497497
);
498498

499499
function* makeTypescriptTasks() {
500-
for (const TS_VERSION of ['next', 'current', '4.1.6']) {
501-
// 4.1.6 can consume the public API but not compile the driver
502-
if (TS_VERSION !== '4.1.6' && TS_VERSION !== 'next') {
500+
for (const TS_VERSION of ['next', 'current', '4.4.0']) {
501+
// We don't compile on next, because compilation errors are likely. We do expect
502+
// that the drivers types continue to work with next though.
503+
if (TS_VERSION !== 'next') {
503504
yield {
504505
name: `compile-driver-typescript-${TS_VERSION}`,
505506
tags: [`compile-driver-typescript-${TS_VERSION}`, 'typescript-compilation'],

README.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -27,9 +27,9 @@ The official [MongoDB](https://www.mongodb.com/) driver for Node.js.
2727
The GitHub release contains a detached signature file for the NPM package (named
2828
`mongodb-X.Y.Z.tgz.sig`).
2929

30-
The following command returns the link npm package.
30+
The following command returns the link npm package.
3131
```shell
32-
npm view [email protected] dist.tarball
32+
npm view [email protected] dist.tarball
3333
```
3434

3535
Using the result of the above command, a `curl` command can return the official npm package for the release.
@@ -81,7 +81,7 @@ The following table describes add-on component version compatibility for the Nod
8181

8282
#### Typescript Version
8383

84-
We recommend using the latest version of typescript, however we currently ensure the driver's public types compile against `typescript@4.1.6`.
84+
We recommend using the latest version of typescript, however we currently ensure the driver's public types compile against `typescript@4.4.0`.
8585
This is the lowest typescript version guaranteed to work with our driver: older versions may or may not work - use at your own risk.
8686
Since typescript [does not restrict breaking changes to major versions](https://github.com/Microsoft/TypeScript/wiki/Breaking-Changes), we consider this support best effort.
8787
If you run into any unexpected compiler failures against our supported TypeScript versions, please let us know by filing an issue on our [JIRA](https://jira.mongodb.org/browse/NODE).

src/client-side-encryption/providers/index.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -122,7 +122,7 @@ export interface KMSProviders {
122122
* Configuration options for using 'aws' as your KMS provider
123123
*/
124124
aws?: AWSKMSProviderConfiguration | Record<string, never>;
125-
[key: `aws:${string}`]: AWSKMSProviderConfiguration | Record<string, never>;
125+
[key: `aws:${string}`]: AWSKMSProviderConfiguration;
126126

127127
/**
128128
* Configuration options for using 'local' as your KMS provider
@@ -140,13 +140,13 @@ export interface KMSProviders {
140140
* Configuration options for using 'azure' as your KMS provider
141141
*/
142142
azure?: AzureKMSProviderConfiguration | Record<string, never>;
143-
[key: `azure:${string}`]: AzureKMSProviderConfiguration | Record<string, never>;
143+
[key: `azure:${string}`]: AzureKMSProviderConfiguration;
144144

145145
/**
146146
* Configuration options for using 'gcp' as your KMS provider
147147
*/
148148
gcp?: GCPKMSProviderConfiguration | Record<string, never>;
149-
[key: `gcp:${string}`]: GCPKMSProviderConfiguration | Record<string, never>;
149+
[key: `gcp:${string}`]: GCPKMSProviderConfiguration;
150150
}
151151

152152
/**

0 commit comments

Comments
 (0)