Hello all,
I just spent too much time tracking down a RTE to having incremental
compiles turned on. Basically, it was very hit and miss; it always would
compile fine; run when running the installed product is would sometimes
sometimes simply fail, throwing a Error #1065, before it even ran the class
constructor on the related class.
Basically, I have embedded SQL text into my my classes like this:
[Embed(source="../../sql/flightSearch/FlightSegments.sql",
mimeType="application/octet-stream")]
private static var FlightDataLoaderStatementText:Class;
public static function get LOAD_FLIGHTS_SQL():String {
return new FlightDataLoaderStatementText();
}
The first time I compile, there are no run-time issues. After I compile the
2nd time, I start getting errors on one of the various classes that use
this strategy.
I originally was having issues in SDK 4.12 (before I understood that issue
was compiler-related), so I upgraded to 4.13 see if that fixed it (which it
did, for 1 compile cycle).
The RTE occurs in a module (for what its worth), and the entire build is
driven by ANT. Strangely enough, when I use IntelliJ for my dev build, the
error never occurs.
Looks like Tom Chiverton experienced the (same ?) issue back in March (
http://mail-archives.apache.org/mod_mbox/flex-users/201403.mbox/%[email protected]%3E
).
When I compile w/a link-report, the only working version includes
references to my embedded assets:
<script name="Constants_DoublesIndexCreateSQLText.as"
mod="1405113179000" size="387" optimizedsize="213">
<def id="Constants_DoublesIndexCreateSQLText" />
<pre id="mx.core:ByteArrayAsset" />
<dep id="AS3" />
</script>
Is that what is expected? Or would the embedded asset not be listed b/c it
is already in the swf from the previous compile?
Scott