Bug 121109 Bad Data Source and Data Set Javascript event handlers are ignored
Open a report design, open any Data Set's Script editor. Type in an invalid Javascript for the "beforeOpen" method, for example, " { ". Preview a report that uses that Data Set. The report executes normally. No error is shown. Apparently Report Engine ignored the bad Javascript code. It's only when you run the report in Debug mode do you see some exception message in the Eclipse console, with error message " ... Script engine error: missing } after function body ... " This is a regression against BIRT 1.0.1. In earlier builds the bad Javascript error message will be shown. Event handlers are an integral part of a report design, and if a script handler has an compilation error, or if the handler throws a runtime exception, Report Engine should either stop the report execution, or show the error message in the generated report. (Tested with the 2005-12-15 nightly build)
engine/org.eclipse.birt.report.engine/src/org/eclipse/birt/report/engine/script/internal/DtEScriptExecutor.java
/*******************************************************************************
 * Copyright (c) 2005 Actuate Corporation.
 * All rights reserved. This program and the accompanying materials
 * are made available under the terms of the Eclipse Public License v1.0
 * which accompanies this distribution, and is available at
 * http://www.eclipse.org/legal/epl-v10.html
 *
 * Contributors:
 *  Actuate Corporation  - initial API and implementation
 *******************************************************************************/
package org.eclipse.birt.report.engine.script.internal;
import org.eclipse.birt.data.engine.script.JSMethodRunner;
import org.eclipse.birt.report.engine.api.script.IReportContext;
import org.eclipse.birt.report.engine.executor.ExecutionContext;
import org.mozilla.javascript.Scriptable;
public abstract class DtEScriptExecutor extends ScriptExecutor