Skip to content

Commit 8c7db8f

Browse files
authored
3.4.0 (#677)
1 parent 4dba6fe commit 8c7db8f

25 files changed

+74
-54
lines changed

CHANGELOG.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,10 @@
11
# Changelog
22

3+
## 3.4.0
4+
* CHANGE: React Native plugin now stores errors in AsyncStorage and sends error data on app init. See: https://github.com/getsentry/raven-js/pull/626
5+
* BUGFIX: React Native path normalization regex has been updated. See: https://github.com/getsentry/raven-js/pull/666
6+
* BUGFIX: Angular 1 plugin now extracts errors from minified exception strings. See: https://github.com/getsentry/raven-js/pull/667
7+
38
## 3.3.0
49
* NEW: Can now specify `environment` configuration option. See: https://github.com/getsentry/raven-js/pull/661
510
* CHANGE: Raven.js now serializes data payload w/ json-stringify-safe to avoid circular references. See: https://github.com/getsentry/raven-js/pull/652

bower.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "raven-js",
3-
"version": "3.3.0",
3+
"version": "3.4.0",
44
"dependencies": {},
55
"main": "dist/raven.js",
66
"ignore": [

dist/plugins/angular.js

Lines changed: 24 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
/*! Raven.js 3.3.0 (74c6c03) | github.com/getsentry/raven-js */
1+
/*! Raven.js 3.4.0 (4dba6fe) | github.com/getsentry/raven-js */
22

33
/*
44
* Includes TraceKit
@@ -19,7 +19,8 @@
1919
'use strict';
2020

2121
// See https://github.com/angular/angular.js/blob/v1.4.7/src/minErr.js
22-
var angularPattern = /^\[((?:[$a-zA-Z0-9]+:)?(?:[$a-zA-Z0-9]+))\] (.+?)\n(\S+)$/;
22+
var angularPattern = /^\[((?:[$a-zA-Z0-9]+:)?(?:[$a-zA-Z0-9]+))\] (.*?)\n?(\S+)$/;
23+
2324

2425
function angularPlugin(Raven, angular) {
2526
angular = angular || window.angular;
@@ -51,25 +52,31 @@ function angularPlugin(Raven, angular) {
5152
.config(['$provide', ExceptionHandlerProvider]);
5253

5354
Raven.setDataCallback(function(data, original) {
54-
// We only care about mutating an exception
55-
var exception = data.exception;
56-
if (exception) {
57-
exception = exception.values[0];
58-
var matches = angularPattern.exec(exception.value);
59-
60-
if (matches) {
61-
// This type now becomes something like: $rootScope:inprog
62-
exception.type = matches[1];
63-
exception.value = matches[2];
64-
data.message = exception.type + ': ' + exception.value;
65-
// auto set a new tag specifically for the angular error url
66-
data.extra.angularDocs = matches[3].substr(0, 250);
67-
}
68-
}
55+
angularPlugin._normalizeData(data);
56+
6957
original && original(data);
7058
});
7159
}
7260

61+
angularPlugin._normalizeData = function (data) {
62+
// We only care about mutating an exception
63+
var exception = data.exception;
64+
if (exception) {
65+
exception = exception.values[0];
66+
var matches = angularPattern.exec(exception.value);
67+
68+
if (matches) {
69+
// This type now becomes something like: $rootScope:inprog
70+
exception.type = matches[1];
71+
exception.value = matches[2];
72+
73+
data.message = exception.type + ': ' + exception.value;
74+
// auto set a new tag specifically for the angular error url
75+
data.extra.angularDocs = matches[3].substr(0, 250);
76+
}
77+
}
78+
};
79+
7380
module.exports = angularPlugin;
7481

7582
},{}]},{},[1])(1)

dist/plugins/angular.min.js

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/plugins/angular.min.js.map

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/plugins/console.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
/*! Raven.js 3.3.0 (74c6c03) | github.com/getsentry/raven-js */
1+
/*! Raven.js 3.4.0 (4dba6fe) | github.com/getsentry/raven-js */
22

33
/*
44
* Includes TraceKit

dist/plugins/console.min.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/plugins/ember.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
/*! Raven.js 3.3.0 (74c6c03) | github.com/getsentry/raven-js */
1+
/*! Raven.js 3.4.0 (4dba6fe) | github.com/getsentry/raven-js */
22

33
/*
44
* Includes TraceKit

dist/plugins/ember.min.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/plugins/require.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
/*! Raven.js 3.3.0 (74c6c03) | github.com/getsentry/raven-js */
1+
/*! Raven.js 3.4.0 (4dba6fe) | github.com/getsentry/raven-js */
22

33
/*
44
* Includes TraceKit

0 commit comments

Comments
 (0)