This answer relies on the ripple emulator though you probably wanted a more general solution.
Two things. First, ripple is new and improved but it still has this error. You can see this article: http://www.raymondcamden.com/index.cfm/2013/11/5/Ripple-is-Reborn and follow links to get the new ripple from github: https://git-wip-us.apache.org/repos/asf?p=incubator-ripple.git;a=blob_plain;f=README.md;hb=HEAD
Second, you can fix ripple to prevent that particular error, which still exists even though ripple is much improved for working with cordova 3.0. Here's what I did after all the install process:
1) find the ripple.js file; for me it was at C:\Documents and Settings\myusername\Application Data\npm\node_modules\ripple-emulator\pkg\hosted\ripple.js
2) Find this line "ripple.define('platform/cordova/2.0.0/bridge/app', function (ripple, exports, module) {" which was at line #32611 in my download.
3) After the comments following that line, add the exitApp() function with the existing show() function. I used this code:
module.exports = {
show: function (success) {
return success && success();
},
exitApp: function(){
if(console && console.log) {
console.log("Tried to exit app from within ripple.");
}
}
};
I get the feed back in the console that the app tried to exit. You could do something else that is useful to you. I think the new ripple is worth the work of installing it. From there, you can fix it yourself or even contribute a useful solution.
UPDATE: exitApp and overrideBackbutton have both been added to ripple (in same place in the code as mentioned above). See this link: Add App.exitApp and App.overrideBackbutton methods support