Community
Participate
Working Groups
Created attachment 206827 [details] completed mortgage sample
Open the main handler, it shows runtime exception saying ui can not be initialized. This used to be working fine before Now 10.
Created attachment 206891 [details] A temporary patch, need Jeff's review
Created attachment 206892 [details] A simple test case This problem happens when a function in a handler references a field in another handler. In this sample, wheatherlib.egl accessed weatherTable.xml Steps to reproduce 1. comment out // xml string = "da"; in WeatherTable.egl and save. The js will be regenerated and weatherlib.egl should have compile error. 2. uncomment xml string = "da"; The weatherTable.egl and weatherlib.egl will be regenerated. Look at the generated js in weathertable.js "eze$$setInitial": function() { this.eze$$setEmpty(); this.xml = "da"; this.weatherData = [eze$Temp2].setType("[Teu/weatherdata;"); //This line is wrong } This error happens because the weatherTable is reorganized when weatherlib is generated. We should prevent the reorganization of field of other handlers.
I cannot tell if that would break everything or not, but it looks dangerous to me because it will stop the flow of the IR accepts. I will need time to see and try your testcase
I cannot get to that testcase. Please post the EGL source in a format that I can use.
Hi Jeff, This is the source code of the 2 handlers in the test case. weatherlib.egl: package eu; library weatherlib function hello() syslib.writeStderr(WeatherTable.xml); syslib.writeStdout(WeatherTable.weatherData.getSize()); end end record WeatherData{} Day string?; end WeatherTable.egl: package eu; library WeatherTable xml string = "da"; weatherData WeatherData[] =[ new WeatherData{Day = "Tuesday, June 02, 2009"}]; end Please create a web client project to include this two handlers and follow the steps in comment 3 to recreate the problem. Thanks
It looks like you did a very good job on figuring this out and it corrects the same problem for both javaGen and JSGen. Thank you, well done! I've committed the update.
Verified. Problem does not exist for Mortgage now.