File tree Expand file tree Collapse file tree 9 files changed +227
-261
lines changed Expand file tree Collapse file tree 9 files changed +227
-261
lines changed Original file line number Diff line number Diff line change 2929 "homepage" : " https://github.com/databricks/databricks-vscode#readme" ,
3030 "packageManager" : " yarn@3.2.1" ,
3131 "devDependencies" : {
32- "@typescript-eslint/eslint-plugin" : " ^5.32 .0" ,
33- "@typescript-eslint/parser" : " ^5.32 .0" ,
32+ "@typescript-eslint/eslint-plugin" : " ^5.33 .0" ,
33+ "@typescript-eslint/parser" : " ^5.33 .0" ,
3434 "eslint" : " ^8.21.0" ,
3535 "eslint-config-prettier" : " ^8.5.0" ,
3636 "typescript" : " ^4.7.4"
Original file line number Diff line number Diff line change 1717 " /dist"
1818 ],
1919 "scripts" : {
20- "build" : " tsc -p tsconfig.json" ,
20+ "build" : " tsc -p tsconfig.json && cp src/fetch.* dist/ " ,
2121 "watch" : " tsc -w -p tsconfig.json" ,
2222 "clean" : " rm -rf dist node_modules" ,
2323 "fix" : " prettier . --write" ,
3030 },
3131 "dependencies" : {
3232 "ini" : " ^3.0.0" ,
33- "node-fetch" : " ^2.6.7 "
33+ "node-fetch" : " ^3.2.10 "
3434 },
3535 "devDependencies" : {
3636 "@istanbuljs/nyc-config-typescript" : " ^1.0.2" ,
3737 "@types/ini" : " ^1.3.31" ,
3838 "@types/mocha" : " ^9.1.1" ,
39- "@types/node" : " ^18.6.4" ,
40- "@types/node-fetch" : " ^2.6.2" ,
39+ "@types/node" : " ^18.7.1" ,
4140 "@types/tmp" : " ^0.2.3" ,
4241 "@types/uuid" : " ^8.3.4" ,
4342 "eslint" : " ^8.21.0" ,
Original file line number Diff line number Diff line change 11/* eslint-disable @typescript-eslint/naming-convention */
2- import fetch from "node-fetch" ;
32import * as https from "node:https" ;
43import { TextDecoder } from "node:util" ;
54import { fromDefaultChain } from "./auth/fromChain" ;
5+ import { fetch } from "./fetch" ;
66
77const sdkVersion = require ( "../package.json" ) . version ;
88
Original file line number Diff line number Diff line change 1+ /**
2+ * @param { import("node-fetch").RequestInfo } url
3+ * @param {import("node-fetch").RequestInit } init
4+ * @returns {Promise<import("node-fetch").Response> }
5+ */
6+ export function fetch (
7+ url : import ( "node-fetch" ) . RequestInfo ,
8+ init : import ( "node-fetch" ) . RequestInit
9+ ) : Promise < import ( "node-fetch" ) . Response > ;
Original file line number Diff line number Diff line change 1+ // node-fetch@3 is ESM only. Need some trickery to make it work with CommonJS
2+
3+ exports . fetch = async function ( url , init ) {
4+ const { default : fetch } = await import ( "node-fetch" ) ;
5+ return await fetch ( url , init ) ;
6+ } ;
Original file line number Diff line number Diff line change 22
33import { v4 as uuidv4 } from "uuid" ;
44import { ApiClient } from "../api-client" ;
5- import { ClusterService } from "../apis/cluster" ;
65import { Cluster } from "../services/Cluster" ;
76
87export class IntegrationTestSetup {
Original file line number Diff line number Diff line change 66 "moduleResolution" : " Node" ,
77 "esModuleInterop" : true ,
88 "isolatedModules" : true ,
9- "lib" : [" ES2020" ],
9+ "lib" : [" ES2020" , " DOM " ],
1010 "sourceMap" : true ,
1111 "rootDir" : " src" ,
1212 "outDir" : " dist" ,
1313 "strict" : true /* enable all strict type-checking options */ ,
1414 "experimentalDecorators" : true
15- }
15+ },
16+ "include" : [" src" ]
1617}
Original file line number Diff line number Diff line change 290290 "@istanbuljs/nyc-config-typescript" : " ^1.0.2" ,
291291 "@types/glob" : " ^7.2.0" ,
292292 "@types/mocha" : " ^9.1.1" ,
293- "@types/node" : " ^18.6.4 " ,
293+ "@types/node" : " ^18.7.1 " ,
294294 "@types/tmp" : " ^0.2.3" ,
295295 "@types/vscode" : " ^1.69.1" ,
296- "@typescript-eslint/eslint-plugin" : " ^5.32 .0" ,
297- "@typescript-eslint/parser" : " ^5.32 .0" ,
296+ "@typescript-eslint/eslint-plugin" : " ^5.33 .0" ,
297+ "@typescript-eslint/parser" : " ^5.33 .0" ,
298298 "@vscode/test-electron" : " ^2.1.5" ,
299- "esbuild" : " ^0.14.53 " ,
299+ "esbuild" : " ^0.15.1 " ,
300300 "eslint" : " ^8.21.0" ,
301301 "glob" : " ^8.0.3" ,
302302 "mocha" : " ^10.0.0" ,
306306 "ts-mockito" : " ^2.6.1" ,
307307 "typescript" : " ^4.7.4" ,
308308 "vsce" : " ^2.10.0" ,
309- "vscode-extension-tester" : " ^4.4.0 "
309+ "vscode-extension-tester" : " ^4.4.1 "
310310 },
311311 "nyc" : {
312312 "extends" : " @istanbuljs/nyc-config-typescript" ,
You can’t perform that action at this time.
0 commit comments