From a2baa91913365b6c125c17cc79172c0a82bcc242 Mon Sep 17 00:00:00 2001 From: snyk-bot Date: Sun, 7 Jan 2024 17:50:43 +0000 Subject: [PATCH 1/2] fix: upgrade sqlite-wasm-http from 1.1.2 to 1.2.0 Snyk has created this PR to upgrade sqlite-wasm-http from 1.1.2 to 1.2.0. See this package in npm: https://www.npmjs.com/package/sqlite-wasm-http See this project in Snyk: https://app.snyk.io/org/mmomtchev/project/f179785a-f5dc-4dc2-b2fa-7740f2ace43b?utm_source=github&utm_medium=referral&page=upgrade-pr --- package-lock.json | 8 ++++---- package.json | 2 +- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/package-lock.json b/package-lock.json index a2f91a0..5120b10 100644 --- a/package-lock.json +++ b/package-lock.json @@ -12,7 +12,7 @@ "@mapbox/vector-tile": "^1.3.1", "pako": "^2.1.0", "pbf": "^3.2.1", - "sqlite-wasm-http": "^1.1.2" + "sqlite-wasm-http": "^1.2.0" }, "devDependencies": { "@rollup/plugin-typescript": "^11.1.5", @@ -8370,9 +8370,9 @@ } }, "node_modules/sqlite-wasm-http": { - "version": "1.1.2", - "resolved": "https://registry.npmjs.org/sqlite-wasm-http/-/sqlite-wasm-http-1.1.2.tgz", - "integrity": "sha512-v2R0GNGRumTmDfDOfX7uZisLbGkyJYSCWupL8j0JRPExMONNwNVs8TkcvZJNk/VdLUkwVODOM4hdDRQGQLCaCg==", + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/sqlite-wasm-http/-/sqlite-wasm-http-1.2.0.tgz", + "integrity": "sha512-mTZw4MHSw/dsO7PhAZeV14WIiVw/e8ECJSDV5oMEgInbCw+ITP/Y8YqbzggDiWRoPpbJ+uPoOXe5myIQbX6XxQ==", "dependencies": { "lru-cache": "^7.18.2" }, diff --git a/package.json b/package.json index a8c4466..20b9545 100644 --- a/package.json +++ b/package.json @@ -42,7 +42,7 @@ "@mapbox/vector-tile": "^1.3.1", "pako": "^2.1.0", "pbf": "^3.2.1", - "sqlite-wasm-http": "^1.1.2" + "sqlite-wasm-http": "^1.2.0" }, "peerDependencies": { "ol": ">=7.0.0" From f93e392ed65888113b2d03337f1fe8028ff5cf27 Mon Sep 17 00:00:00 2001 From: Momtchil Momtchev Date: Fri, 19 Jan 2024 11:46:49 +0100 Subject: [PATCH 2/2] adapt to the new sqlite3 error message --- test/metadata.test.ts | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/test/metadata.test.ts b/test/metadata.test.ts index 5175c00..9c4c0e1 100644 --- a/test/metadata.test.ts +++ b/test/metadata.test.ts @@ -92,8 +92,9 @@ describe('importMBTiles', () => { done('entered the event horizon'); }) .catch((e) => { - assert.equal(e.result.message, 'sqlite3 result code 14: unable to open database file'); + assert.match(e.result.message, /SQLITE_CANTOPEN/); done(); - }); + }) + .catch(done); }); -}); \ No newline at end of file +});