Hi Serkan, I had some problems with this type of thing last month when I first set things up again on my latest machine. When I added in the JAVA_TOOL_OPTIONS it fixed things for me.
Like Carlos, I have a 'daily build' script that I have in the parent folder of the royale repos. It is a windows dailyBuildSequence.bat batch file that looks like this: @echo off call setEnvVars.bat cd %ROYALE_COMPILER_HOME% call git pull -v --progress "origin" @echo off if not '%errorLevel%'=='0' ( @echo Error:Build stopped - check for git conflicts goto :eof ) cd %ROYALE_TYPEDEFS_HOME% call git pull -v --progress "origin" @echo off if not '%errorLevel%'=='0' ( @echo Error:Build stopped - check for git conflicts goto :eof ) cd %ROYALE_HOME% call git pull -v --progress "origin" @echo off if not '%errorLevel%'=='0' ( @echo Error:Build stopped - check for git conflicts goto :eof ) set JAVA_TOOL_OPTIONS=-Dfile.encoding=UTF-8 -Xmx1024m cd %ROYALE_COMPILER_HOME% call mvn clean install -DskipTests cd %ROYALE_TYPEDEFS_HOME% call ant wipe call mvn clean install cd %ROYALE_HOME% call ant super-clean call mvn clean install -DskipTests call ant all -Dbuild.noprompt=true -Drelease.target=true The first line of that calls setEnvars.bat which is a separate companion file in the same parent directory I have that looks like this: @echo off set _BASE_DIR_DETECTED=%~dp0 ::Does string have a trailing slash? if so remove it IF %_BASE_DIR_DETECTED:~-1%==\ SET _BASE_DIR_DETECTED=%_BASE_DIR_DETECTED:~0,-1% set _BASE_DIR=%_BASE_DIR_DETECTED% @echo on set ASJS_HOME=%_BASE_DIR%\royale-asjs set TLF_HOME=%_BASE_DIR%\flex-tlf set FLEXUNIT_HOME=%_BASE_DIR%\flex-flexunit set FLEX_HOME=%_BASE_DIR%\flex-sdk set BLAZEDS_HOME=%_BASE_DIR%\flex-blazeds set AIR_HOME=%_BASE_DIR%\AIRSDK_Compiler set PLAYERGLOBAL_HOME=%_BASE_DIR%\player set PLAYERGLOBAL_VERSION=22.0 set FLASHPLAYER_DEBUGGER=%_BASE_DIR%\player\22.0\flashplayer_22_sa_debug.exe set GOOG_HOME=%ASJS_HOME%\js\lib\google\closure-library set webdriver.gecko.driver=%_BASE_DIR%\testing\selenium\firefox\geckodriver.exe set webdriver.firefox.marionette=%_BASE_DIR%\testing\selenium\firefox\geckodriver.exe set webdriver.chrome.driver=%_BASE_DIR%\testing\selenium\chrome\chromedriver.exe set PATH=%PATH%;%_BASE_DIR%\testing\selenium\firefox;%_BASE_DIR%\testing\selenium\chrome set MAVEN_OPTS=-Xms256m -Xmx1536m set ROYALE_HOME=%ASJS_HOME% set ROYALE_COMPILER_HOME=%_BASE_DIR%\royale-compiler set ROYALE_TYPEDEFS_HOME=%_BASE_DIR%\royale-typedefs There's probably too many in there - some may be from FlexJS days and not be needed anymore, but perhaps this approach might help you. On Fri, Nov 23, 2018 at 9:16 AM Serkan Taş <[email protected]> wrote: > Hi Alex, > > I am checking generated js files and some has really non-utf8 chars > inside. > > Trying to understand the reason. > > log : > XML.js:1247: ERROR - Parse error. Character '�' (U+FFFD) is not a valid > identifier start char > cont�nue; > > XML.js content : > > if (this.XML__children[i].nodeKind() != "element") > cont�nue; > > Thanks, > Serkan > > 22.11.2018 22:23 tarihinde Serkan Taş yazdı: > > Hi Alex, > > Adding encoding jvm arg just removed most of the errors but some still not > gone. > > **Have you verified that the files do not have any non-UTF8 byte > sequences in it?* > > Four have errors, and none of them are my files, they are generated by > compiler. > > So how can i be sure that they do not have non-UTF8 bytes in ? > > output : > > Kas 22, 2018 10:21:20 PM com.google.javascript.jscomp.LoggerErrorManager > println > SEVERE: ERROR - Cannot read file > D:/dev/royale-emulation-works/github/bin/js-debug/mx/core/Keyboard.js: > Failed to read: D:\dev\royale-emulation-works\github\bin\js-debug\mx\core\ > *Keyboard.js*, is this input UTF-8 encoded? > > Kas 22, 2018 10:21:20 PM com.google.javascript.jscomp.LoggerErrorManager > println > SEVERE: ERROR - Cannot read file > D:/dev/royale-emulation-works/github/bin/js-debug/org/apache/royale/html/beads/DateFieldView.js: > Failed to read: > D:\dev\royale-emulation-works\github\bin\js-debug\org\apache\royale\html\beads\ > *DateFieldView.js*, is this input UTF-8 encoded? > > Kas 22, 2018 10:21:20 PM com.google.javascript.jscomp.LoggerErrorManager > println > SEVERE: ERROR - Cannot read file > D:/dev/royale-emulation-works/github/bin/js-debug/org/apache/royale/textLayout/elements/ListElement.js: > Failed to read: > D:\dev\royale-emulation-works\github\bin\js-debug\org\apache\royale\textLayout\elements\ > *ListElement.js*, is this input UTF-8 encoded? > > Kas 22, 2018 10:21:20 PM com.google.javascript.jscomp.LoggerErrorManager > println > SEVERE: ERROR - Cannot read file > D:/dev/royale-emulation-works/github/bin/js-debug/org/apache/royale/textLayout/factory/StringTextLineFactory.js: > Failed to read: > D:\dev\royale-emulation-works\github\bin\js-debug\org\apache\royale\textLayout\factory\ > *StringTextLineFactory.js*, is this input UTF-8 encoded? > > Kas 22, 2018 10:21:20 PM com.google.javascript.jscomp.LoggerErrorManager > printSummary > WARNING: 4 error(s), 0 warning(s) > The project 'PinaraUI' has been successfully compiled and optimized. > > > 22.11.2018 21:37 tarihinde Alex Harui yazdı: > > Serkan, > > > > Have you verified that the files do not have any non-UTF8 byte sequences > in it? > > > > I would have expected in the log to show something about JAVA_TOOL_OPTIONS > and UTF8. Do you have that environment variable set? > > > > *JAVA_TOOL_OPTIONS*="-Dfile.encoding=*UTF-8*" > > > > HTH, > > -Alex > > > > *From: *Serkan Taş <[email protected]> > <[email protected]> > *Reply-To: *"[email protected]" <[email protected]> > <[email protected]> <[email protected]> > *Date: *Thursday, November 22, 2018 at 5:54 AM > *To: *"[email protected]" <[email protected]> > <[email protected]> <[email protected]> > *Subject: *Re: Work on Emulation > > > > Hi, > > This error is blocking my progress and emulation works. So i am leaving > until some one has idea or has time to advise me where to go. > > For reference full log : > https://drive.google.com/open?id=16Q1OLxAKa2lsbCcXZEebX7g6L21j4PsP > <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fdrive.google.com%2Fopen%3Fid%3D16Q1OLxAKa2lsbCcXZEebX7g6L21j4PsP&data=02%7C01%7Caharui%40adobe.com%7C28fdbfadc29d44bf7d1508d65081fd1b%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636784916589242659&sdata=JkfhD2CK9JocAalS7VUJNvxUENAGDS688J6duMg3z%2Bc%3D&reserved=0> > > Thanks, > Serkan > > 22.11.2018 14:11 tarihinde Serkan Taş yazdı: > > 10 of the errors from my project, 4 from the royale packages. > May be i am missing some compiler options ? > > Here is the list that gets same error: > > SEVERE: ERROR - Cannot read file > D:/dev/royale-emulation-works/github/bin/js-debug/com/likya/pinara/comps/FileViewPopup.js: > Failed to read: > D:\dev\royale-emulation-works\github\bin\js-debug\com\likya\pinara\comps\FileViewPopup.js, > is th > is input UTF-8 encoded? > Kas 22, 2018 2:02:01 PM com.google.javascript.jscomp.LoggerErrorManager > println > SEVERE: ERROR - Cannot read file > D:/dev/royale-emulation-works/github/bin/js-debug/com/likya/pinara/comps/Footer.js: > Failed to read: > D:\dev\royale-emulation-works\github\bin\js-debug\com\likya\pinara\comps\Footer.js, > is this input UTF-8 > encoded? > Kas 22, 2018 2:02:01 PM com.google.javascript.jscomp.LoggerErrorManager > println > SEVERE: ERROR - Cannot read file > D:/dev/royale-emulation-works/github/bin/js-debug/com/likya/pinara/comps/Header.js: > Failed to read: > D:\dev\royale-emulation-works\github\bin\js-debug\com\likya\pinara\comps\Header.js, > is this input UTF-8 > encoded? > Kas 22, 2018 2:02:01 PM com.google.javascript.jscomp.LoggerErrorManager > println > SEVERE: ERROR - Cannot read file > D:/dev/royale-emulation-works/github/bin/js-debug/com/likya/pinara/comps/LoginForm.js: > Failed to read: > D:\dev\royale-emulation-works\github\bin\js-debug\com\likya\pinara\comps\LoginForm.js, > is this input > UTF-8 encoded? > Kas 22, 2018 2:02:01 PM com.google.javascript.jscomp.LoggerErrorManager > println > SEVERE: ERROR - Cannot read file > D:/dev/royale-emulation-works/github/bin/js-debug/com/likya/pinara/comps/jobcrud/DependencyListForm.js: > Failed to read: > D:\dev\royale-emulation-works\github\bin\js-debug\com\likya\pinara\comps\jobcrud\De > pendencyListForm.js, is this input UTF-8 encoded? > Kas 22, 2018 2:02:01 PM com.google.javascript.jscomp.LoggerErrorManager > println > SEVERE: ERROR - Cannot read file > D:/dev/royale-emulation-works/github/bin/js-debug/com/likya/pinara/comps/jobdetail/JobAllDetailPanel.js: > Failed to read: > D:\dev\royale-emulation-works\github\bin\js-debug\com\likya\pinara\comps\jobdetail > \JobAllDetailPanel.js, is this input UTF-8 encoded? > Kas 22, 2018 2:02:01 PM com.google.javascript.jscomp.LoggerErrorManager > println > SEVERE: ERROR - Cannot read file > D:/dev/royale-emulation-works/github/bin/js-debug/com/likya/pinara/main/PinaraUI.js: > Failed to read: > D:\dev\royale-emulation-works\github\bin\js-debug\com\likya\pinara\main\PinaraUI.js, > is this input UTF > -8 encoded? > Kas 22, 2018 2:02:01 PM com.google.javascript.jscomp.LoggerErrorManager > println > SEVERE: ERROR - Cannot read file > D:/dev/royale-emulation-works/github/bin/js-debug/com/likya/pinara/utils/BasicAuthenticationHandler.js: > Failed to read: > D:\dev\royale-emulation-works\github\bin\js-debug\com\likya\pinara\utils\BasicAuthe > nticationHandler.js, is this input UTF-8 encoded? > Kas 22, 2018 2:02:01 PM com.google.javascript.jscomp.LoggerErrorManager > println > SEVERE: ERROR - Cannot read file > D:/dev/royale-emulation-works/github/bin/js-debug/com/likya/pinara/utils/RoleFilters.js: > Failed to read: > D:\dev\royale-emulation-works\github\bin\js-debug\com\likya\pinara\utils\RoleFilters.js, > is this i > nput UTF-8 encoded? > Kas 22, 2018 2:02:01 PM com.google.javascript.jscomp.LoggerErrorManager > println > SEVERE: ERROR - Cannot read file > D:/dev/royale-emulation-works/github/bin/js-debug/com/likya/pinara/utils/ViewToJobXml.js: > Failed to read: > D:\dev\royale-emulation-works\github\bin\js-debug\com\likya\pinara\utils\ViewToJobXml.js, > is this > input UTF-8 encoded? > ******************* > Kas 22, 2018 2:02:01 PM com.google.javascript.jscomp.LoggerErrorManager > println > SEVERE: ERROR - Cannot read file > D:/dev/royale-emulation-works/github/bin/js-debug/mx/core/Keyboard.js: > Failed to read: > D:\dev\royale-emulation-works\github\bin\js-debug\mx\core\Keyboard.js, is > this input UTF-8 encoded? > Kas 22, 2018 2:02:01 PM com.google.javascript.jscomp.LoggerErrorManager > println > SEVERE: ERROR - Cannot read file > D:/dev/royale-emulation-works/github/bin/js-debug/org/apache/royale/html/beads/DateFieldView.js: > Failed to read: > D:\dev\royale-emulation-works\github\bin\js-debug\org\apache\royale\html\beads\DateFieldVi > ew.js, is this input UTF-8 encoded? > Kas 22, 2018 2:02:01 PM com.google.javascript.jscomp.LoggerErrorManager > println > SEVERE: ERROR - Cannot read file > D:/dev/royale-emulation-works/github/bin/js-debug/org/apache/royale/textLayout/elements/ListElement.js: > Failed to read: > D:\dev\royale-emulation-works\github\bin\js-debug\org\apache\royale\textLayout\elem > ents\ListElement.js, is this input UTF-8 encoded? > Kas 22, 2018 2:02:01 PM com.google.javascript.jscomp.LoggerErrorManager > println > SEVERE: ERROR - Cannot read file > D:/dev/royale-emulation-works/github/bin/js-debug/org/apache/royale/textLayout/factory/StringTextLineFactory.js: > Failed to read: > D:\dev\royale-emulation-works\github\bin\js-debug\org\apache\royale\textLa > yout\factory\StringTextLineFactory.js, is this input UTF-8 encoded? > Kas 22, 2018 2:02:01 PM com.google.javascript.jscomp.LoggerErrorManager > printSummary > WARNING: 14 error(s), 0 warning(s) > The project 'PinaraUI' has been successfully compiled and optimized. > > 22.11.2018 13:32 tarihinde Serkan Taş yazdı: > > > > 22.11.2018 13:26 tarihinde Serkan Taş yazdı: > > Do you mean the file XMLDecoder.js ? > > > 22.11.2018 13:15 tarihinde Alex Harui yazdı: > > Could it have characters that aren’t UTF-8 in it? > > > > -Alex > > > > *From: *Serkan Taş <[email protected]> > <[email protected]> > *Reply-To: *"[email protected]" <[email protected]> > <[email protected]> <[email protected]> > *Date: *Thursday, November 22, 2018 at 1:57 AM > *To: *"[email protected]" <[email protected]> > <[email protected]> <[email protected]> > *Subject: *Re: Work on Emulation > > > > Hi, > > What should be the reason for this kid of errors ? > > Kas 22, 2018 12:49:43 PM com.google.javascript.jscomp.LoggerErrorManager > println > SEVERE: ERROR - Cannot read file > D:/dev/royale-emulation-works/github/bin/js-debug/com/adobe/serializers/xml/XMLDecoder.js: > Failed to read: > D:\dev\royale-emulation-works\github\bin\js-debug\com\adobe\serializers\xml\XMLDecoder.js, > is th > is input UTF-8 encoded? > > Thanks, > Serkan > > 22.11.2018 12:47 tarihinde Serkan Taş yazdı: > > Hi, > > I am getting compiler exception, for now i am going to comment-out and go > forward. > > Thanks, > > Serkan > > DETAILS: > > I amgetting exception > > Error : ClassCastException : java.lang.ClassCastException: > org.apache.royale.compiler.internal.tree.mxml.MXMLConcatenatedDataBindingNode > cannot be cast to org.apache.royale.compiler.tree.mxml.IMXMLLiter > > The source code throwing exception : > > <fx:String id="satir1"><![CDATA[ Likya Bilgi Teknolojileri ve > İletişim Hizmetleri Ltd. Şti. ]]></fx:String> > <fx:String id="satir2"><![CDATA[ © 2008-{showYear()} Tüm Hakları > Saklıdır. ]]></fx:String> > <fx:String id="satir3"><![CDATA[ Müşteri : Xxxxx Yyyyyy Zzzzzzz > A.Ş. ]]></fx:String> > <fx:String id="satir4"><![CDATA[ Ürün Kimliği: {licenseId} > ]]></fx:String> > > > stringNode: > > > MXMLStringNode(MXMLStringID) "String" id="satir2" 169:2 loc: 9054-9144 > abs: 9054-9144 > D:\dev\royale-emulation-works\github\pinaraui-royale\src\com\likya\pinara\comps\AboutForm.mxml > MXMLConcatenatedDataBindingNode(MXMLConcatenatedDataBindingID) > "ConcatenatedDataBinding" 169:34 loc: 9086-9141 abs: 9086-9141 > D:\dev\royale-emulation-works\github\pinaraui-royale\src\com\likya\pinara\comps\AboutForm.mxml > LiteralNode(LiteralStringID) String " � 2008-" 169:34 loc: 9086-9094 > abs: 9086-9094 > D:\dev\royale-emulation-works\github\pinaraui-royale\src\com\likya\pinara\comps\AboutForm.mxml > MXMLSingleDataBindingNode(MXMLDataBindingID) "DataBinding" 169:42 loc: > 9094-9106 abs: 9094-9106 > D:\dev\royale-emulation-works\github\pinaraui-royale\src\com\likya\pinara\comps\AboutForm.mxml > FunctionCallNode(FunctionCallID) "showYear" 169:43 loc: 9095-9103 > abs: 9095-9103 > D:\dev\royale-emulation-works\github\pinaraui-royale\src\com\likya\pinara\comps\AboutForm.mxml > IdentifierNode(IdentifierID) "showYear" 169:43 loc: 9095-9103 abs: > 9095-9103 > D:\dev\royale-emulation-works\github\pinaraui-royale\src\com\likya\pinara\comps\AboutForm.mxml > ContainerNode(ContainerID) SYNTHESIZED 169:51 loc: 9103-9105 abs: > 9103-9105 > D:\dev\royale-emulation-works\github\pinaraui-royale\src\com\likya\pinara\comps\AboutForm.mxml > LiteralNode(LiteralStringID) String " T�m Haklar� Sakl�d�r. " 169:54 > loc: 9106-9129 abs: 9106-9129 > D:\dev\royale-emulation-works\github\pinaraui-royale\src\com\likya\pinara\comps\AboutForm.mxml > > stringNode.getExpressionNode() : > > > MXMLConcatenatedDataBindingNode(MXMLConcatenatedDataBindingID) > "ConcatenatedDataBinding" 169:34 loc: 9086-9141 abs: 9086-9141 > D:\dev\royale-emulation-works\github\pinaraui-royale\src\com\likya\pinara\comps\AboutForm.mxml > LiteralNode(LiteralStringID) String " � 2008-" 169:34 loc: 9086-9094 > abs: 9086-9094 > D:\dev\royale-emulation-works\github\pinaraui-royale\src\com\likya\pinara\comps\AboutForm.mxml > MXMLSingleDataBindingNode(MXMLDataBindingID) "DataBinding" 169:42 loc: > 9094-9106 abs: 9094-9106 > D:\dev\royale-emulation-works\github\pinaraui-royale\src\com\likya\pinara\comps\AboutForm.mxml > FunctionCallNode(FunctionCallID) "showYear" 169:43 loc: 9095-9103 abs: > 9095-9103 > D:\dev\royale-emulation-works\github\pinaraui-royale\src\com\likya\pinara\comps\AboutForm.mxml > IdentifierNode(IdentifierID) "showYear" 169:43 loc: 9095-9103 abs: > 9095-9103 > D:\dev\royale-emulation-works\github\pinaraui-royale\src\com\likya\pinara\comps\AboutForm.mxml > ContainerNode(ContainerID) SYNTHESIZED 169:51 loc: 9103-9105 abs: > 9103-9105 > D:\dev\royale-emulation-works\github\pinaraui-royale\src\com\likya\pinara\comps\AboutForm.mxml > LiteralNode(LiteralStringID) String " T�m Haklar� Sakl�d�r. " 169:54 > loc: 9106-9129 abs: 9106-9129 > D:\dev\royale-emulation-works\github\pinaraui-royale\src\com\likya\pinara\comps\AboutForm.mxml > > Throws exception : valueNode = > (IMXMLLiteralNode)(stringNode.getExpressionNode()); > (MXMLRoyaleEmitter.java:3035) > > 22.11.2018 12:08 tarihinde Serkan Taş yazdı: > > Hi Alex, > > Here is the content : > > package com.adobe.fiber.core > { > public namespace model_internal = > "http://www.adobe.com/2008/flex/model/internal" > <http://www.adobe.com/2008/flex/model/internal>; > } > > And yes it is included. > > When getting scope for : http://www.adobe.com/2006/flex/mx/internal > > Result is : > > SWCFileScope for > "D:\dev\royale-emulation-works\github\royale-asjs\frameworks\js\libs\MXRoyaleJS.swc" > mx_internal > http://www.adobe.com/2006/flex/mx/internal > > Which is empty for http://www.adobe.com/2008/flex/model/internal > > SWC file scope can not be retrieved. I may have missing something while > packaging 3rd part libs. > > Thanks, > Serkan > > 22.11.2018 01:14 tarihinde Alex Harui yazdı: > > What does model_internal.as look like and is it included in the source or > libraries? > > Compare to mx/core/mx_internal.as > > > > Thanks, > > -Alex > > > > *From: *Serkan Taş <[email protected]> > <[email protected]> > *Reply-To: *"[email protected]" <[email protected]> > <[email protected]> <[email protected]> > *Date: *Wednesday, November 21, 2018 at 1:09 PM > *To: *"[email protected]" <[email protected]> > <[email protected]> <[email protected]> > *Subject: *Re: Work on Emulation > > > > Hi Alex, > > For getContainingToplevelDefinition (DefinitionBase.java:537), input > parameter is definition = "http://www.adobe.com/2008/flex/model/internal" > <http://www.adobe.com/2008/flex/model/internal> > > > Then trying to get : > > ASScope currentContainingScope = definition.getContainingASScope(); > > returns null. > > Later, > > currentContainingScope.getContainingDefinition(); is called which throws > exception. > > It is related with namespaces as you referenced. > > I am going to comment-out the function call and go forward for now. > > Thanks, > Serkan > > 21.11.2018 01:26 tarihinde Alex Harui yazdı: > > Regarding the compiler errors. My guess is that it has to do with the > model_internal namespace. Maybe get rid of it for now unless it is in a > lot of places. Or create a simple test case. > > > > -Alex > > > > *From: *Serkan Taş <[email protected]> > <[email protected]> > *Reply-To: *"[email protected]" <[email protected]> > <[email protected]> <[email protected]> > *Date: *Tuesday, November 20, 2018 at 1:36 PM > *To: *"[email protected]" <[email protected]> > <[email protected]> <[email protected]> > *Subject: *Re: Work on Emulation > > > > Hi, > > I submitted PR:https://github.com/apache/royale-asjs/pull/349 > <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fapache%2Froyale-asjs%2Fpull%2F349&data=02%7C01%7Caharui%40adobe.com%7C28fdbfadc29d44bf7d1508d65081fd1b%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636784916589242659&sdata=Mz%2FuSdFsFRWoZPwrGA19t23%2FSZziMFmIM3NqNDd5Kg8%3D&reserved=0> > > I am getting compiler errors. I pasted three errors in file : > https://drive.google.com/open?id=15b3Yvke-H96L1ud_9YE1JW4a4dgiA3F5 > <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fdrive.google.com%2Fopen%3Fid%3D15b3Yvke-H96L1ud_9YE1JW4a4dgiA3F5&data=02%7C01%7Caharui%40adobe.com%7C28fdbfadc29d44bf7d1508d65081fd1b%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636784916589242659&sdata=j2XMEIDo6rPwTD378NJZJnVxddyqTpNy86SCHRUgxxk%3D&reserved=0> > > I leaving for today. I am going to debug compiler and try to understand > what is going wrong when i have time. > > Thanks, > Serkan > > 20.11.2018 23:48 tarihinde Serkan Taş yazdı: > > Okay Alex, it is really clarified :) > > I am moving with making changes and going to follow-up your PR. > > Thank you so much, > Serkan > > 20.11.2018 23:43 tarihinde Alex Harui yazdı: > > Yes, like I said, there is a change to the config files I am going to make > that should reduce how often you get that error. For now, you will have to > be explicit and fully qualify the name. The MXML compiler automatically > imports certain classes and it is being told by royale-config.xml to import > org.apache.royale.events.MouseEvent which conflicts with > mx.events.MouseEvent. I am going to see if we can change the default > imports in flex-config.xml and have migrating users use flex-config.xml > instead of royale-config.xml by adding +configname=”flex” to their compiler > options. > > > > I’m working on these changes now to see if there are any issues with doing > this. > > > > -Alex > > > > > > *From: *Serkan Taş <[email protected]> > <[email protected]> > *Reply-To: *"[email protected]" <[email protected]> > <[email protected]> <[email protected]> > *Date: *Tuesday, November 20, 2018 at 12:40 PM > *To: *"[email protected]" <[email protected]> > <[email protected]> <[email protected]> > *Subject: *Re: Work on Emulation > > > > > I remove the flash import and just imported mx.events.MouseEvent but > vcompiler is forcing to replace all occurrence of MouseEvent with > mx.events.MouseEvent. > > Getting errors : > > DependencyListForm.mxml(150): col: 50 Error: Ambiguous reference to > MouseEvent > > protected function depEkle_clickHandler(event:MouseEvent):void > > ^ > > > > > > 20.11.2018 23:33 tarihinde Alex Harui yazdı: > > Hi Serkan, > > > > You can override addedToParent() and call your handler. > > > > I don’t have enough context to answer your questions about MouseEvent. In > Royale, flash.events.MouseEvents should never be used. When running as a > SWF, Royale traps all mouse events and re-dispatches them as > org.apache.royale.events.MouseEvent. However, it does not have all of the > properties that flash.events.MouseEvent has (and shouldn’t since we don’t > want properties like “stageX” in the Royale API since “stage” doesn’t mean > anything to users who don’t know Flash. At some point in time, the > emulation Applications will replace the code that traps both Flash and > Browser MouseEvent and re-dispatch them as mx.events.MouseEvent. So all > migrated code should use mx.events.MouseEvent and not any other MouseEvent. > > > > It is ok for SWF code to reference flash.events.MouseEvent. Cleaning it > up so it doesn’t would be nice, but probably not required. > > > > HTH, > > -Alex > > > > *From: *Serkan Taş <[email protected]> > <[email protected]> > *Reply-To: *"[email protected]" <[email protected]> > <[email protected]> <[email protected]> > *Date: *Tuesday, November 20, 2018 at 12:22 PM > *To: *"[email protected]" <[email protected]> > <[email protected]> <[email protected]> > *Subject: *Re: Work on Emulation > > > > One more addition : > > do I have to change all occurrence of MouseEvent with > mx.events.MouseEvent to get rid of "ambiguous" usage error ? > > 20.11.2018 23:19 tarihinde Serkan Taş yazdı: > > Hi Alex, > > Unfortunately i need to adjust dynamically header properties when the > component added/removed each time. But for just now i may comment-out and > come back later for the check if the emulation is really required. > > For the mouse event, as i understand, both swf and js mx.events.MouseEvent > is going to be used and then i have to remove "import > flash.events.MouseEvent". So why some of the files still contain the flash > import ? Just i am little bit mixed. > > Thanks, > > Serkan > > 20.11.2018 23:11 tarihinde Alex Harui yazdı: > > Hi Serkan, > > > > So far, there aren’t others using addedToStage event so it would be better > if Royale didn’t have to emulate it. There may be some other event you can > use instead like “initComplete” unless you need that code to run every time > you remove and re-add the Panel. > > > > Regarding MouseEvent, you just reminded me of something on my list to do, > which is to reconfigure the -config.xml files so there aren’t CSS conflicts > in apps that aren’t using the emulation. But for now, you can just fully > qualify the type: > > > > protected function depEkle_clickHandler(event:mx.events.MouseEvent):void > > > > you will have to import mx.events.MouseEvent for both JS and SWF. > > > > HTH, > > -Alex > > > > *From: *Serkan Taş <[email protected]> > <[email protected]> > *Reply-To: *"[email protected]" <[email protected]> > <[email protected]> <[email protected]> > *Date: *Tuesday, November 20, 2018 at 11:55 AM > *To: *"[email protected]" <[email protected]> > <[email protected]> <[email protected]> > *Subject: *Re: Work on Emulation > > > > Hi, > > I would like to get advises to resolve these two errors : > > 1: > Header.mxml(98): col: 75 Error: This attribute is unexpected. It will be > ignored. > > <s:Panel id="headerPanel" width="100%" height="20" > chromeColor="#E1E5EA" addedToStage="headerPanel_addedToStageHandler(event > as Event)"> > > > ^ > > may i just remove the handler ? > > 2: > DependencyListForm.mxml(156): col: 50 Error: Ambiguous reference to > MouseEvent > > protected function depEkle_clickHandler(event:MouseEvent):void > > ^ > > I tired adding import statement with compiler directive : > > COMPILE::SWF { > import flash.events.MouseEvent; > } > COMPILE::JS { > import mx.events.MouseEvent; > } > > but still the same error is reported. > > Thanks, > Serkan > > 20.11.2018 13:09 tarihinde Serkan Taş yazdı: > > Hi Alex, > > Nice to hear that it is resolved :) > > I may go through my emulation process... > > Thanks, > Serkan > > 19.11.2018 22:47 tarihinde Alex Harui yazdı: > > Wow, it turns out to be a relatively simple scenario. It is amazing that > none of our examples have MXML files that reference other MXML files by > type. Our Applications might have a MyInitialView tag, but no other code > in our examples actually create a variable like “var myView:MyInitialView” > or in your case, “import somepackage.MyInitialView”. > > > > I just pushed a fix for that. Thanks for helping us track that down. > > > > -Alex > > > > *From: *Alex Harui <[email protected]> <[email protected]> > *Reply-To: *"[email protected]" <[email protected]> > <[email protected]> <[email protected]> > *Date: *Monday, November 19, 2018 at 12:36 AM > *To: *"[email protected]" <[email protected]> > <[email protected]> <[email protected]> > *Subject: *Re: Work on Emulation > > > > OK, I will try this tomorrow. I have to stop for tonight. > > > > -Alex > > > > *From: *Serkan Taş <[email protected]> > <[email protected]> > *Reply-To: *"[email protected]" <[email protected]> > <[email protected]> <[email protected]> > *Date: *Sunday, November 18, 2018 at 12:59 AM > *To: *"[email protected]" <[email protected]> > <[email protected]> <[email protected]> > *Subject: *Re: Work on Emulation > > > > Hi Alex, > > I prepared a file called FindBug.mxml in my project beside my main file. : > https://github.com/likyateknoloji/pinaraui-royale/blob/master/src/com/likya/pinara/main/FindBug.mxml > <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Flikyateknoloji%2Fpinaraui-royale%2Fblob%2Fmaster%2Fsrc%2Fcom%2Flikya%2Fpinara%2Fmain%2FFindBug.mxml&data=02%7C01%7Caharui%40adobe.com%7C28fdbfadc29d44bf7d1508d65081fd1b%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636784916589242659&sdata=WTg%2FDEIN1JpvH2k%2Bw%2BCxX6xEUQsk6Hh%2BVcpUygd10oI%3D&reserved=0> > > Content : > > > > > > > > > > > <?xml version="1.0" encoding="utf-8"?> > > <s:TitleWindow xmlns:fx="http://ns.adobe.com/mxml/2009" > <https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fns.adobe.com%2Fmxml%2F2009&data=02%7C01%7Caharui%40adobe.com%7C28fdbfadc29d44bf7d1508d65081fd1b%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636784916589242659&sdata=1UMvTTA4qWCLzIVMksvHgI%2B3QjqrTr3kIheN%2FuLg8ss%3D&reserved=0> > > xmlns:s="library://ns.apache.org/royale/spark" > > xmlns:mx="library://ns.apache.org/royale/mx" > > xmlns:comps="com.likya.pinara.comps.*" > > > > > <fx:Script> > > <![CDATA[ > > ]]> > > </fx:Script> > > > > <fx:Declarations> > > </fx:Declarations> > > > > <comps:MenuBar excludeFrom="loggedOutState, dummyState" id="menuBar"/> > > > > </s:TitleWindow> > > > This code makes the compiler hang wtih line : ASScopeCache done with lock > in getQualifiedScopeChainMap > > When i comment out the line <!comps:MenuBar excludeFrom="loggedOutState, > dummyState" id="menuBar"/--> > > Than it completes with warnings: > > Kas 18, 2018 11:54:53 AM com.google.javascript.jscomp.LoggerErrorManager > printSummary > WARNING: 1 error(s), 2 warning(s) > The project 'FindBug' has been successfully compiled and optimized. > 23.416603651 seconds > > I my previous mail in thread i told that the problem is related with > namespace, but i guess the namespace declaration masked the problem behind. > > If you want to regenerate the error, you need to clone the project and > modify the build script : > https://github.com/likyateknoloji/pinaraui-royale > <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Flikyateknoloji%2Fpinaraui-royale&data=02%7C01%7Caharui%40adobe.com%7C28fdbfadc29d44bf7d1508d65081fd1b%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636784916589242659&sdata=GZL3ikbsuyWFKEyQ4Qh7RjygSX135YX7I2Uqf3ntsQE%3D&reserved=0> > > The only vars in scripts need to be changed : > > > > > > > > > > > set > COMPILER_PATH=D:\dev\royale-emulation-works\apache-royale-0.9.4-bin-js-swf\royale-asjs\js\bin > > set ROYALE_ASJS=D:\dev\royale-emulation-works\github\royale-asjs > > I am leaving for today maybe look at evening or monday evening. > > Thanks, > Serkan > > 17.11.2018 18:40 tarihinde Serkan Taş yazdı: > > Let me preserve thread : > > I found out that namespace definitions in the beginning of file - in > application tag - causes compiler to hang. > > e.g. > > xmlns:comps="com.likya.pinara.comps.*" > > When i remove these namespace definitions, than compiler goes on. > > This workaround let me to continue a little but real solution is required > for final : > > PinaraUI.mxml(630): col: 3 Error: Unknown namespace jobmanager. > > <jobmanager:JobManager showBusyCursor="true" > id="jobManagerService" fault="jobManagerService_faultHandler(event)"/> > > > Thanks. > Serkan > > 17.11.2018 00:41 tarihinde Alex Harui yazdı: > > OK, I may not get to it until Sunday night or Monday. > > > > -Alex > > > > *From: *Serkan Taş <[email protected]> > <[email protected]> > *Reply-To: *"[email protected]" <[email protected]> > <[email protected]> <[email protected]> > *Date: *Friday, November 16, 2018 at 12:58 PM > *To: *"[email protected]" <[email protected]> > <[email protected]> <[email protected]> > *Subject: *Re: Work on Emulation > > > > > > > > > > > > > > > Hi Alex, > > List is ignoring my mails sometimes :) as you may understand from my last > mail. > > I finally finished preparing my project on github to be build easily. > > Project path : https://github.com/likyateknoloji/pinaraui-royale/ > <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Flikyateknoloji%2Fpinaraui-royale%2F&data=02%7C01%7Caharui%40adobe.com%7C28fdbfadc29d44bf7d1508d65081fd1b%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636784916589242659&sdata=JNauULsKYz9V7bKzxhBCZk1Y2ZhTIXTeKLcgypW2Yqk%3D&reserved=0> > > You can find details about command-line options in the batch file > https://github.com/likyateknoloji/pinaraui-royale/blob/master/pinara-git-build.bat > <https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Flikyateknoloji%2Fpinaraui-royale%2Fblob%2Fmaster%2Fpinara-git-build.bat&data=02%7C01%7Caharui%40adobe.com%7C28fdbfadc29d44bf7d1508d65081fd1b%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636784916589398910&sdata=dZzJFGuph%2BIqPlvhJtVAf7KRF67KOYRRu5%2BezwyXBVM%3D&reserved=0> > > I do not like to put libs on github but sometimes it is best solution, and > the swc's are under libs folder. > > If you have any questions let me know. > > Thanks, > Serkan > > > > > > > > > > > 16.11.2018 10:53 tarihinde Alex Harui yazdı: > > Hi Serkan, > > > > I was hoping the output would show an unreleased lock, but every lock > seems to get released. > > > > Is all of your code in your GitHub account? If so, I will try to download > it and see if it hangs for me. Please put the exact command-line options > you are using. If you have custom SWCs that this compile will need, maybe > you can put those in GitHub too. I’m done working for tonight. I will > check tomorrow. > > > > Thanks, > > -Alex > > > > > > > > > > > > > >
