From fe6fb6fd6782c44b6397c503342e26347a534016 Mon Sep 17 00:00:00 2001 From: Yiannis Giannelos Date: Fri, 8 Apr 2022 18:16:06 +0200 Subject: [PATCH 1/3] Fix compatibility with latest mapnik --- index.js | 4 ++-- package.json | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/index.js b/index.js index 46cf362..9728928 100644 --- a/index.js +++ b/index.js @@ -88,7 +88,7 @@ Vector.prototype.close = function(callback) { Vector.prototype.update = function(opts, callback) { var s = this; var map = new mapnik.Map(256,256); - map.fromString(opts.xml, { + map.fromString(opts.xml.data, { strict: module.exports.strict, base: this._base + path.sep }, function(err) { @@ -100,7 +100,7 @@ Vector.prototype.update = function(opts, callback) { delete s._info; s._xml = opts.xml; s._map = map; - s._md5 = crypto.createHash('md5').update(opts.xml).digest('hex'); + s._md5 = crypto.createHash('md5').update(opts.xml.data).digest('hex'); s._format = opts.format || map.parameters.format || s._format || 'png8:m=h'; s._scale = opts.scale || +map.parameters.scale || s._scale || 1; diff --git a/package.json b/package.json index 42f380e..933bb4c 100644 --- a/package.json +++ b/package.json @@ -37,7 +37,7 @@ "tape": "2.13.x" }, "peerDependencies": { - "@kartotherian/mapnik": "~3.7.3" + "mapnik": "^4.5.9" }, "scripts": { "test": "tape test/*.js", From d0b001138420d8c3a2b533c57998867dfe9a42fb Mon Sep 17 00:00:00 2001 From: Yiannis Giannelos Date: Fri, 8 Apr 2022 20:10:00 +0200 Subject: [PATCH 2/3] Update dependencies --- package.json | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/package.json b/package.json index 933bb4c..0001187 100644 --- a/package.json +++ b/package.json @@ -16,25 +16,25 @@ "Yuri Astrakhan " ], "dependencies": { - "@mapbox/sphericalmercator": "~1.0.5", - "@mapbox/tilelive": "~5.12.0", - "@mapbox/tiletype": "0.3.x", + "@mapbox/sphericalmercator": "^1.2.0", + "@mapbox/tilelive": "^6.1.0", + "@mapbox/tiletype": "^0.3.1", "aws-sdk": "^2.2.30", "numeral": "~1.5.3", - "request": "~2.83.0", + "request": "^2.88.2", "s3urls": "^1.3.0", "spherical": "~0.1.0", - "tar": "~2.2.1", + "tar": "^6.1.11", "tilelive-promise": "^2.0.0", - "underscore": "~1.8.0" + "underscore": "^1.13.2" }, "devDependencies": { "@mapbox/mapbox-studio-default-style": "2.0.0", "@mapbox/tilejson": "^1.1.0", "coveralls": "~2.11.2", - "istanbul": "~0.3.17", + "istanbul": "^0.4.5", "simple-statistics": "~0.8.0", - "tape": "2.13.x" + "tape": "^5.5.2" }, "peerDependencies": { "mapnik": "^4.5.9" From 92d8d60bd28b260dc096ac386796a267d2d195db Mon Sep 17 00:00:00 2001 From: Yiannis Giannelos Date: Fri, 8 Apr 2022 20:14:24 +0200 Subject: [PATCH 3/3] Bump package version --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index 0001187..62bd2b1 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@kartotherian/tilelive-vector", - "version": "4.0.3-alpha.0", + "version": "4.0.3-wikimedia.1", "main": "./index.js", "description": "Vector tile => raster tile backend for tilelive", "repository": {