[Pkg-javascript-commits] [node-socket.io-parser] 01/05: New upstream version 2.3.1
Paolo Greppi
paolog-guest at moszumanska.debian.org
Wed Dec 28 21:15:04 UTC 2016
This is an automated email from the git hooks/post-receive script.
paolog-guest pushed a commit to branch master
in repository node-socket.io-parser.
commit 4547dfc24f8a56171dce9fd6622b9c752320d27d
Author: Paolo Greppi <paolo.greppi at libpf.com>
Date: Wed Dec 28 18:07:15 2016 +0000
New upstream version 2.3.1
---
.npmignore | 5 -----
.travis.yml | 44 +++++++++++++++++++++++++++++++++++++++-----
.zuul.yml | 19 ++++---------------
History.md | 30 ++++++++++++++++++++++++++++++
LICENSE | 20 ++++++++++++++++++++
Makefile | 18 +++++++++++++++++-
Readme.md | 8 ++++----
index.js | 22 +++++++++++++---------
package.json | 20 +++++++++++++-------
9 files changed, 140 insertions(+), 46 deletions(-)
diff --git a/.npmignore b/.npmignore
deleted file mode 100644
index 7fbb06f..0000000
--- a/.npmignore
+++ /dev/null
@@ -1,5 +0,0 @@
-node_modules
-build
-components
-
-test
diff --git a/.travis.yml b/.travis.yml
index c1c830a..0238770 100644
--- a/.travis.yml
+++ b/.travis.yml
@@ -1,11 +1,45 @@
language: node_js
+sudo: false
node_js:
- - 0.10
+ - '0.10'
+ - '0.12'
+ - '4'
+ - 'node'
notifications:
irc: irc.freenode.org##socket.io
git:
depth: 1
-env:
- global:
- - secure: 28HHk1J0H64KNjzmmlxG/Ro0EPuLnhO0rU+kZjjthDHj/FaugIsqjAVQ1Dl6heWV2/MlVzw6nDCyMNiGwiVk0ruZPQ0SYdAKLplrdMtzAihbU3xx+ULFQPLM3SoW0ZFCEpe8dWPGy4WdgW7aLByeel9TJb3vlhAu7p7AvrcO7Fs=
- - secure: rKEG0Cfw0vkw8thk63RHYG7h8XWYcBlvZ0w1IWpr2dAfnnLMi1palSTrBrFQc77flk7rN00zGIe76FhKydV9r4WWYAUYKPqo4k+9/FkpzjZlNtL49QRoNwC9jmJ8OeUwGowA13gZPyl/5P13wVaKCB0YrKnzz5LHo3Sp7So6J8U=
+matrix:
+ include:
+ - node_js: '0.12'
+ env: BROWSER_NAME=chrome BROWSER_VERSION=latest
+ - node_js: '0.12'
+ env: BROWSER_NAME=safari BROWSER_VERSION=latest
+ - node_js: '0.12'
+ env: BROWSER_NAME=firefox BROWSER_VERSION=latest BROWSER_PLATFORM="Windows 10"
+ - node_js: '0.12'
+ env: BROWSER_NAME=ie BROWSER_VERSION=6
+ - node_js: '0.12'
+ env: BROWSER_NAME=ie BROWSER_VERSION=7
+ - node_js: '0.12'
+ env: BROWSER_NAME=ie BROWSER_VERSION=8
+ - node_js: '0.12'
+ env: BROWSER_NAME=ie BROWSER_VERSION=9
+ - node_js: '0.12'
+ env: BROWSER_NAME=ie BROWSER_VERSION=10 BROWSER_PLATFORM="Windows 2012"
+ - node_js: '0.12'
+ env: BROWSER_NAME=ie BROWSER_VERSION=latest BROWSER_PLATFORM="Windows 2012"
+ - node_js: '0.12'
+ env: BROWSER_NAME=microsoftedge BROWSER_VERSION=13 BROWSER_PLATFORM="Windows 10"
+ - node_js: '0.12'
+ env: BROWSER_NAME=iphone BROWSER_VERSION=8.4
+ - node_js: '0.12'
+ env: BROWSER_NAME=iphone BROWSER_VERSION=9.2
+ - node_js: '0.12'
+ env: BROWSER_NAME=android BROWSER_VERSION=4.3
+ - node_js: '0.12'
+ env: BROWSER_NAME=android BROWSER_VERSION=4.4
+ - node_js: '0.12'
+ env: BROWSER_NAME=android BROWSER_VERSION=5.1
+ - node_js: '0.12'
+ env: BROWSER_NAME=android BROWSER_VERSION=latest
diff --git a/.zuul.yml b/.zuul.yml
index 38bc342..2cc4b3c 100644
--- a/.zuul.yml
+++ b/.zuul.yml
@@ -1,16 +1,5 @@
ui: mocha-bdd
-browsers:
- - name: chrome
- version: 29..latest
- - name: firefox
- version: latest
- - name: safari
- version: latest
- - name: ie
- version: 10
- platform: Windows 2012
- - name: ie
- version: 9
- version: [6..9, latest]
- - name: iphone
- version: oldest..latest
+tunnel:
+ type: ngrok
+ authtoken: 6Aw8vTgcG5EvXdQywVvbh_3fMxvd4Q7dcL2caAHAFjV
+ proto: tcp
diff --git a/History.md b/History.md
index eaad1b9..cdceb39 100644
--- a/History.md
+++ b/History.md
@@ -1,4 +1,34 @@
+2.3.1 / 2016-10-24
+==================
+
+* [chore] Revert "Remove deprecated isarray dependency" (#50)
+
+2.3.0 / 2016-10-21
+==================
+
+ * [perf] Split try catch into separate function (#40)
+ * [chore] remove browsers setting from .zuul.yml (#34)
+ * [chore] bump zuul (#37)
+ * [chore] Bump zuul to 3.11.0 & zuul-ngrok to 4.0.0 (#41)
+ * [chore] Update zuul browser settings following EOL notices (#42)
+ * [chore] Restrict files included in npm package (#45)
+ * [chore] Update zuul browser settings (#44)
+ * [chore] Remove deprecated isarray dependency (#46)
+ * [chore] Make the build status badge point towards master (#47)
+ * [chore] Move benchmark to dev dependencies (#48)
+
+2.2.6 / 2015-11-25
+==================
+
+ * fix the order of exported events [chylli]
+
+2.2.5 / 2015-11-21
+==================
+
+ * package: bump debug
+ * update JSON3 to 3.3.2
+
2.2.4 / 2015-03-03
==================
diff --git a/LICENSE b/LICENSE
new file mode 100644
index 0000000..7e43606
--- /dev/null
+++ b/LICENSE
@@ -0,0 +1,20 @@
+(The MIT License)
+
+Copyright (c) 2014 Guillermo Rauch <guillermo at learnboost.com>
+
+Permission is hereby granted, free of charge, to any person obtaining a copy of
+this software and associated documentation files (the 'Software'), to deal in
+the Software without restriction, including without limitation the rights to
+use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
+the Software, and to permit persons to whom the Software is furnished to do so,
+subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in all
+copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
+FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
+COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
+IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
+CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
diff --git a/Makefile b/Makefile
index ee0a3b2..80912ed 100644
--- a/Makefile
+++ b/Makefile
@@ -2,10 +2,26 @@
REPORTER = dot
test:
+ @if [ "x$(BROWSER_NAME)" = "x" ]; then make test-node; else make test-zuul; fi
+
+test-node:
@./node_modules/.bin/mocha \
--reporter $(REPORTER) \
--bail \
test/index.js
- @./node_modules/.bin/zuul -- test/index.js
+
+test-zuul:
+ @if [ "x$(BROWSER_PLATFORM)" = "x" ]; then \
+ ./node_modules/zuul/bin/zuul \
+ --browser-name $(BROWSER_NAME) \
+ --browser-version $(BROWSER_VERSION) \
+ test/index.js; \
+ else \
+ ./node_modules/zuul/bin/zuul \
+ --browser-name $(BROWSER_NAME) \
+ --browser-version $(BROWSER_VERSION) \
+ --browser-platform "$(BROWSER_PLATFORM)" \
+ test/index.js; \
+ fi
.PHONY: test
diff --git a/Readme.md b/Readme.md
index 2fa0f82..2463bc7 100644
--- a/Readme.md
+++ b/Readme.md
@@ -1,13 +1,13 @@
# socket.io-parser
-[![Build Status](https://secure.travis-ci.org/Automattic/socket.io-parser.svg)](http://travis-ci.org/Automattic/socket.io-parser)
+[![Build Status](https://secure.travis-ci.org/socketio/socket.io-parser.svg?branch=master)](http://travis-ci.org/socketio/socket.io-parser)
[![NPM version](https://badge.fury.io/js/socket.io-parser.svg)](http://badge.fury.io/js/socket.io-parser)
A socket.io encoder and decoder written in JavaScript complying with version `3`
-of [socket.io-protocol](https://github.com/learnboost/socket.io-protocol).
-Used by [socket.io](https://github.com/learnboost/socket.io) and
-[socket.io-client](https://github.com/learnboost/socket.io-client).
+of [socket.io-protocol](https://github.com/socketio/socket.io-protocol).
+Used by [socket.io](https://github.com/automattic/socket.io) and
+[socket.io-client](https://github.com/automattic/socket.io-client).
## Parser API
diff --git a/index.js b/index.js
index 4149558..165a4a6 100644
--- a/index.js
+++ b/index.js
@@ -5,7 +5,6 @@
var debug = require('debug')('socket.io-parser');
var json = require('json3');
-var isArray = require('isarray');
var Emitter = require('component-emitter');
var binary = require('./binary');
var isBuf = require('./is-buffer');
@@ -28,10 +27,10 @@ exports.types = [
'CONNECT',
'DISCONNECT',
'EVENT',
- 'BINARY_EVENT',
'ACK',
- 'BINARY_ACK',
- 'ERROR'
+ 'ERROR',
+ 'BINARY_EVENT',
+ 'BINARY_ACK'
];
/**
@@ -323,17 +322,22 @@ function decodeString(str) {
// look up json data
if (str.charAt(++i)) {
- try {
- p.data = json.parse(str.substr(i));
- } catch(e){
- return error();
- }
+ p = tryParse(p, str.substr(i));
}
debug('decoded %s as %j', str, p);
return p;
}
+function tryParse(p, str) {
+ try {
+ p.data = json.parse(str);
+ } catch(e){
+ return error();
+ }
+ return p;
+};
+
/**
* Deallocates a parser's resources
*
diff --git a/package.json b/package.json
index b92c925..94788e2 100644
--- a/package.json
+++ b/package.json
@@ -1,22 +1,28 @@
{
"name": "socket.io-parser",
- "version": "2.2.4",
+ "version": "2.3.1",
"description": "socket.io protocol parser",
"repository": {
"type": "git",
"url": "https://github.com/Automattic/socket.io-parser.git"
},
+ "files": [
+ "binary.js",
+ "index.js",
+ "is-buffer.js"
+ ],
"dependencies": {
- "debug": "0.7.4",
- "json3": "3.2.6",
+ "debug": "2.2.0",
+ "json3": "3.3.2",
"component-emitter": "1.1.2",
- "isarray": "0.0.1",
- "benchmark": "1.0.0"
+ "isarray": "0.0.1"
},
"devDependencies": {
- "mocha": "1.16.2",
+ "benchmark": "1.0.0",
"expect.js": "0.2.0",
- "zuul": "1.6.3"
+ "mocha": "1.16.2",
+ "zuul": "3.11.0",
+ "zuul-ngrok": "4.0.0"
},
"scripts": {
"test": "make test"
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-javascript/node-socket.io-parser.git
More information about the Pkg-javascript-commits
mailing list