Skip to content

Instantly share code, notes, and snippets.

View aymericbouzy's full-sized avatar

aymeric bouzy aymericbouzy

  • Pigment
  • Nancy, France
View GitHub Profile
@aymericbouzy
aymericbouzy / app.js
Last active March 31, 2016 20:35
react-native-router-flux android bug report
import React, {
ListView,
Text,
TouchableWithoutFeedback,
View,
} from 'react-native'
import {Actions, Scene, Router} from 'react-native-router-flux'
let App = React.createClass({
render: function() {
try {
thisMightFail();
} catch(error) {
handleError(error);
} finally {
thisWillAlwaysRun();
}
try {
thisMightFail();
} catch(error) {
handleError(error);
}
thisWillAlwaysRun();
try {
throw "oups!";
} finally {
console.log("hello!");
}
try {
throw "oups!";
} catch(error) {
throw "so clumsy...";
} finally {
console.log("hello!");
}
(function() {
try {
return "early";
} finally {
console.log("hello!");
}
})();
(function() {
try {
throw "oups!";
} catch(error) {
return "early";
} finally {
console.log("hello!");
}
})();
try {
db.connect();
const data = db.getData();
return status(200).data(data);
} catch(error) {
return status(500).error(error);
} finally {
db.disconnect();
}
let finalError
try {
throw "oups!";
} catch(error) {
throw "so clumsy...";
} catch(error) {
finalError = error
}
console.log("hello!");
if (finalError) {
Outcome percentage
Succeeds on 1st retry 76.3%
Succeeds on 2nd retry 2.8%
Succeeds on 3rd retry 1.3%
Succeeds on 4th retry 1.0%
Succeeds on 5th retry 1.0%
Dead-letter 17.6%