From 3dbf2bc7bf02e0ad34e51dc8e0869ca1894e347d Mon Sep 17 00:00:00 2001 From: rjrodger Date: Mon, 25 Feb 2019 19:45:20 +0000 Subject: [PATCH] v3.8.3 --- .travis.yml | 1 - CHANGES.md | 6 ++++++ lib/common.js | 1 - lib/inward.js | 6 ++++-- package.json | 2 +- test/api.test.js | 2 +- test/message.test.js | 5 ++++- 7 files changed, 16 insertions(+), 7 deletions(-) diff --git a/.travis.yml b/.travis.yml index 8aa6cf94..1c73a6b7 100644 --- a/.travis.yml +++ b/.travis.yml @@ -12,7 +12,6 @@ env: matrix: - TEST_SUITE=senecajs/seneca - TEST_SUITE=senecajs/seneca-entity - - TEST_SUITE=senecajs/seneca-promisify install: - NODE_VERSION=$(node -v); if [ ${NODE_VERSION:1:2} -ge 10 ]; then npm i -g npm@6; npm ci; else npm install; fi diff --git a/CHANGES.md b/CHANGES.md index 11e30db3..2416e741 100644 --- a/CHANGES.md +++ b/CHANGES.md @@ -1,3 +1,9 @@ +## 3.8.3 2019-02-25 + +* Seneca.fail throws Seneca Errors, whereas Seneca.error creates them +* Seneca.error can create plugin scoped errors + + ## 3.8.2 2019-02-17 * Allow plugin names that are file paths, and allow . in plugin names and tags. diff --git a/lib/common.js b/lib/common.js index 07c3c0fa..e1bfdb51 100644 --- a/lib/common.js +++ b/lib/common.js @@ -17,7 +17,6 @@ var error = (exports.error = exports.eraro = Eraro({ override: true })) - exports.make_plugin_key = function(plugin, origtag) { if (null == plugin) { throw error('missing_plugin_name') diff --git a/lib/inward.js b/lib/inward.js index 9705530d..f882a02d 100644 --- a/lib/inward.js +++ b/lib/inward.js @@ -34,8 +34,10 @@ function inward_limit_msg(ctxt, data) { info: { maxparents: so.limits.maxparents, numparents: meta.parents.length, - parents: _.map(meta.parents, - p => p[Common.TRACE_PATTERN]+' '+p[Common.TRACE_ACTION]), + parents: _.map( + meta.parents, + p => p[Common.TRACE_PATTERN] + ' ' + p[Common.TRACE_ACTION] + ), args: Util.inspect(Common.clean(data.msg)).replace(/\n/g, '') } } diff --git a/package.json b/package.json index 69a2f891..4a2adc73 100644 --- a/package.json +++ b/package.json @@ -1,7 +1,7 @@ { "name": "seneca", "description": "A Microservices Framework for Node.js", - "version": "3.8.2", + "version": "3.8.3", "license": "MIT", "homepage": "http://senecajs.org", "keywords": [ diff --git a/test/api.test.js b/test/api.test.js index 3236eb3e..f645c2bc 100644 --- a/test/api.test.js +++ b/test/api.test.js @@ -226,7 +226,7 @@ describe('api', function() { expect(si.has('g:1')).equal(false) expect(si.has('h:1,g:1')).equal(true) expect(si.has('h:1,g:1,x:1')).equal(false) - + fin() }) diff --git a/test/message.test.js b/test/message.test.js index 2c31f910..2866b8a2 100644 --- a/test/message.test.js +++ b/test/message.test.js @@ -115,7 +115,10 @@ describe('message', function() { expect(i).equal(4) expect(err.code).equal('maxparents') expect(err.details.parents).equal([ - 'a:1 a1_8', 'a:1 a1_8', 'a:1 a1_8', 'a:1 a1_8' + 'a:1 a1_8', + 'a:1 a1_8', + 'a:1 a1_8', + 'a:1 a1_8' ]) fin() })