You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@flex.apache.org by Harbs <ha...@gmail.com> on 2016/02/07 16:59:07 UTC

Re: [FALCONJX][FLEXJS] XML handling (was Re: [FlexJS] Back port)

Here’s another issue I’m struggling with:

The ECMA spec has an [[Insert]] and [[Replace]] internal method defined for XML.

Here’s the semantics for [[Insert]]:
Semantics 
When the [[Insert]] method of an XML object x is called with property name P and value V, the following steps are taken: 
1. If x.[[Class]] ∈ {"text", "comment", "processing-instruction", "attribute"}, return 
2. Let i = ToUint32(P) 
3. If (ToString(i) is not equal to P), throw a TypeError exception 
4. If Type(V) is XML and (V is x or an ancestor of x) throw an Error exception 
5. Let n = 1 
6. If Type(V) is XMLList, let n = V.[[Length]] 
7. If n == 0, Return 
8. For j = x.[[Length]]-1 downto i, rename property ToString(j) of x to ToString(j + n) 
9. Let x.[[Length]] = x.[[Length]] + n 
10. If Type(V) is XMLList 
a. For j = 0 to V.[[Length-1]] 
i. V[j].[[Parent]] = x 
ii. x[i + j] = V[j] 
11. Else 
a. Call the [[Replace]] method of x with arguments i and V 
12. Return 
The [[Insert]] method is referenced a few places in the spec, but I’m really not sure how/why it’s defined as it is for XML objects (as opposed to XMLList objects). It kind of sounds like the contents of the XML object itself is redefined (as opposed to children). Why would you do that rather than [[Insert]] a child XML object into the parent and/or replace the child with a different one?

If my reading is right, I have no clue how to read the spec for [[Put]], insertChildBefore, insertChildAfter and prependChild. All those cases seem to be adding children.

Color me confused,
Harbs

On Jan 11, 2016, at 9:24 AM, Harbs <ha...@gmail.com> wrote:

> Thanks for that.
> 
> So: It looks like all items in xml get the parent namespaces associated with them as XML objects, but the namespaces are not written when using toXMLString().
> 
> Transferring an element with a namespace to another xml element loses the prefix and has an un-prefixed namespace applied to it.
> If the uri exists in the new element with a prefix, the element takes on the prefix of the new element.
> 
> 
> On Jan 11, 2016, at 5:21 AM, Andy Dufilie <an...@gmail.com> wrote:
> 
>> On Sun, Jan 10, 2016 at 4:53 PM, Harbs <ha...@gmail.com> wrote:
>> 
>>> I’m trying to figure out namespace behavior.
>>> 
>>> I’m probably tired, but can someone tell me why the  “catalog_item” var in
>>> this test (on line 70) does not get any results?
>>> 
>>> https://gist.github.com/Harbs/c24285b3af80eeed251d
>>> 
>> 
>> 
>> I put your code in an .as file instead of an .mxml, and it won't compile
>> because of this line:
>> 
>> var catalog_item = xml..fx::catalog_item[0];
>> 1120: Access of undefined property fx.
>> 
>> I think it's only a warning in MXML ("*possibly* undefined property")
>> because you've defined the fx namespace in the mxml tag at the top of the
>> file. To fix it, you either need to add the following to your code inside
>> CDATA:
>> 
>> namespace fx = 'http://ns.adobe.com/mxml/2009';
>> 
>> or use one of these forms:
>> 
>> var catalog_item = xml..('http://ns.adobe.com/mxml/2009')::catalog_item[0];
>> var catalog_item = xml.descendants(new QName('http://ns.adobe.com/mxml/2009',
>> 'catalog_item'))[0];
> 


Re: [FALCONJX][FLEXJS] XML handling (was Re: [FlexJS] Back port)

Posted by Harbs <ha...@gmail.com>.
Yes I did have an env.properties file. But the paths seem to be right, and removing it did not make a difference.

It’s good to know it’s not needed though…

On Feb 15, 2016, at 5:01 PM, Alex Harui <ah...@adobe.com> wrote:

> This implies you still have environment variables set somehow.  The
> defaults would use relative paths with ../ in them.
> Do you have an env.properties file or local.properties file?


Re: [FALCONJX][FLEXJS] XML handling (was Re: [FlexJS] Back port)

Posted by Alex Harui <ah...@adobe.com>.

On 2/16/16, 12:29 AM, "Harbs" <ha...@gmail.com> wrote:

>Point taken.
>
>I’ll spend some time today and see if I can figure it out. If I have
>trouble, I might come back and ask you for help… ;-)

Well, try the latest changes in the post I just sent.

You and others are always welcome to ask for help, but please have
realistic expectations of how polished this technology is and what is best
for the project as a whole.  It would not make sense to me to kick off the
FlexJS event in San Francisco by showing that you can click on something
and build the entire code base, but the code base has no new features
since 0.5.0.

Maybe you don't like environment variables, but maybe for now you'll have
to live with them.  I generally put them in scripts so I don't have to
have defaults baked into the system settings and that encapsulates the set
of variables that I need for various purposes.

I actually think I got env.properties to work properly, but we'll see.
I'm up way later than I should be so I'll won't be answering any questions
for the next several hours, so good luck.

-Alex


Re: [FALCONJX][FLEXJS] XML handling (was Re: [FlexJS] Back port)

Posted by Harbs <ha...@gmail.com>.
Point taken.

I’ll spend some time today and see if I can figure it out. If I have trouble, I might come back and ask you for help… ;-)

On Feb 16, 2016, at 10:16 AM, Alex Harui <ah...@adobe.com> wrote:

> 
> 
> On 2/15/16, 11:44 PM, "Harbs" <ha...@gmail.com> wrote:
> 
>> I would definitely work on this if I knew how. My level of expertise
>> using ant is about good enough to look at a build file and get a general
>> idea of how it works.
> 
> Before Flex came to Apache, I didn't know much about Ant either.  We had
> folks who did that sort of stuff at Adobe.  But  I was forced to learn it.
> You're a smart guy, you could learn it too if motivated enough.
> 
> But, because you are a volunteer and your time is limited, I guess that
> gives you the right to say, "well, if it isn't as easy as I want it to be,
> I can't contribute".  And that puts the onus on the few of us who have
> more time to do the not-so-fun stuff.  Which isn't fun.  Which is why I'm
> complaining.  Like or not, this stuff is the bleeding edge.  I really
> don't see much advantage to the community to polish stuff that might
> change soon.  I had hoped we could draw in more folks who could put up
> with the bleeding edge, but apparently we can't.  Folks can just say "I
> don't want to know how you work, this is how I want to work" and I have to
> try to figure out what the difference is and try to get the build system
> to conform to it.
> 
>> 
>> The Flex builds seem really complex to me and I’m not even sure what all
>> the dependencies are.
> 
> Agreed that it is complex.  I could probably stop developing new features
> and try to make it simpler.  The README and LICENSE hopefully document the
> dependencies.
> 
> -Alex
> 


Re: [FALCONJX][FLEXJS] XML handling (was Re: [FlexJS] Back port)

Posted by Alex Harui <ah...@adobe.com>.

On 2/15/16, 11:44 PM, "Harbs" <ha...@gmail.com> wrote:

>I would definitely work on this if I knew how. My level of expertise
>using ant is about good enough to look at a build file and get a general
>idea of how it works.

Before Flex came to Apache, I didn't know much about Ant either.  We had
folks who did that sort of stuff at Adobe.  But  I was forced to learn it.
 You're a smart guy, you could learn it too if motivated enough.

But, because you are a volunteer and your time is limited, I guess that
gives you the right to say, "well, if it isn't as easy as I want it to be,
I can't contribute".  And that puts the onus on the few of us who have
more time to do the not-so-fun stuff.  Which isn't fun.  Which is why I'm
complaining.  Like or not, this stuff is the bleeding edge.  I really
don't see much advantage to the community to polish stuff that might
change soon.  I had hoped we could draw in more folks who could put up
with the bleeding edge, but apparently we can't.  Folks can just say "I
don't want to know how you work, this is how I want to work" and I have to
try to figure out what the difference is and try to get the build system
to conform to it.

>
>The Flex builds seem really complex to me and I’m not even sure what all
>the dependencies are.

Agreed that it is complex.  I could probably stop developing new features
and try to make it simpler.  The README and LICENSE hopefully document the
dependencies.

-Alex


Re: [FALCONJX][FLEXJS] XML handling (was Re: [FlexJS] Back port)

Posted by Harbs <ha...@gmail.com>.
I would definitely work on this if I knew how. My level of expertise using ant is about good enough to look at a build file and get a general idea of how it works.

The Flex builds seem really complex to me and I’m not even sure what all the dependencies are.

On Feb 16, 2016, at 12:38 AM, Alex Harui <ah...@adobe.com> wrote:

> I have not seen anyone offer to make a fix.  I am mostly done with a change. Hopefully it will go in tonight.
> 
> 
> Sent from my LG G3, an AT&T 4G LTE smartphone
> 
> 
> ------ Original message------
> 
> From: OmPrakash Muppirala
> 
> Date: Mon, Feb 15, 2016 1:55 PM
> 
> To: dev@flex.apache.org;
> 
> Subject:Re: [FALCONJX][FLEXJS] XML handling (was Re: [FlexJS] Back port)
> 
> 
> Alex,
> 
> The way I am reading this thread, I don't think folks are asking you to
> make the changes.  They are generally asking if it is okay to make these
> kind of changes.  It would be good if you are okay with the changes since
> you are one of the affected parties.
> 
> Thanks,
> Om
> 
> On Mon, Feb 15, 2016 at 1:36 PM, Alex Harui <ah...@adobe.com> wrote:
> 
>> 
>> 
>> On 2/15/16, 1:32 PM, "Michael Schmalle" <te...@gmail.com> wrote:
>> 
>>> Alex, if I had time I wouldn't do it. :) I hate build stuff and this is
>>> exactly why I set that template file up.
>> 
>> Well, I'm glad it worked for you, and it worked for me, but now I am
>> spending time trying to implement something else to make others happy.
>> Yes, we want to make it easier for others to contribute, but I don't like
>> it that it always falls on me to try to figure it out for others.
>> 
>> -Alex
>> 
>> 


Re: [FALCONJX][FLEXJS] XML handling (was Re: [FlexJS] Back port)

Posted by jude <fl...@gmail.com>.
I don't but let's say Ant does something that AIR doesn't. You can call
just that one behavior. Get download or unzip file. You would have a single
function target.

I don't think it has to be installed. So you can bundle ant with the app.
Just put it in a subdirectory and then call ant /path/to/build.xml
name_of_target.

On Thu, Feb 18, 2016 at 9:54 PM, Alex Harui <ah...@adobe.com> wrote:

>
>
> On 2/18/16, 11:30 AM, "jude" <fl...@gmail.com> wrote:
>
> >it's possible to call ant using native process though. so you could fall
> >back on those few cases that ant is required.'
>
> Sure, that's possible, but I thought you didn't want to use Ant syntax in
> the first place.  And even if you do, you have to deal with making sure
> Ant is properly installed.
>
> -Alex
>
>

Re: [FALCONJX][FLEXJS] XML handling (was Re: [FlexJS] Back port)

Posted by Alex Harui <ah...@adobe.com>.

On 2/18/16, 11:30 AM, "jude" <fl...@gmail.com> wrote:

>it's possible to call ant using native process though. so you could fall
>back on those few cases that ant is required.'

Sure, that's possible, but I thought you didn't want to use Ant syntax in
the first place.  And even if you do, you have to deal with making sure
Ant is properly installed.

-Alex


Re: [FALCONJX][FLEXJS] XML handling (was Re: [FlexJS] Back port)

Posted by jude <fl...@gmail.com>.
it's possible to call ant using native process though. so you could fall
back on those few cases that ant is required.
On Feb 17, 2016 10:50 PM, "Alex Harui" <ah...@adobe.com> wrote:

>
>
> On 2/17/16, 10:34 PM, "Justin Mclean" <ju...@classsoftware.com> wrote:
>
> >Hi,
> >
> >> But Windows doesn't even have native processes for grep and sed and
> >> requiring CygWin or GitBash doesn't seem like a good idea.
> >
> >ActionScript has RegExp support [1] so an AIR grep wouldn’t be too hard
> >to create. Remind me what do the build scripts use grep for?
>
> I don't think our builds call out to grep explicitly, but we do use the
> ReplaceRegExp Ant task in some cases and I'm not sure we have AntOnAIR
> fully equivalent.
>
> AntOnAIR currently has enough to run the installer.xml scripts, but I
> think it is missing stuff we use in our build.xml and download.xml files.
> Tar/Jar also come to mind.  And, of course, it is still mimic-ing Ant,
> which some folks don't like.
>
> The AntOnAIR project has a tests/AntOnAIR.mxml which in theory you can
> feed the command line "-f <some ant script>" and see how far it gets with
> our build.xml files.
>
> -Alex
>
>
>
>

Re: [FALCONJX][FLEXJS] XML handling (was Re: [FlexJS] Back port)

Posted by Alex Harui <ah...@adobe.com>.

On 2/17/16, 10:34 PM, "Justin Mclean" <ju...@classsoftware.com> wrote:

>Hi,
>
>> But Windows doesn't even have native processes for grep and sed and
>> requiring CygWin or GitBash doesn't seem like a good idea.
>
>ActionScript has RegExp support [1] so an AIR grep wouldn’t be too hard
>to create. Remind me what do the build scripts use grep for?

I don't think our builds call out to grep explicitly, but we do use the
ReplaceRegExp Ant task in some cases and I'm not sure we have AntOnAIR
fully equivalent.

AntOnAIR currently has enough to run the installer.xml scripts, but I
think it is missing stuff we use in our build.xml and download.xml files.
Tar/Jar also come to mind.  And, of course, it is still mimic-ing Ant,
which some folks don't like.

The AntOnAIR project has a tests/AntOnAIR.mxml which in theory you can
feed the command line "-f <some ant script>" and see how far it gets with
our build.xml files.

-Alex




Re: [FALCONJX][FLEXJS] XML handling (was Re: [FlexJS] Back port)

Posted by Justin Mclean <ju...@classsoftware.com>.
Hi,

> But Windows doesn't even have native processes for grep and sed and
> requiring CygWin or GitBash doesn't seem like a good idea.

ActionScript has RegExp support [1] so an AIR grep wouldn’t be too hard to create. Remind me what do the build scripts use grep for?

Thanks,
Justin

1. http://help.adobe.com/en_US/FlashPlatform/reference/actionscript/3/RegExp.html

Re: [FALCONJX][FLEXJS] XML handling (was Re: [FlexJS] Back port)

Posted by Alex Harui <ah...@adobe.com>.

On 2/17/16, 5:47 PM, "jude" <fl...@gmail.com> wrote:

>If AIR has a comparable API use that, if it doesn't then use native
>process. And instead of environment variables use GUI and save those
>values
>to a shared object.

But Windows doesn't even have native processes for grep and sed and
requiring CygWin or GitBash doesn't seem like a good idea.   And saving to
a shared object doesn't help you run Ant on your CI server.

But again, if you want to take a shot at it, I'd be interested to see what
you come up with.

-Alex


Re: [FALCONJX][FLEXJS] XML handling (was Re: [FlexJS] Back port)

Posted by jude <fl...@gmail.com>.
If AIR has a comparable API use that, if it doesn't then use native
process. And instead of environment variables use GUI and save those values
to a shared object.


On 2/15/16, 5:17 PM, "jude" <fl...@gmail.com> wrote:

>some ideas: the first time I used ant I loved it but as soon as i asked it
>to do anything complex it became a major pain, imo.
>
>when I was helping harbs with TLF it took me a week and a lot of patience
>to get it setup.
>
>I understand why there are build engineers now. I'm really hesitant to try
>and make ant work with any project.

So what do you use instead of Ant?

>
>but for people like me, and others the process has to be easier to set up.
>I'm not saying that's for you to do but I think it would be better to use
>actionscript instead. why not create an AIR app? use as3 to check for
>environment variables, ask for directories, use those with the file class
>to copy things where they need to go. have a build button. maybe it's not
>possible. idk.

IMO, Ant and Maven take care of a lot of cross-platform stuff that AIR
doesn't (grep, sed, etc).  We have emulated a significant number of Ant
tasks in AS already, but some of the hard ones are missing.  And if I
deploy and AIR app, it needs its own release cycle.  IMO, too much work
for the benefit for me to want to stop feature development to work on it.
But definitely give it a try if you are so inclined.

I'm not saying it isn't complex, and I do wish it was easier, but this is
the 4th time I've devoted at least a day to trying to make it easier.  And
so far, it hasn't seemed to move the needle.  Maybe it will this time.

-Alex

Re: [FALCONJX][FLEXJS] XML handling (was Re: [FlexJS] Back port)

Posted by Alex Harui <ah...@adobe.com>.

On 2/15/16, 5:17 PM, "jude" <fl...@gmail.com> wrote:

>some ideas: the first time I used ant I loved it but as soon as i asked it
>to do anything complex it became a major pain, imo.
>
>when I was helping harbs with TLF it took me a week and a lot of patience
>to get it setup.
>
>I understand why there are build engineers now. I'm really hesitant to try
>and make ant work with any project.

So what do you use instead of Ant?

>
>but for people like me, and others the process has to be easier to set up.
>I'm not saying that's for you to do but I think it would be better to use
>actionscript instead. why not create an AIR app? use as3 to check for
>environment variables, ask for directories, use those with the file class
>to copy things where they need to go. have a build button. maybe it's not
>possible. idk.

IMO, Ant and Maven take care of a lot of cross-platform stuff that AIR
doesn't (grep, sed, etc).  We have emulated a significant number of Ant
tasks in AS already, but some of the hard ones are missing.  And if I
deploy and AIR app, it needs its own release cycle.  IMO, too much work
for the benefit for me to want to stop feature development to work on it.
But definitely give it a try if you are so inclined.

I'm not saying it isn't complex, and I do wish it was easier, but this is
the 4th time I've devoted at least a day to trying to make it easier.  And
so far, it hasn't seemed to move the needle.  Maybe it will this time.

-Alex


Re: [FALCONJX][FLEXJS] XML handling (was Re: [FlexJS] Back port)

Posted by jude <fl...@gmail.com>.
some ideas: the first time I used ant I loved it but as soon as i asked it
to do anything complex it became a major pain, imo.

when I was helping harbs with TLF it took me a week and a lot of patience
to get it setup.

I understand why there are build engineers now. I'm really hesitant to try
and make ant work with any project.

but for people like me, and others the process has to be easier to set up.
I'm not saying that's for you to do but I think it would be better to use
actionscript instead. why not create an AIR app? use as3 to check for
environment variables, ask for directories, use those with the file class
to copy things where they need to go. have a build button. maybe it's not
possible. idk.

I'm not saying this is for you to do but if install and run was an as3 app
any of us could debug it and even write parts if it. just an idea. in fact,
I might be able to help on it. I'll see if I can get something started this
week if there's interest.
On Feb 15, 2016 2:38 PM, "Alex Harui" <ah...@adobe.com> wrote:

> I have not seen anyone offer to make a fix.  I am mostly done with a
> change. Hopefully it will go in tonight.
>
>
> Sent from my LG G3, an AT&T 4G LTE smartphone
>
>
> ------ Original message------
>
> From: OmPrakash Muppirala
>
> Date: Mon, Feb 15, 2016 1:55 PM
>
> To: dev@flex.apache.org;
>
> Subject:Re: [FALCONJX][FLEXJS] XML handling (was Re: [FlexJS] Back port)
>
>
> Alex,
>
> The way I am reading this thread, I don't think folks are asking you to
> make the changes.  They are generally asking if it is okay to make these
> kind of changes.  It would be good if you are okay with the changes since
> you are one of the affected parties.
>
> Thanks,
> Om
>
> On Mon, Feb 15, 2016 at 1:36 PM, Alex Harui <ah...@adobe.com> wrote:
>
> >
> >
> > On 2/15/16, 1:32 PM, "Michael Schmalle" <te...@gmail.com>
> wrote:
> >
> > >Alex, if I had time I wouldn't do it. :) I hate build stuff and this is
> > >exactly why I set that template file up.
> >
> > Well, I'm glad it worked for you, and it worked for me, but now I am
> > spending time trying to implement something else to make others happy.
> > Yes, we want to make it easier for others to contribute, but I don't like
> > it that it always falls on me to try to figure it out for others.
> >
> > -Alex
> >
> >
>

Re: [FALCONJX]Compiling Falcon with externs problems

Posted by Alex Harui <ah...@adobe.com>.
Glad you got it to work.  Somehow, I messed up my Git commands and the
env.properties change for flex-falcon got stashed instead of committed.  I
just pushed It now, so you shouldn't need unittest.properties any more.
An env.properties file will override unittest.properties.

-Alex

On 2/16/16, 4:33 AM, "Harbs" <ha...@gmail.com> wrote:

>Yay!
>
>I got asjs to compile and XML compiles as well. The build failed because
>of errors, but at least the errors make sense.
>
>I can now get back to work. Phew!
>
>Thanks Alex for bearing with me… ;-)
>
>FWIW, I put together some instructions in a Google Doc with things that
>tripped me up. I’ll put it in the wiki when it makes sense.
>https://docs.google.com/document/d/1na0UI3c_d0c6EroVLzNTaUGLoPXeD5Y9v-s-Rg
>X1ohQ/edit?usp=sharing
>
>Harbs
>
>On Feb 16, 2016, at 2:17 PM, Harbs <ha...@gmail.com> wrote:
>
>> OK.
>> 
>> It looks like my problem was due to some outdated files from previous
>>compilations.
>> 
>> I completely removed the flex-falcon folder and checked out a fresh
>>copy of the repo, and my problems seem to have gone away.
>> 
>> I just got a successful build of falcon! :-)
>> 
>> Trying to compile asjs now…
>> 
>> On Feb 16, 2016, at 12:19 PM, Harbs <ha...@gmail.com> wrote:
>> 
>>> Renaming this because this has nothing to do with XML.
>>> 
>>> I’ve been trying various things related to the externs and nothing I’m
>>>doing seems to be right.
>>> 
>>> 1. Running it with all my existing externs files causes an error that
>>>Window and Console are undefined.
>>> 2. Removing the js externs files causes an error because svg.js is
>>>missing when the js compile-config file looks for it in line 71.
>>> 3. Adding just svg.js back in causes an error on line 56 because the
>>>interfaces path is missing (I cleared out the “out” folder thinking it
>>>would get regenerated.)
>>> 
>>> I looked through the build script to try and find where the externs
>>>files are supposed to be downloaded, but I could not find it. I’m also
>>>having trouble following the order of events in terms of generating the
>>>extern-related files.
>>> 
>>> I’m out of time for this morning. I’ll try again later, but if anyone
>>>can give me some pointers, it might help this lost traveler… ;-)
>>> 
>>> Harbs
>>> 
>>> On Feb 16, 2016, at 11:14 AM, Harbs <ha...@gmail.com> wrote:
>>> 
>>>> It looks improved to me. I still needed to add the
>>>>unittest.properties file, but that’s fine.
>>>> 
>>>> I now seem to be getting stuck on externs. I’m trying to figure out
>>>>what’s not set up properly on my machine, but if anyone has pointers
>>>>please pipe up.
>>>> 
>>>> externc.js.swc:
>>>>      [java] Feb 16, 2016 11:05:24 AM
>>>>com.google.javascript.jscomp.LoggerErrorManager println
>>>>      [java] WARNING: [es6]:87: WARNING - Keywords and reserved words
>>>>are not allowed as unquoted property names in older versions of
>>>>JavaScript. If you are targeting newer versions of JavaScript, set the
>>>>appropriate language_in option.
>>>>      [java] Generator.prototype.return = function(value) {};
>>>>      [java]                     ^
>>>>      [java] 
>>>>      [java] Feb 16, 2016 11:05:24 AM
>>>>com.google.javascript.jscomp.LoggerErrorManager println
>>>>      [java] WARNING: [es6]:93: WARNING - Keywords and reserved words
>>>>are not allowed as unquoted property names in older versions of
>>>>JavaScript. If you are targeting newer versions of JavaScript, set the
>>>>appropriate language_in option.
>>>>      [java] Generator.prototype.throw = function(exception) {};
>>>>      [java]                     ^
>>>>      [java] 
>>>>      [java] Feb 16, 2016 11:05:24 AM
>>>>com.google.javascript.jscomp.LoggerErrorManager println
>>>>      [java] WARNING: [es6]:898: WARNING - Keywords and reserved words
>>>>are not allowed as unquoted property names in older versions of
>>>>JavaScript. If you are targeting newer versions of JavaScript, set the
>>>>appropriate language_in option.
>>>>      [java] Promise.prototype.catch = function(onRejected) {};
>>>>      [java]                   ^
>>>>      [java] 
>>>>      [java] Feb 16, 2016 11:05:24 AM
>>>>com.google.javascript.jscomp.LoggerErrorManager println
>>>>      [java] SEVERE: [missing]:91: ERROR - Parse error. identifier is
>>>>a reserved word
>>>>      [java] function int() {}
>>>>      [java]          ^
>>>>      [java] 
>>>>      [java] Feb 16, 2016 11:05:24 AM
>>>>com.google.javascript.jscomp.LoggerErrorManager println
>>>>      [java] SEVERE: [missing]:97: ERROR - Parse error. identifier is
>>>>a reserved word
>>>>      [java] int.prototype.toString = function(opt_radix) {}
>>>>      [java] ^
>>>>      [java] 
>>>>      [java] Feb 16, 2016 11:05:24 AM
>>>>com.google.javascript.jscomp.LoggerErrorManager printSummary
>>>>      [java] WARNING: 2 error(s), 3 warning(s)
>>>>      [java] 0.839131 seconds
>>>>      [java] Java Result: 255
>>>>      [copy] Copying 1 file to
>>>>/Users/harbs/Documents/ApacheFlex/flex-falcon/externs/js/out/as/classes
>>>>     [mkdir] Created dir:
>>>>/Users/harbs/Documents/ApacheFlex/flex-falcon/externs/js/out/as/classes
>>>>/__AS3__/vec
>>>>      [copy] Copying 1 file to
>>>>/Users/harbs/Documents/ApacheFlex/flex-falcon/externs/js/out/as/classes
>>>>/__AS3__/vec
>>>>      [copy] Copying 1 file to
>>>>/Users/harbs/Documents/ApacheFlex/flex-falcon/externs/js/out/as/classes
>>>>/__AS3__/vec
>>>>      [copy] Copying 1 file to
>>>>/Users/harbs/Documents/ApacheFlex/flex-falcon/externs/js/out/as/classes
>>>>/__AS3__/vec
>>>>      [copy] Copying 1 file to
>>>>/Users/harbs/Documents/ApacheFlex/flex-falcon/externs/js/out/as/classes
>>>>/__AS3__/vec
>>>>      [copy] Copying 1 file to
>>>>/Users/harbs/Documents/ApacheFlex/flex-falcon/externs/js/out/as/classes
>>>>/__AS3__/vec
>>>>      [java] Loading configuration:
>>>>/Users/harbs/Documents/ApacheFlex/flex-falcon/externs/js/compile-config
>>>>.xml
>>>>      [java] 
>>>>      [java] 
>>>>/Users/harbs/Documents/ApacheFlex/flex-falcon/externs/js/out/as/constan
>>>>ts/console.as:3
>>>>      [java] Error: Type was not found or was not a compile-time
>>>>constant: Console.
>>>>      [java]     public const console:Console = undefined;
>>>>      [java]                          ^
>>>>      [java] 
>>>>      [java] 
>>>>/Users/harbs/Documents/ApacheFlex/flex-falcon/externs/js/out/as/constan
>>>>ts/window.as:3
>>>>      [java] Error: Type was not found or was not a compile-time
>>>>constant: Window.
>>>>      [java]     public const window:Window = undefined;
>>>>      [java]                         ^
>>>>      [java] 
>>>> 
>>>> BUILD FAILED
>>>> /Users/harbs/Documents/ApacheFlex/flex-asjs/build.xml:1552: The
>>>>following error occurred while executing this line:
>>>> /Users/harbs/Documents/ApacheFlex/flex-asjs/build.xml:1693: The
>>>>following error occurred while executing this line:
>>>> /Users/harbs/Documents/ApacheFlex/flex-falcon/build.xml:674: Java
>>>>returned: 2
>>>> 
>>>> On Feb 16, 2016, at 10:36 AM, Harbs <ha...@gmail.com> wrote:
>>>> 
>>>>> Thanks for that. I’ll give it a go. If it does not work, I’ll try
>>>>>and figure out why without “complaining” first… ;-)
>>>>> 
>>>>> On Feb 16, 2016, at 10:32 AM, Alex Harui <ah...@adobe.com> wrote:
>>>>> 
>>>>>> 
>>>>>> 
>>>>>> On 2/15/16, 2:38 PM, "Alex Harui" <ah...@adobe.com> wrote:
>>>>>> 
>>>>>>> I have not seen anyone offer to make a fix.  I am mostly done with
>>>>>>>a
>>>>>>> change. Hopefully it will go in tonight.
>>>>>>> 
>>>>>> 
>>>>>> OK, I pushed changes to flex-falcon and flex-asjs.
>>>>>> 
>>>>>> In each of flex-falcon, flex-sdk and flex-asjs, set up an
>>>>>>env.properties
>>>>>> file by copying the env-template.properties file in the root of
>>>>>>each repo
>>>>>> (they are slightly different).
>>>>>> 
>>>>>> In each of the env.properties files, I think you only need to set
>>>>>> AIR_HOME, PLAYERGLOBAL_HOME and FLASHPLAYER_DEBUGGER.  Leave the
>>>>>>rest
>>>>>> commented out.
>>>>>> 
>>>>>> Then for me, running "ant all" in flex-asjs, built everything
>>>>>> successfully.  I'll bet I missed something somewhere, but maybe
>>>>>>we'll get
>>>>>> lucky.
>>>>>> 
>>>>>> -Alex
>>>>>> 
>>>>> 
>>>> 
>>> 
>> 
>


Re: [FALCONJX]Compiling Falcon with externs problems

Posted by Harbs <ha...@gmail.com>.
Yay!

I got asjs to compile and XML compiles as well. The build failed because of errors, but at least the errors make sense.

I can now get back to work. Phew!

Thanks Alex for bearing with me… ;-)

FWIW, I put together some instructions in a Google Doc with things that tripped me up. I’ll put it in the wiki when it makes sense.
https://docs.google.com/document/d/1na0UI3c_d0c6EroVLzNTaUGLoPXeD5Y9v-s-RgX1ohQ/edit?usp=sharing

Harbs

On Feb 16, 2016, at 2:17 PM, Harbs <ha...@gmail.com> wrote:

> OK.
> 
> It looks like my problem was due to some outdated files from previous compilations.
> 
> I completely removed the flex-falcon folder and checked out a fresh copy of the repo, and my problems seem to have gone away.
> 
> I just got a successful build of falcon! :-)
> 
> Trying to compile asjs now…
> 
> On Feb 16, 2016, at 12:19 PM, Harbs <ha...@gmail.com> wrote:
> 
>> Renaming this because this has nothing to do with XML.
>> 
>> I’ve been trying various things related to the externs and nothing I’m doing seems to be right.
>> 
>> 1. Running it with all my existing externs files causes an error that Window and Console are undefined.
>> 2. Removing the js externs files causes an error because svg.js is missing when the js compile-config file looks for it in line 71.
>> 3. Adding just svg.js back in causes an error on line 56 because the interfaces path is missing (I cleared out the “out” folder thinking it would get regenerated.)
>> 
>> I looked through the build script to try and find where the externs files are supposed to be downloaded, but I could not find it. I’m also having trouble following the order of events in terms of generating the extern-related files.
>> 
>> I’m out of time for this morning. I’ll try again later, but if anyone can give me some pointers, it might help this lost traveler… ;-)
>> 
>> Harbs
>> 
>> On Feb 16, 2016, at 11:14 AM, Harbs <ha...@gmail.com> wrote:
>> 
>>> It looks improved to me. I still needed to add the unittest.properties file, but that’s fine.
>>> 
>>> I now seem to be getting stuck on externs. I’m trying to figure out what’s not set up properly on my machine, but if anyone has pointers please pipe up.
>>> 
>>> externc.js.swc:
>>>      [java] Feb 16, 2016 11:05:24 AM com.google.javascript.jscomp.LoggerErrorManager println
>>>      [java] WARNING: [es6]:87: WARNING - Keywords and reserved words are not allowed as unquoted property names in older versions of JavaScript. If you are targeting newer versions of JavaScript, set the appropriate language_in option.
>>>      [java] Generator.prototype.return = function(value) {};
>>>      [java]                     ^
>>>      [java] 
>>>      [java] Feb 16, 2016 11:05:24 AM com.google.javascript.jscomp.LoggerErrorManager println
>>>      [java] WARNING: [es6]:93: WARNING - Keywords and reserved words are not allowed as unquoted property names in older versions of JavaScript. If you are targeting newer versions of JavaScript, set the appropriate language_in option.
>>>      [java] Generator.prototype.throw = function(exception) {};
>>>      [java]                     ^
>>>      [java] 
>>>      [java] Feb 16, 2016 11:05:24 AM com.google.javascript.jscomp.LoggerErrorManager println
>>>      [java] WARNING: [es6]:898: WARNING - Keywords and reserved words are not allowed as unquoted property names in older versions of JavaScript. If you are targeting newer versions of JavaScript, set the appropriate language_in option.
>>>      [java] Promise.prototype.catch = function(onRejected) {};
>>>      [java]                   ^
>>>      [java] 
>>>      [java] Feb 16, 2016 11:05:24 AM com.google.javascript.jscomp.LoggerErrorManager println
>>>      [java] SEVERE: [missing]:91: ERROR - Parse error. identifier is a reserved word
>>>      [java] function int() {}
>>>      [java]          ^
>>>      [java] 
>>>      [java] Feb 16, 2016 11:05:24 AM com.google.javascript.jscomp.LoggerErrorManager println
>>>      [java] SEVERE: [missing]:97: ERROR - Parse error. identifier is a reserved word
>>>      [java] int.prototype.toString = function(opt_radix) {}
>>>      [java] ^
>>>      [java] 
>>>      [java] Feb 16, 2016 11:05:24 AM com.google.javascript.jscomp.LoggerErrorManager printSummary
>>>      [java] WARNING: 2 error(s), 3 warning(s)
>>>      [java] 0.839131 seconds
>>>      [java] Java Result: 255
>>>      [copy] Copying 1 file to /Users/harbs/Documents/ApacheFlex/flex-falcon/externs/js/out/as/classes
>>>     [mkdir] Created dir: /Users/harbs/Documents/ApacheFlex/flex-falcon/externs/js/out/as/classes/__AS3__/vec
>>>      [copy] Copying 1 file to /Users/harbs/Documents/ApacheFlex/flex-falcon/externs/js/out/as/classes/__AS3__/vec
>>>      [copy] Copying 1 file to /Users/harbs/Documents/ApacheFlex/flex-falcon/externs/js/out/as/classes/__AS3__/vec
>>>      [copy] Copying 1 file to /Users/harbs/Documents/ApacheFlex/flex-falcon/externs/js/out/as/classes/__AS3__/vec
>>>      [copy] Copying 1 file to /Users/harbs/Documents/ApacheFlex/flex-falcon/externs/js/out/as/classes/__AS3__/vec
>>>      [copy] Copying 1 file to /Users/harbs/Documents/ApacheFlex/flex-falcon/externs/js/out/as/classes/__AS3__/vec
>>>      [java] Loading configuration: /Users/harbs/Documents/ApacheFlex/flex-falcon/externs/js/compile-config.xml
>>>      [java] 
>>>      [java] /Users/harbs/Documents/ApacheFlex/flex-falcon/externs/js/out/as/constants/console.as:3
>>>      [java] Error: Type was not found or was not a compile-time constant: Console.
>>>      [java]     public const console:Console = undefined;
>>>      [java]                          ^
>>>      [java] 
>>>      [java] /Users/harbs/Documents/ApacheFlex/flex-falcon/externs/js/out/as/constants/window.as:3
>>>      [java] Error: Type was not found or was not a compile-time constant: Window.
>>>      [java]     public const window:Window = undefined;
>>>      [java]                         ^
>>>      [java] 
>>> 
>>> BUILD FAILED
>>> /Users/harbs/Documents/ApacheFlex/flex-asjs/build.xml:1552: The following error occurred while executing this line:
>>> /Users/harbs/Documents/ApacheFlex/flex-asjs/build.xml:1693: The following error occurred while executing this line:
>>> /Users/harbs/Documents/ApacheFlex/flex-falcon/build.xml:674: Java returned: 2
>>> 
>>> On Feb 16, 2016, at 10:36 AM, Harbs <ha...@gmail.com> wrote:
>>> 
>>>> Thanks for that. I’ll give it a go. If it does not work, I’ll try and figure out why without “complaining” first… ;-)
>>>> 
>>>> On Feb 16, 2016, at 10:32 AM, Alex Harui <ah...@adobe.com> wrote:
>>>> 
>>>>> 
>>>>> 
>>>>> On 2/15/16, 2:38 PM, "Alex Harui" <ah...@adobe.com> wrote:
>>>>> 
>>>>>> I have not seen anyone offer to make a fix.  I am mostly done with a
>>>>>> change. Hopefully it will go in tonight.
>>>>>> 
>>>>> 
>>>>> OK, I pushed changes to flex-falcon and flex-asjs.
>>>>> 
>>>>> In each of flex-falcon, flex-sdk and flex-asjs, set up an env.properties
>>>>> file by copying the env-template.properties file in the root of each repo
>>>>> (they are slightly different).
>>>>> 
>>>>> In each of the env.properties files, I think you only need to set
>>>>> AIR_HOME, PLAYERGLOBAL_HOME and FLASHPLAYER_DEBUGGER.  Leave the rest
>>>>> commented out.
>>>>> 
>>>>> Then for me, running "ant all" in flex-asjs, built everything
>>>>> successfully.  I'll bet I missed something somewhere, but maybe we'll get
>>>>> lucky.
>>>>> 
>>>>> -Alex
>>>>> 
>>>> 
>>> 
>> 
> 


AW: [FALCONJX]Compiling Falcon with externs problems

Posted by Christofer Dutz <ch...@c-ware.de>.
Hi,

these are exactly the type of problems I was so sick of :-( Probably I was cursed by them more often, cause I didn't update my project that often. How about we do the same update of the directory structure as with some of the ASJS directories in Falcon too? This way we could make sure all generated and compiled stuff is located underneath a "target" directory and a simple delete would make sure that any legacy content is removed. 

And I could eventually whip up a parallel Maven build much easier ... wich would in turn result in automated SNAPSHOTs of Falcon, which would be the prerequisite of providing SNAPSHOT versions of FlexJS (ASJS)? I'd love to work on that.

And ... I am currently giving a 3-day Maven training for two insurance companies ... so my tutorials and slides are fresh and up-to-date. Think I'd be able to compress everything into a one day Maven bootcamp crash-course. If one of my Talks is selected for ApacheCon, then I'd be able to take the trip and I'd be glad to give a free Maven training, if there is any Interest in this. I would specially be delighted to give Alex and Om such a training so we could achieve a more common understanding for the topic, which would definitely benefit the project greatly cause we could actually start working in the same direction.

Chris

________________________________________
Von: Harbs <ha...@gmail.com>
Gesendet: Dienstag, 16. Februar 2016 13:17
An: dev@flex.apache.org
Betreff: Re: [FALCONJX]Compiling Falcon with externs problems

OK.

It looks like my problem was due to some outdated files from previous compilations.

I completely removed the flex-falcon folder and checked out a fresh copy of the repo, and my problems seem to have gone away.

I just got a successful build of falcon! :-)

Trying to compile asjs now…

On Feb 16, 2016, at 12:19 PM, Harbs <ha...@gmail.com> wrote:

> Renaming this because this has nothing to do with XML.
>
> I’ve been trying various things related to the externs and nothing I’m doing seems to be right.
>
> 1. Running it with all my existing externs files causes an error that Window and Console are undefined.
> 2. Removing the js externs files causes an error because svg.js is missing when the js compile-config file looks for it in line 71.
> 3. Adding just svg.js back in causes an error on line 56 because the interfaces path is missing (I cleared out the “out” folder thinking it would get regenerated.)
>
> I looked through the build script to try and find where the externs files are supposed to be downloaded, but I could not find it. I’m also having trouble following the order of events in terms of generating the extern-related files.
>
> I’m out of time for this morning. I’ll try again later, but if anyone can give me some pointers, it might help this lost traveler… ;-)
>
> Harbs
>
> On Feb 16, 2016, at 11:14 AM, Harbs <ha...@gmail.com> wrote:
>
>> It looks improved to me. I still needed to add the unittest.properties file, but that’s fine.
>>
>> I now seem to be getting stuck on externs. I’m trying to figure out what’s not set up properly on my machine, but if anyone has pointers please pipe up.
>>
>> externc.js.swc:
>>      [java] Feb 16, 2016 11:05:24 AM com.google.javascript.jscomp.LoggerErrorManager println
>>      [java] WARNING: [es6]:87: WARNING - Keywords and reserved words are not allowed as unquoted property names in older versions of JavaScript. If you are targeting newer versions of JavaScript, set the appropriate language_in option.
>>      [java] Generator.prototype.return = function(value) {};
>>      [java]                     ^
>>      [java]
>>      [java] Feb 16, 2016 11:05:24 AM com.google.javascript.jscomp.LoggerErrorManager println
>>      [java] WARNING: [es6]:93: WARNING - Keywords and reserved words are not allowed as unquoted property names in older versions of JavaScript. If you are targeting newer versions of JavaScript, set the appropriate language_in option.
>>      [java] Generator.prototype.throw = function(exception) {};
>>      [java]                     ^
>>      [java]
>>      [java] Feb 16, 2016 11:05:24 AM com.google.javascript.jscomp.LoggerErrorManager println
>>      [java] WARNING: [es6]:898: WARNING - Keywords and reserved words are not allowed as unquoted property names in older versions of JavaScript. If you are targeting newer versions of JavaScript, set the appropriate language_in option.
>>      [java] Promise.prototype.catch = function(onRejected) {};
>>      [java]                   ^
>>      [java]
>>      [java] Feb 16, 2016 11:05:24 AM com.google.javascript.jscomp.LoggerErrorManager println
>>      [java] SEVERE: [missing]:91: ERROR - Parse error. identifier is a reserved word
>>      [java] function int() {}
>>      [java]          ^
>>      [java]
>>      [java] Feb 16, 2016 11:05:24 AM com.google.javascript.jscomp.LoggerErrorManager println
>>      [java] SEVERE: [missing]:97: ERROR - Parse error. identifier is a reserved word
>>      [java] int.prototype.toString = function(opt_radix) {}
>>      [java] ^
>>      [java]
>>      [java] Feb 16, 2016 11:05:24 AM com.google.javascript.jscomp.LoggerErrorManager printSummary
>>      [java] WARNING: 2 error(s), 3 warning(s)
>>      [java] 0.839131 seconds
>>      [java] Java Result: 255
>>      [copy] Copying 1 file to /Users/harbs/Documents/ApacheFlex/flex-falcon/externs/js/out/as/classes
>>     [mkdir] Created dir: /Users/harbs/Documents/ApacheFlex/flex-falcon/externs/js/out/as/classes/__AS3__/vec
>>      [copy] Copying 1 file to /Users/harbs/Documents/ApacheFlex/flex-falcon/externs/js/out/as/classes/__AS3__/vec
>>      [copy] Copying 1 file to /Users/harbs/Documents/ApacheFlex/flex-falcon/externs/js/out/as/classes/__AS3__/vec
>>      [copy] Copying 1 file to /Users/harbs/Documents/ApacheFlex/flex-falcon/externs/js/out/as/classes/__AS3__/vec
>>      [copy] Copying 1 file to /Users/harbs/Documents/ApacheFlex/flex-falcon/externs/js/out/as/classes/__AS3__/vec
>>      [copy] Copying 1 file to /Users/harbs/Documents/ApacheFlex/flex-falcon/externs/js/out/as/classes/__AS3__/vec
>>      [java] Loading configuration: /Users/harbs/Documents/ApacheFlex/flex-falcon/externs/js/compile-config.xml
>>      [java]
>>      [java] /Users/harbs/Documents/ApacheFlex/flex-falcon/externs/js/out/as/constants/console.as:3
>>      [java] Error: Type was not found or was not a compile-time constant: Console.
>>      [java]     public const console:Console = undefined;
>>      [java]                          ^
>>      [java]
>>      [java] /Users/harbs/Documents/ApacheFlex/flex-falcon/externs/js/out/as/constants/window.as:3
>>      [java] Error: Type was not found or was not a compile-time constant: Window.
>>      [java]     public const window:Window = undefined;
>>      [java]                         ^
>>      [java]
>>
>> BUILD FAILED
>> /Users/harbs/Documents/ApacheFlex/flex-asjs/build.xml:1552: The following error occurred while executing this line:
>> /Users/harbs/Documents/ApacheFlex/flex-asjs/build.xml:1693: The following error occurred while executing this line:
>> /Users/harbs/Documents/ApacheFlex/flex-falcon/build.xml:674: Java returned: 2
>>
>> On Feb 16, 2016, at 10:36 AM, Harbs <ha...@gmail.com> wrote:
>>
>>> Thanks for that. I’ll give it a go. If it does not work, I’ll try and figure out why without “complaining” first… ;-)
>>>
>>> On Feb 16, 2016, at 10:32 AM, Alex Harui <ah...@adobe.com> wrote:
>>>
>>>>
>>>>
>>>> On 2/15/16, 2:38 PM, "Alex Harui" <ah...@adobe.com> wrote:
>>>>
>>>>> I have not seen anyone offer to make a fix.  I am mostly done with a
>>>>> change. Hopefully it will go in tonight.
>>>>>
>>>>
>>>> OK, I pushed changes to flex-falcon and flex-asjs.
>>>>
>>>> In each of flex-falcon, flex-sdk and flex-asjs, set up an env.properties
>>>> file by copying the env-template.properties file in the root of each repo
>>>> (they are slightly different).
>>>>
>>>> In each of the env.properties files, I think you only need to set
>>>> AIR_HOME, PLAYERGLOBAL_HOME and FLASHPLAYER_DEBUGGER.  Leave the rest
>>>> commented out.
>>>>
>>>> Then for me, running "ant all" in flex-asjs, built everything
>>>> successfully.  I'll bet I missed something somewhere, but maybe we'll get
>>>> lucky.
>>>>
>>>> -Alex
>>>>
>>>
>>
>


Re: [FALCONJX]Compiling Falcon with externs problems

Posted by OmPrakash Muppirala <bi...@gmail.com>.
On Tue, Feb 16, 2016 at 4:17 AM, Harbs <ha...@gmail.com> wrote:

> OK.
>
> It looks like my problem was due to some outdated files from previous
> compilations.
>
> I completely removed the flex-falcon folder and checked out a fresh copy
> of the repo, and my problems seem to have gone away.
>

I just ran into this same issue.  I did ant wipe-all followed by ant all
and everything was fixed!

The wipe-all target has the same effect of getting a fresh copy of the repo.

Thanks,
Om


>
> I just got a successful build of falcon! :-)
>
> Trying to compile asjs now…
>
> On Feb 16, 2016, at 12:19 PM, Harbs <ha...@gmail.com> wrote:
>
> > Renaming this because this has nothing to do with XML.
> >
> > I’ve been trying various things related to the externs and nothing I’m
> doing seems to be right.
> >
> > 1. Running it with all my existing externs files causes an error that
> Window and Console are undefined.
> > 2. Removing the js externs files causes an error because svg.js is
> missing when the js compile-config file looks for it in line 71.
> > 3. Adding just svg.js back in causes an error on line 56 because the
> interfaces path is missing (I cleared out the “out” folder thinking it
> would get regenerated.)
> >
> > I looked through the build script to try and find where the externs
> files are supposed to be downloaded, but I could not find it. I’m also
> having trouble following the order of events in terms of generating the
> extern-related files.
> >
> > I’m out of time for this morning. I’ll try again later, but if anyone
> can give me some pointers, it might help this lost traveler… ;-)
> >
> > Harbs
> >
> > On Feb 16, 2016, at 11:14 AM, Harbs <ha...@gmail.com> wrote:
> >
> >> It looks improved to me. I still needed to add the unittest.properties
> file, but that’s fine.
> >>
> >> I now seem to be getting stuck on externs. I’m trying to figure out
> what’s not set up properly on my machine, but if anyone has pointers please
> pipe up.
> >>
> >> externc.js.swc:
> >>      [java] Feb 16, 2016 11:05:24 AM
> com.google.javascript.jscomp.LoggerErrorManager println
> >>      [java] WARNING: [es6]:87: WARNING - Keywords and reserved words
> are not allowed as unquoted property names in older versions of JavaScript.
> If you are targeting newer versions of JavaScript, set the appropriate
> language_in option.
> >>      [java] Generator.prototype.return = function(value) {};
> >>      [java]                     ^
> >>      [java]
> >>      [java] Feb 16, 2016 11:05:24 AM
> com.google.javascript.jscomp.LoggerErrorManager println
> >>      [java] WARNING: [es6]:93: WARNING - Keywords and reserved words
> are not allowed as unquoted property names in older versions of JavaScript.
> If you are targeting newer versions of JavaScript, set the appropriate
> language_in option.
> >>      [java] Generator.prototype.throw = function(exception) {};
> >>      [java]                     ^
> >>      [java]
> >>      [java] Feb 16, 2016 11:05:24 AM
> com.google.javascript.jscomp.LoggerErrorManager println
> >>      [java] WARNING: [es6]:898: WARNING - Keywords and reserved words
> are not allowed as unquoted property names in older versions of JavaScript.
> If you are targeting newer versions of JavaScript, set the appropriate
> language_in option.
> >>      [java] Promise.prototype.catch = function(onRejected) {};
> >>      [java]                   ^
> >>      [java]
> >>      [java] Feb 16, 2016 11:05:24 AM
> com.google.javascript.jscomp.LoggerErrorManager println
> >>      [java] SEVERE: [missing]:91: ERROR - Parse error. identifier is a
> reserved word
> >>      [java] function int() {}
> >>      [java]          ^
> >>      [java]
> >>      [java] Feb 16, 2016 11:05:24 AM
> com.google.javascript.jscomp.LoggerErrorManager println
> >>      [java] SEVERE: [missing]:97: ERROR - Parse error. identifier is a
> reserved word
> >>      [java] int.prototype.toString = function(opt_radix) {}
> >>      [java] ^
> >>      [java]
> >>      [java] Feb 16, 2016 11:05:24 AM
> com.google.javascript.jscomp.LoggerErrorManager printSummary
> >>      [java] WARNING: 2 error(s), 3 warning(s)
> >>      [java] 0.839131 seconds
> >>      [java] Java Result: 255
> >>      [copy] Copying 1 file to
> /Users/harbs/Documents/ApacheFlex/flex-falcon/externs/js/out/as/classes
> >>     [mkdir] Created dir:
> /Users/harbs/Documents/ApacheFlex/flex-falcon/externs/js/out/as/classes/__AS3__/vec
> >>      [copy] Copying 1 file to
> /Users/harbs/Documents/ApacheFlex/flex-falcon/externs/js/out/as/classes/__AS3__/vec
> >>      [copy] Copying 1 file to
> /Users/harbs/Documents/ApacheFlex/flex-falcon/externs/js/out/as/classes/__AS3__/vec
> >>      [copy] Copying 1 file to
> /Users/harbs/Documents/ApacheFlex/flex-falcon/externs/js/out/as/classes/__AS3__/vec
> >>      [copy] Copying 1 file to
> /Users/harbs/Documents/ApacheFlex/flex-falcon/externs/js/out/as/classes/__AS3__/vec
> >>      [copy] Copying 1 file to
> /Users/harbs/Documents/ApacheFlex/flex-falcon/externs/js/out/as/classes/__AS3__/vec
> >>      [java] Loading configuration:
> /Users/harbs/Documents/ApacheFlex/flex-falcon/externs/js/compile-config.xml
> >>      [java]
> >>      [java]
> /Users/harbs/Documents/ApacheFlex/flex-falcon/externs/js/out/as/constants/
> console.as:3
> >>      [java] Error: Type was not found or was not a compile-time
> constant: Console.
> >>      [java]     public const console:Console = undefined;
> >>      [java]                          ^
> >>      [java]
> >>      [java]
> /Users/harbs/Documents/ApacheFlex/flex-falcon/externs/js/out/as/constants/
> window.as:3
> >>      [java] Error: Type was not found or was not a compile-time
> constant: Window.
> >>      [java]     public const window:Window = undefined;
> >>      [java]                         ^
> >>      [java]
> >>
> >> BUILD FAILED
> >> /Users/harbs/Documents/ApacheFlex/flex-asjs/build.xml:1552: The
> following error occurred while executing this line:
> >> /Users/harbs/Documents/ApacheFlex/flex-asjs/build.xml:1693: The
> following error occurred while executing this line:
> >> /Users/harbs/Documents/ApacheFlex/flex-falcon/build.xml:674: Java
> returned: 2
> >>
> >> On Feb 16, 2016, at 10:36 AM, Harbs <ha...@gmail.com> wrote:
> >>
> >>> Thanks for that. I’ll give it a go. If it does not work, I’ll try and
> figure out why without “complaining” first… ;-)
> >>>
> >>> On Feb 16, 2016, at 10:32 AM, Alex Harui <ah...@adobe.com> wrote:
> >>>
> >>>>
> >>>>
> >>>> On 2/15/16, 2:38 PM, "Alex Harui" <ah...@adobe.com> wrote:
> >>>>
> >>>>> I have not seen anyone offer to make a fix.  I am mostly done with a
> >>>>> change. Hopefully it will go in tonight.
> >>>>>
> >>>>
> >>>> OK, I pushed changes to flex-falcon and flex-asjs.
> >>>>
> >>>> In each of flex-falcon, flex-sdk and flex-asjs, set up an
> env.properties
> >>>> file by copying the env-template.properties file in the root of each
> repo
> >>>> (they are slightly different).
> >>>>
> >>>> In each of the env.properties files, I think you only need to set
> >>>> AIR_HOME, PLAYERGLOBAL_HOME and FLASHPLAYER_DEBUGGER.  Leave the rest
> >>>> commented out.
> >>>>
> >>>> Then for me, running "ant all" in flex-asjs, built everything
> >>>> successfully.  I'll bet I missed something somewhere, but maybe we'll
> get
> >>>> lucky.
> >>>>
> >>>> -Alex
> >>>>
> >>>
> >>
> >
>
>

Re: [FALCONJX]Compiling Falcon with externs problems

Posted by Harbs <ha...@gmail.com>.
OK.

It looks like my problem was due to some outdated files from previous compilations.

I completely removed the flex-falcon folder and checked out a fresh copy of the repo, and my problems seem to have gone away.

I just got a successful build of falcon! :-)

Trying to compile asjs now…

On Feb 16, 2016, at 12:19 PM, Harbs <ha...@gmail.com> wrote:

> Renaming this because this has nothing to do with XML.
> 
> I’ve been trying various things related to the externs and nothing I’m doing seems to be right.
> 
> 1. Running it with all my existing externs files causes an error that Window and Console are undefined.
> 2. Removing the js externs files causes an error because svg.js is missing when the js compile-config file looks for it in line 71.
> 3. Adding just svg.js back in causes an error on line 56 because the interfaces path is missing (I cleared out the “out” folder thinking it would get regenerated.)
> 
> I looked through the build script to try and find where the externs files are supposed to be downloaded, but I could not find it. I’m also having trouble following the order of events in terms of generating the extern-related files.
> 
> I’m out of time for this morning. I’ll try again later, but if anyone can give me some pointers, it might help this lost traveler… ;-)
> 
> Harbs
> 
> On Feb 16, 2016, at 11:14 AM, Harbs <ha...@gmail.com> wrote:
> 
>> It looks improved to me. I still needed to add the unittest.properties file, but that’s fine.
>> 
>> I now seem to be getting stuck on externs. I’m trying to figure out what’s not set up properly on my machine, but if anyone has pointers please pipe up.
>> 
>> externc.js.swc:
>>      [java] Feb 16, 2016 11:05:24 AM com.google.javascript.jscomp.LoggerErrorManager println
>>      [java] WARNING: [es6]:87: WARNING - Keywords and reserved words are not allowed as unquoted property names in older versions of JavaScript. If you are targeting newer versions of JavaScript, set the appropriate language_in option.
>>      [java] Generator.prototype.return = function(value) {};
>>      [java]                     ^
>>      [java] 
>>      [java] Feb 16, 2016 11:05:24 AM com.google.javascript.jscomp.LoggerErrorManager println
>>      [java] WARNING: [es6]:93: WARNING - Keywords and reserved words are not allowed as unquoted property names in older versions of JavaScript. If you are targeting newer versions of JavaScript, set the appropriate language_in option.
>>      [java] Generator.prototype.throw = function(exception) {};
>>      [java]                     ^
>>      [java] 
>>      [java] Feb 16, 2016 11:05:24 AM com.google.javascript.jscomp.LoggerErrorManager println
>>      [java] WARNING: [es6]:898: WARNING - Keywords and reserved words are not allowed as unquoted property names in older versions of JavaScript. If you are targeting newer versions of JavaScript, set the appropriate language_in option.
>>      [java] Promise.prototype.catch = function(onRejected) {};
>>      [java]                   ^
>>      [java] 
>>      [java] Feb 16, 2016 11:05:24 AM com.google.javascript.jscomp.LoggerErrorManager println
>>      [java] SEVERE: [missing]:91: ERROR - Parse error. identifier is a reserved word
>>      [java] function int() {}
>>      [java]          ^
>>      [java] 
>>      [java] Feb 16, 2016 11:05:24 AM com.google.javascript.jscomp.LoggerErrorManager println
>>      [java] SEVERE: [missing]:97: ERROR - Parse error. identifier is a reserved word
>>      [java] int.prototype.toString = function(opt_radix) {}
>>      [java] ^
>>      [java] 
>>      [java] Feb 16, 2016 11:05:24 AM com.google.javascript.jscomp.LoggerErrorManager printSummary
>>      [java] WARNING: 2 error(s), 3 warning(s)
>>      [java] 0.839131 seconds
>>      [java] Java Result: 255
>>      [copy] Copying 1 file to /Users/harbs/Documents/ApacheFlex/flex-falcon/externs/js/out/as/classes
>>     [mkdir] Created dir: /Users/harbs/Documents/ApacheFlex/flex-falcon/externs/js/out/as/classes/__AS3__/vec
>>      [copy] Copying 1 file to /Users/harbs/Documents/ApacheFlex/flex-falcon/externs/js/out/as/classes/__AS3__/vec
>>      [copy] Copying 1 file to /Users/harbs/Documents/ApacheFlex/flex-falcon/externs/js/out/as/classes/__AS3__/vec
>>      [copy] Copying 1 file to /Users/harbs/Documents/ApacheFlex/flex-falcon/externs/js/out/as/classes/__AS3__/vec
>>      [copy] Copying 1 file to /Users/harbs/Documents/ApacheFlex/flex-falcon/externs/js/out/as/classes/__AS3__/vec
>>      [copy] Copying 1 file to /Users/harbs/Documents/ApacheFlex/flex-falcon/externs/js/out/as/classes/__AS3__/vec
>>      [java] Loading configuration: /Users/harbs/Documents/ApacheFlex/flex-falcon/externs/js/compile-config.xml
>>      [java] 
>>      [java] /Users/harbs/Documents/ApacheFlex/flex-falcon/externs/js/out/as/constants/console.as:3
>>      [java] Error: Type was not found or was not a compile-time constant: Console.
>>      [java]     public const console:Console = undefined;
>>      [java]                          ^
>>      [java] 
>>      [java] /Users/harbs/Documents/ApacheFlex/flex-falcon/externs/js/out/as/constants/window.as:3
>>      [java] Error: Type was not found or was not a compile-time constant: Window.
>>      [java]     public const window:Window = undefined;
>>      [java]                         ^
>>      [java] 
>> 
>> BUILD FAILED
>> /Users/harbs/Documents/ApacheFlex/flex-asjs/build.xml:1552: The following error occurred while executing this line:
>> /Users/harbs/Documents/ApacheFlex/flex-asjs/build.xml:1693: The following error occurred while executing this line:
>> /Users/harbs/Documents/ApacheFlex/flex-falcon/build.xml:674: Java returned: 2
>> 
>> On Feb 16, 2016, at 10:36 AM, Harbs <ha...@gmail.com> wrote:
>> 
>>> Thanks for that. I’ll give it a go. If it does not work, I’ll try and figure out why without “complaining” first… ;-)
>>> 
>>> On Feb 16, 2016, at 10:32 AM, Alex Harui <ah...@adobe.com> wrote:
>>> 
>>>> 
>>>> 
>>>> On 2/15/16, 2:38 PM, "Alex Harui" <ah...@adobe.com> wrote:
>>>> 
>>>>> I have not seen anyone offer to make a fix.  I am mostly done with a
>>>>> change. Hopefully it will go in tonight.
>>>>> 
>>>> 
>>>> OK, I pushed changes to flex-falcon and flex-asjs.
>>>> 
>>>> In each of flex-falcon, flex-sdk and flex-asjs, set up an env.properties
>>>> file by copying the env-template.properties file in the root of each repo
>>>> (they are slightly different).
>>>> 
>>>> In each of the env.properties files, I think you only need to set
>>>> AIR_HOME, PLAYERGLOBAL_HOME and FLASHPLAYER_DEBUGGER.  Leave the rest
>>>> commented out.
>>>> 
>>>> Then for me, running "ant all" in flex-asjs, built everything
>>>> successfully.  I'll bet I missed something somewhere, but maybe we'll get
>>>> lucky.
>>>> 
>>>> -Alex
>>>> 
>>> 
>> 
> 


Re: [FALCONJX]Compiling Falcon with externs problems

Posted by Harbs <ha...@gmail.com>.
Renaming this because this has nothing to do with XML.

I’ve been trying various things related to the externs and nothing I’m doing seems to be right.

1. Running it with all my existing externs files causes an error that Window and Console are undefined.
2. Removing the js externs files causes an error because svg.js is missing when the js compile-config file looks for it in line 71.
3. Adding just svg.js back in causes an error on line 56 because the interfaces path is missing (I cleared out the “out” folder thinking it would get regenerated.)

I looked through the build script to try and find where the externs files are supposed to be downloaded, but I could not find it. I’m also having trouble following the order of events in terms of generating the extern-related files.

I’m out of time for this morning. I’ll try again later, but if anyone can give me some pointers, it might help this lost traveler… ;-)

Harbs

On Feb 16, 2016, at 11:14 AM, Harbs <ha...@gmail.com> wrote:

> It looks improved to me. I still needed to add the unittest.properties file, but that’s fine.
> 
> I now seem to be getting stuck on externs. I’m trying to figure out what’s not set up properly on my machine, but if anyone has pointers please pipe up.
> 
> externc.js.swc:
>      [java] Feb 16, 2016 11:05:24 AM com.google.javascript.jscomp.LoggerErrorManager println
>      [java] WARNING: [es6]:87: WARNING - Keywords and reserved words are not allowed as unquoted property names in older versions of JavaScript. If you are targeting newer versions of JavaScript, set the appropriate language_in option.
>      [java] Generator.prototype.return = function(value) {};
>      [java]                     ^
>      [java] 
>      [java] Feb 16, 2016 11:05:24 AM com.google.javascript.jscomp.LoggerErrorManager println
>      [java] WARNING: [es6]:93: WARNING - Keywords and reserved words are not allowed as unquoted property names in older versions of JavaScript. If you are targeting newer versions of JavaScript, set the appropriate language_in option.
>      [java] Generator.prototype.throw = function(exception) {};
>      [java]                     ^
>      [java] 
>      [java] Feb 16, 2016 11:05:24 AM com.google.javascript.jscomp.LoggerErrorManager println
>      [java] WARNING: [es6]:898: WARNING - Keywords and reserved words are not allowed as unquoted property names in older versions of JavaScript. If you are targeting newer versions of JavaScript, set the appropriate language_in option.
>      [java] Promise.prototype.catch = function(onRejected) {};
>      [java]                   ^
>      [java] 
>      [java] Feb 16, 2016 11:05:24 AM com.google.javascript.jscomp.LoggerErrorManager println
>      [java] SEVERE: [missing]:91: ERROR - Parse error. identifier is a reserved word
>      [java] function int() {}
>      [java]          ^
>      [java] 
>      [java] Feb 16, 2016 11:05:24 AM com.google.javascript.jscomp.LoggerErrorManager println
>      [java] SEVERE: [missing]:97: ERROR - Parse error. identifier is a reserved word
>      [java] int.prototype.toString = function(opt_radix) {}
>      [java] ^
>      [java] 
>      [java] Feb 16, 2016 11:05:24 AM com.google.javascript.jscomp.LoggerErrorManager printSummary
>      [java] WARNING: 2 error(s), 3 warning(s)
>      [java] 0.839131 seconds
>      [java] Java Result: 255
>      [copy] Copying 1 file to /Users/harbs/Documents/ApacheFlex/flex-falcon/externs/js/out/as/classes
>     [mkdir] Created dir: /Users/harbs/Documents/ApacheFlex/flex-falcon/externs/js/out/as/classes/__AS3__/vec
>      [copy] Copying 1 file to /Users/harbs/Documents/ApacheFlex/flex-falcon/externs/js/out/as/classes/__AS3__/vec
>      [copy] Copying 1 file to /Users/harbs/Documents/ApacheFlex/flex-falcon/externs/js/out/as/classes/__AS3__/vec
>      [copy] Copying 1 file to /Users/harbs/Documents/ApacheFlex/flex-falcon/externs/js/out/as/classes/__AS3__/vec
>      [copy] Copying 1 file to /Users/harbs/Documents/ApacheFlex/flex-falcon/externs/js/out/as/classes/__AS3__/vec
>      [copy] Copying 1 file to /Users/harbs/Documents/ApacheFlex/flex-falcon/externs/js/out/as/classes/__AS3__/vec
>      [java] Loading configuration: /Users/harbs/Documents/ApacheFlex/flex-falcon/externs/js/compile-config.xml
>      [java] 
>      [java] /Users/harbs/Documents/ApacheFlex/flex-falcon/externs/js/out/as/constants/console.as:3
>      [java] Error: Type was not found or was not a compile-time constant: Console.
>      [java]     public const console:Console = undefined;
>      [java]                          ^
>      [java] 
>      [java] /Users/harbs/Documents/ApacheFlex/flex-falcon/externs/js/out/as/constants/window.as:3
>      [java] Error: Type was not found or was not a compile-time constant: Window.
>      [java]     public const window:Window = undefined;
>      [java]                         ^
>      [java] 
> 
> BUILD FAILED
> /Users/harbs/Documents/ApacheFlex/flex-asjs/build.xml:1552: The following error occurred while executing this line:
> /Users/harbs/Documents/ApacheFlex/flex-asjs/build.xml:1693: The following error occurred while executing this line:
> /Users/harbs/Documents/ApacheFlex/flex-falcon/build.xml:674: Java returned: 2
> 
> On Feb 16, 2016, at 10:36 AM, Harbs <ha...@gmail.com> wrote:
> 
>> Thanks for that. I’ll give it a go. If it does not work, I’ll try and figure out why without “complaining” first… ;-)
>> 
>> On Feb 16, 2016, at 10:32 AM, Alex Harui <ah...@adobe.com> wrote:
>> 
>>> 
>>> 
>>> On 2/15/16, 2:38 PM, "Alex Harui" <ah...@adobe.com> wrote:
>>> 
>>>> I have not seen anyone offer to make a fix.  I am mostly done with a
>>>> change. Hopefully it will go in tonight.
>>>> 
>>> 
>>> OK, I pushed changes to flex-falcon and flex-asjs.
>>> 
>>> In each of flex-falcon, flex-sdk and flex-asjs, set up an env.properties
>>> file by copying the env-template.properties file in the root of each repo
>>> (they are slightly different).
>>> 
>>> In each of the env.properties files, I think you only need to set
>>> AIR_HOME, PLAYERGLOBAL_HOME and FLASHPLAYER_DEBUGGER.  Leave the rest
>>> commented out.
>>> 
>>> Then for me, running "ant all" in flex-asjs, built everything
>>> successfully.  I'll bet I missed something somewhere, but maybe we'll get
>>> lucky.
>>> 
>>> -Alex
>>> 
>> 
> 


Re: [FALCONJX][FLEXJS] XML handling (was Re: [FlexJS] Back port)

Posted by Harbs <ha...@gmail.com>.
The error definitely makes sense because I don’t see Window and Console defined anywhere. I’m having trouble finding what created the constant files. I tried removing the externs folder from the js folder in the hope that it would be re-created (hopefully in a better fashion), but I get an error that svg.js cannot be found.

How do I re-download the externs files? I do not remember what I did to have them downloaded originally.

On Feb 16, 2016, at 11:14 AM, Harbs <ha...@gmail.com> wrote:

> It looks improved to me. I still needed to add the unittest.properties file, but that’s fine.
> 
> I now seem to be getting stuck on externs. I’m trying to figure out what’s not set up properly on my machine, but if anyone has pointers please pipe up.
> 
> externc.js.swc:
>      [java] Feb 16, 2016 11:05:24 AM com.google.javascript.jscomp.LoggerErrorManager println
>      [java] WARNING: [es6]:87: WARNING - Keywords and reserved words are not allowed as unquoted property names in older versions of JavaScript. If you are targeting newer versions of JavaScript, set the appropriate language_in option.
>      [java] Generator.prototype.return = function(value) {};
>      [java]                     ^
>      [java] 
>      [java] Feb 16, 2016 11:05:24 AM com.google.javascript.jscomp.LoggerErrorManager println
>      [java] WARNING: [es6]:93: WARNING - Keywords and reserved words are not allowed as unquoted property names in older versions of JavaScript. If you are targeting newer versions of JavaScript, set the appropriate language_in option.
>      [java] Generator.prototype.throw = function(exception) {};
>      [java]                     ^
>      [java] 
>      [java] Feb 16, 2016 11:05:24 AM com.google.javascript.jscomp.LoggerErrorManager println
>      [java] WARNING: [es6]:898: WARNING - Keywords and reserved words are not allowed as unquoted property names in older versions of JavaScript. If you are targeting newer versions of JavaScript, set the appropriate language_in option.
>      [java] Promise.prototype.catch = function(onRejected) {};
>      [java]                   ^
>      [java] 
>      [java] Feb 16, 2016 11:05:24 AM com.google.javascript.jscomp.LoggerErrorManager println
>      [java] SEVERE: [missing]:91: ERROR - Parse error. identifier is a reserved word
>      [java] function int() {}
>      [java]          ^
>      [java] 
>      [java] Feb 16, 2016 11:05:24 AM com.google.javascript.jscomp.LoggerErrorManager println
>      [java] SEVERE: [missing]:97: ERROR - Parse error. identifier is a reserved word
>      [java] int.prototype.toString = function(opt_radix) {}
>      [java] ^
>      [java] 
>      [java] Feb 16, 2016 11:05:24 AM com.google.javascript.jscomp.LoggerErrorManager printSummary
>      [java] WARNING: 2 error(s), 3 warning(s)
>      [java] 0.839131 seconds
>      [java] Java Result: 255
>      [copy] Copying 1 file to /Users/harbs/Documents/ApacheFlex/flex-falcon/externs/js/out/as/classes
>     [mkdir] Created dir: /Users/harbs/Documents/ApacheFlex/flex-falcon/externs/js/out/as/classes/__AS3__/vec
>      [copy] Copying 1 file to /Users/harbs/Documents/ApacheFlex/flex-falcon/externs/js/out/as/classes/__AS3__/vec
>      [copy] Copying 1 file to /Users/harbs/Documents/ApacheFlex/flex-falcon/externs/js/out/as/classes/__AS3__/vec
>      [copy] Copying 1 file to /Users/harbs/Documents/ApacheFlex/flex-falcon/externs/js/out/as/classes/__AS3__/vec
>      [copy] Copying 1 file to /Users/harbs/Documents/ApacheFlex/flex-falcon/externs/js/out/as/classes/__AS3__/vec
>      [copy] Copying 1 file to /Users/harbs/Documents/ApacheFlex/flex-falcon/externs/js/out/as/classes/__AS3__/vec
>      [java] Loading configuration: /Users/harbs/Documents/ApacheFlex/flex-falcon/externs/js/compile-config.xml
>      [java] 
>      [java] /Users/harbs/Documents/ApacheFlex/flex-falcon/externs/js/out/as/constants/console.as:3
>      [java] Error: Type was not found or was not a compile-time constant: Console.
>      [java]     public const console:Console = undefined;
>      [java]                          ^
>      [java] 
>      [java] /Users/harbs/Documents/ApacheFlex/flex-falcon/externs/js/out/as/constants/window.as:3
>      [java] Error: Type was not found or was not a compile-time constant: Window.
>      [java]     public const window:Window = undefined;
>      [java]                         ^
>      [java] 
> 
> BUILD FAILED
> /Users/harbs/Documents/ApacheFlex/flex-asjs/build.xml:1552: The following error occurred while executing this line:
> /Users/harbs/Documents/ApacheFlex/flex-asjs/build.xml:1693: The following error occurred while executing this line:
> /Users/harbs/Documents/ApacheFlex/flex-falcon/build.xml:674: Java returned: 2
> 
> On Feb 16, 2016, at 10:36 AM, Harbs <ha...@gmail.com> wrote:
> 
>> Thanks for that. I’ll give it a go. If it does not work, I’ll try and figure out why without “complaining” first… ;-)
>> 
>> On Feb 16, 2016, at 10:32 AM, Alex Harui <ah...@adobe.com> wrote:
>> 
>>> 
>>> 
>>> On 2/15/16, 2:38 PM, "Alex Harui" <ah...@adobe.com> wrote:
>>> 
>>>> I have not seen anyone offer to make a fix.  I am mostly done with a
>>>> change. Hopefully it will go in tonight.
>>>> 
>>> 
>>> OK, I pushed changes to flex-falcon and flex-asjs.
>>> 
>>> In each of flex-falcon, flex-sdk and flex-asjs, set up an env.properties
>>> file by copying the env-template.properties file in the root of each repo
>>> (they are slightly different).
>>> 
>>> In each of the env.properties files, I think you only need to set
>>> AIR_HOME, PLAYERGLOBAL_HOME and FLASHPLAYER_DEBUGGER.  Leave the rest
>>> commented out.
>>> 
>>> Then for me, running "ant all" in flex-asjs, built everything
>>> successfully.  I'll bet I missed something somewhere, but maybe we'll get
>>> lucky.
>>> 
>>> -Alex
>>> 
>> 
> 


Re: [FALCONJX][FLEXJS] XML handling (was Re: [FlexJS] Back port)

Posted by Harbs <ha...@gmail.com>.
It looks improved to me. I still needed to add the unittest.properties file, but that’s fine.

I now seem to be getting stuck on externs. I’m trying to figure out what’s not set up properly on my machine, but if anyone has pointers please pipe up.

externc.js.swc:
     [java] Feb 16, 2016 11:05:24 AM com.google.javascript.jscomp.LoggerErrorManager println
     [java] WARNING: [es6]:87: WARNING - Keywords and reserved words are not allowed as unquoted property names in older versions of JavaScript. If you are targeting newer versions of JavaScript, set the appropriate language_in option.
     [java] Generator.prototype.return = function(value) {};
     [java]                     ^
     [java] 
     [java] Feb 16, 2016 11:05:24 AM com.google.javascript.jscomp.LoggerErrorManager println
     [java] WARNING: [es6]:93: WARNING - Keywords and reserved words are not allowed as unquoted property names in older versions of JavaScript. If you are targeting newer versions of JavaScript, set the appropriate language_in option.
     [java] Generator.prototype.throw = function(exception) {};
     [java]                     ^
     [java] 
     [java] Feb 16, 2016 11:05:24 AM com.google.javascript.jscomp.LoggerErrorManager println
     [java] WARNING: [es6]:898: WARNING - Keywords and reserved words are not allowed as unquoted property names in older versions of JavaScript. If you are targeting newer versions of JavaScript, set the appropriate language_in option.
     [java] Promise.prototype.catch = function(onRejected) {};
     [java]                   ^
     [java] 
     [java] Feb 16, 2016 11:05:24 AM com.google.javascript.jscomp.LoggerErrorManager println
     [java] SEVERE: [missing]:91: ERROR - Parse error. identifier is a reserved word
     [java] function int() {}
     [java]          ^
     [java] 
     [java] Feb 16, 2016 11:05:24 AM com.google.javascript.jscomp.LoggerErrorManager println
     [java] SEVERE: [missing]:97: ERROR - Parse error. identifier is a reserved word
     [java] int.prototype.toString = function(opt_radix) {}
     [java] ^
     [java] 
     [java] Feb 16, 2016 11:05:24 AM com.google.javascript.jscomp.LoggerErrorManager printSummary
     [java] WARNING: 2 error(s), 3 warning(s)
     [java] 0.839131 seconds
     [java] Java Result: 255
     [copy] Copying 1 file to /Users/harbs/Documents/ApacheFlex/flex-falcon/externs/js/out/as/classes
    [mkdir] Created dir: /Users/harbs/Documents/ApacheFlex/flex-falcon/externs/js/out/as/classes/__AS3__/vec
     [copy] Copying 1 file to /Users/harbs/Documents/ApacheFlex/flex-falcon/externs/js/out/as/classes/__AS3__/vec
     [copy] Copying 1 file to /Users/harbs/Documents/ApacheFlex/flex-falcon/externs/js/out/as/classes/__AS3__/vec
     [copy] Copying 1 file to /Users/harbs/Documents/ApacheFlex/flex-falcon/externs/js/out/as/classes/__AS3__/vec
     [copy] Copying 1 file to /Users/harbs/Documents/ApacheFlex/flex-falcon/externs/js/out/as/classes/__AS3__/vec
     [copy] Copying 1 file to /Users/harbs/Documents/ApacheFlex/flex-falcon/externs/js/out/as/classes/__AS3__/vec
     [java] Loading configuration: /Users/harbs/Documents/ApacheFlex/flex-falcon/externs/js/compile-config.xml
     [java] 
     [java] /Users/harbs/Documents/ApacheFlex/flex-falcon/externs/js/out/as/constants/console.as:3
     [java] Error: Type was not found or was not a compile-time constant: Console.
     [java]     public const console:Console = undefined;
     [java]                          ^
     [java] 
     [java] /Users/harbs/Documents/ApacheFlex/flex-falcon/externs/js/out/as/constants/window.as:3
     [java] Error: Type was not found or was not a compile-time constant: Window.
     [java]     public const window:Window = undefined;
     [java]                         ^
     [java] 

BUILD FAILED
/Users/harbs/Documents/ApacheFlex/flex-asjs/build.xml:1552: The following error occurred while executing this line:
/Users/harbs/Documents/ApacheFlex/flex-asjs/build.xml:1693: The following error occurred while executing this line:
/Users/harbs/Documents/ApacheFlex/flex-falcon/build.xml:674: Java returned: 2

On Feb 16, 2016, at 10:36 AM, Harbs <ha...@gmail.com> wrote:

> Thanks for that. I’ll give it a go. If it does not work, I’ll try and figure out why without “complaining” first… ;-)
> 
> On Feb 16, 2016, at 10:32 AM, Alex Harui <ah...@adobe.com> wrote:
> 
>> 
>> 
>> On 2/15/16, 2:38 PM, "Alex Harui" <ah...@adobe.com> wrote:
>> 
>>> I have not seen anyone offer to make a fix.  I am mostly done with a
>>> change. Hopefully it will go in tonight.
>>> 
>> 
>> OK, I pushed changes to flex-falcon and flex-asjs.
>> 
>> In each of flex-falcon, flex-sdk and flex-asjs, set up an env.properties
>> file by copying the env-template.properties file in the root of each repo
>> (they are slightly different).
>> 
>> In each of the env.properties files, I think you only need to set
>> AIR_HOME, PLAYERGLOBAL_HOME and FLASHPLAYER_DEBUGGER.  Leave the rest
>> commented out.
>> 
>> Then for me, running "ant all" in flex-asjs, built everything
>> successfully.  I'll bet I missed something somewhere, but maybe we'll get
>> lucky.
>> 
>> -Alex
>> 
> 


Re: [FALCONJX][FLEXJS] XML handling (was Re: [FlexJS] Back port)

Posted by Harbs <ha...@gmail.com>.
Thanks for that. I’ll give it a go. If it does not work, I’ll try and figure out why without “complaining” first… ;-)

On Feb 16, 2016, at 10:32 AM, Alex Harui <ah...@adobe.com> wrote:

> 
> 
> On 2/15/16, 2:38 PM, "Alex Harui" <ah...@adobe.com> wrote:
> 
>> I have not seen anyone offer to make a fix.  I am mostly done with a
>> change. Hopefully it will go in tonight.
>> 
> 
> OK, I pushed changes to flex-falcon and flex-asjs.
> 
> In each of flex-falcon, flex-sdk and flex-asjs, set up an env.properties
> file by copying the env-template.properties file in the root of each repo
> (they are slightly different).
> 
> In each of the env.properties files, I think you only need to set
> AIR_HOME, PLAYERGLOBAL_HOME and FLASHPLAYER_DEBUGGER.  Leave the rest
> commented out.
> 
> Then for me, running "ant all" in flex-asjs, built everything
> successfully.  I'll bet I missed something somewhere, but maybe we'll get
> lucky.
> 
> -Alex
> 


Re: [FALCONJX][FLEXJS] XML handling (was Re: [FlexJS] Back port)

Posted by Josh Tynjala <jo...@gmail.com>.
Thank you, Alex. I am able to build flex-falcon successfully using only
env.properties. I was able to remove the unittest.properties files, and my
env.properties file now only defines these three values: env.AIR_HOME,
env.FLASHPLAYER_DEBUGGER, and env.PLAYERGLOBAL_HOME.

This is an Ant build that pretty much anyone should be able to get up and
running easily using either env.properties or real environment variables.
Thank you for your efforts. I know it's not fun work, but you've put us in
a good place for new contributors.

- Josh

On Tue, Feb 16, 2016 at 1:32 AM, Alex Harui <ah...@adobe.com> wrote:

>
> In each of the env.properties files, I think you only need to set
> AIR_HOME, PLAYERGLOBAL_HOME and FLASHPLAYER_DEBUGGER.  Leave the rest
> commented out.
>

Re: [FALCONJX][FLEXJS] XML handling (was Re: [FlexJS] Back port)

Posted by Alex Harui <ah...@adobe.com>.

On 2/15/16, 2:38 PM, "Alex Harui" <ah...@adobe.com> wrote:

>I have not seen anyone offer to make a fix.  I am mostly done with a
>change. Hopefully it will go in tonight.
>

OK, I pushed changes to flex-falcon and flex-asjs.

In each of flex-falcon, flex-sdk and flex-asjs, set up an env.properties
file by copying the env-template.properties file in the root of each repo
(they are slightly different).

In each of the env.properties files, I think you only need to set
AIR_HOME, PLAYERGLOBAL_HOME and FLASHPLAYER_DEBUGGER.  Leave the rest
commented out.

Then for me, running "ant all" in flex-asjs, built everything
successfully.  I'll bet I missed something somewhere, but maybe we'll get
lucky.

-Alex


Re: [FALCONJX][FLEXJS] XML handling (was Re: [FlexJS] Back port)

Posted by Alex Harui <ah...@adobe.com>.
I have not seen anyone offer to make a fix.  I am mostly done with a change. Hopefully it will go in tonight.


Sent from my LG G3, an AT&T 4G LTE smartphone


------ Original message------

From: OmPrakash Muppirala

Date: Mon, Feb 15, 2016 1:55 PM

To: dev@flex.apache.org;

Subject:Re: [FALCONJX][FLEXJS] XML handling (was Re: [FlexJS] Back port)


Alex,

The way I am reading this thread, I don't think folks are asking you to
make the changes.  They are generally asking if it is okay to make these
kind of changes.  It would be good if you are okay with the changes since
you are one of the affected parties.

Thanks,
Om

On Mon, Feb 15, 2016 at 1:36 PM, Alex Harui <ah...@adobe.com> wrote:

>
>
> On 2/15/16, 1:32 PM, "Michael Schmalle" <te...@gmail.com> wrote:
>
> >Alex, if I had time I wouldn't do it. :) I hate build stuff and this is
> >exactly why I set that template file up.
>
> Well, I'm glad it worked for you, and it worked for me, but now I am
> spending time trying to implement something else to make others happy.
> Yes, we want to make it easier for others to contribute, but I don't like
> it that it always falls on me to try to figure it out for others.
>
> -Alex
>
>

Re: [FALCONJX][FLEXJS] XML handling (was Re: [FlexJS] Back port)

Posted by OmPrakash Muppirala <bi...@gmail.com>.
Alex,

The way I am reading this thread, I don't think folks are asking you to
make the changes.  They are generally asking if it is okay to make these
kind of changes.  It would be good if you are okay with the changes since
you are one of the affected parties.

Thanks,
Om

On Mon, Feb 15, 2016 at 1:36 PM, Alex Harui <ah...@adobe.com> wrote:

>
>
> On 2/15/16, 1:32 PM, "Michael Schmalle" <te...@gmail.com> wrote:
>
> >Alex, if I had time I wouldn't do it. :) I hate build stuff and this is
> >exactly why I set that template file up.
>
> Well, I'm glad it worked for you, and it worked for me, but now I am
> spending time trying to implement something else to make others happy.
> Yes, we want to make it easier for others to contribute, but I don't like
> it that it always falls on me to try to figure it out for others.
>
> -Alex
>
>

Re: [FALCONJX][FLEXJS] XML handling (was Re: [FlexJS] Back port)

Posted by Alex Harui <ah...@adobe.com>.

On 2/15/16, 1:54 PM, "Michael Schmalle" <te...@gmail.com> wrote:

>On Mon, Feb 15, 2016 at 4:36 PM, Alex Harui <ah...@adobe.com> wrote:
>
>>
>>
>> On 2/15/16, 1:32 PM, "Michael Schmalle" <te...@gmail.com>
>>wrote:
>>
>> >Alex, if I had time I wouldn't do it. :) I hate build stuff and this is
>> >exactly why I set that template file up.
>>
>> Well, I'm glad it worked for you, and it worked for me, but now I am
>> spending time trying to implement something else to make others happy.
>> Yes, we want to make it easier for others to contribute, but I don't
>>like
>> it that it always falls on me to try to figure it out for others.
>>
>
>Seriously I don't understand, I worked on it off and on for 1.5 years and
>came back 2 years later and got it to work the first time. So is it really
>broken?

It isn't broken, it is too difficult for folks to figure out who don't
want to dig into the compiler.

-Alex


Re: [FALCONJX][FLEXJS] XML handling (was Re: [FlexJS] Back port)

Posted by Michael Schmalle <te...@gmail.com>.
On Mon, Feb 15, 2016 at 4:36 PM, Alex Harui <ah...@adobe.com> wrote:

>
>
> On 2/15/16, 1:32 PM, "Michael Schmalle" <te...@gmail.com> wrote:
>
> >Alex, if I had time I wouldn't do it. :) I hate build stuff and this is
> >exactly why I set that template file up.
>
> Well, I'm glad it worked for you, and it worked for me, but now I am
> spending time trying to implement something else to make others happy.
> Yes, we want to make it easier for others to contribute, but I don't like
> it that it always falls on me to try to figure it out for others.
>

Seriously I don't understand, I worked on it off and on for 1.5 years and
came back 2 years later and got it to work the first time. So is it really
broken?

I was only trying to add humor to your situation which I get. I have 2-3
weeks before the uploads to google play start with my audio stuff. After
that if I get some monetary stuff coming in, I can finally start to venture
out into more experimental directions and I was investigating Cordova as we
talked before.

Although, if I get more time this next 2-3 months, I am no good at these
massive build targets.

Mike



>
> -Alex
>
>

Re: [FALCONJX][FLEXJS] XML handling (was Re: [FlexJS] Back port)

Posted by Alex Harui <ah...@adobe.com>.

On 2/15/16, 1:32 PM, "Michael Schmalle" <te...@gmail.com> wrote:

>Alex, if I had time I wouldn't do it. :) I hate build stuff and this is
>exactly why I set that template file up.

Well, I'm glad it worked for you, and it worked for me, but now I am
spending time trying to implement something else to make others happy.
Yes, we want to make it easier for others to contribute, but I don't like
it that it always falls on me to try to figure it out for others.

-Alex


Re: [FALCONJX][FLEXJS] XML handling (was Re: [FlexJS] Back port)

Posted by Michael Schmalle <te...@gmail.com>.
Alex, if I had time I wouldn't do it. :) I hate build stuff and this is
exactly why I set that template file up.

I have never had a problem getting things going, so people that are having
problems are missing a step or two.

It seems like a youtube video showing exactly the steps would help hehehe.
;-)

Mike

On Mon, Feb 15, 2016 at 4:20 PM, Alex Harui <ah...@adobe.com> wrote:

> And there is a template-unittest.properties file in compiler.tests which
> explains the options.
>
> The README supposedly contains sufficient information to build from
> sources since several PMC members have successfully done so and voted to
> release.
>
> I don't know how much time to devote to make the build system simpler.
> Some place have full time build engineers.  Should I become a full-time
> build engineer and stop developing features?  Everyone has their favorite
> way of configuring their system.  I am not enjoying trying to guess what
> people want to do.  This is not my itch that I want to scratch, but
> apparently, nobody else has the time to make it better.  They just want to
> complain.  I've been using scripts that set environment variables for
> years.  It seems to work for me.
>
> I will try to get the build system to read an env.properties file from a
> repo root.  I don't think we can have an uber env.properties.  We can't
> guarantee all repos will stay in sync.
>
> -Alex
>
> On 2/15/16, 9:16 AM, "Josh Tynjala" <jo...@gmail.com> wrote:
>
> >I think I found that you need to add unittest.properties in both compiler
> >and compiler.jx. The readme file has details about what properties should
> >be defined. It's near the bottom, as I recall, which means it's easy to
> >miss.
> >
> >I agree with Harbs that we should probably make this simpler. Instead of a
> >separate properties file for tests, why not use env.properties?
> >
> >- Josh
> >On Feb 15, 2016 8:01 AM, "Harbs" <ha...@gmail.com> wrote:
> >
> >> Where do I need to set the unittest.properties file?
> >>
> >> I’m happy to do so, but I think it would be great if we could at least
> >>get
> >> some instructions on everything needed to build from source.
> >>
> >> Every time I come back to this, I have trouble. Maybe it’s just me, but
> >>it
> >> seems like it raises the bar needed to contribute.
> >>
> >> On Feb 15, 2016, at 5:01 PM, Alex Harui <ah...@adobe.com> wrote:
> >>
> >> >
> >> >
> >> > On 2/14/16, 11:52 PM, "Harbs" <ha...@gmail.com> wrote:
> >> >
> >> >> Cleaning the repo seemed to have helped somewhat, but I still could
> >>not
> >> >> compile, and I’m assuming because I need to build falcon:
> >> >> Buildfile:
> >> >>
> >>
> >>/Users/harbs/Documents/ApacheFlex/flex-asjs/frameworks/projects/XML/build
> >>.
> >> >> xml
> >> >>
> >> >> clean:
> >> >>
> >> >> check-falcon-home:
> >> >>    [echo] FALCON_HOME is
> >> >> /Users/harbs/Documents/ApacheFlex/flex-falcon/compiler
> >> >>
> >> >> check-falconjx-home:
> >> >>    [echo] FALCONJX_HOME is
> >> >> /Users/harbs/Documents/ApacheFlex/flex-falcon/compiler.jx
> >> >
> >> > This implies you still have environment variables set somehow.  The
> >> > defaults would use relative paths with ../ in them.
> >> > Do you have an env.properties file or local.properties file?
> >> >
> >> >
> >> >>
> >> >> unit.tests:
> >> >>   [junit] unittest.properties not found
> >> >>   [junit] environment property - FLEX_HOME =
> >> >>
> >>
> >>/Users/harbs/Documents/ApacheFlex/flex-falcon/compiler/generated/dist/sdk
> >> >>   [junit] environment property - PLAYERGLOBAL_HOME =
> >> >>
> >>
> >>/Users/harbs/Documents/ApacheFlex/flex-falcon/compiler/generated/dist/sdk
> >>/
> >> >> frameworks/libs/player
> >> >>   [junit] environment property - PLAYERGLOBAL_VERSION = 11.1
> >> >>   [junit] environment property - TLF_HOME = null
> >> >>   [junit] environment property - AIR_HOME = null
> >> >>   [junit] environment property - FLASHPLAYER_DEBUGGER = null
> >> >
> >> > I will spend time today trying to get the build to work without
> >> > unittest.properties files, but I think it will still require setting
> >> > PLAYERGLOBAL_HOME, AIR_HOME, FLASHPLAYER_DEBUGGER and maybe
> >> > PLAYERGLOBAL_VERSION in the environment.  I have spent several hours
> >> > already trying to make sure folks don't have to specify relative
> >>paths to
> >> > other Apache Flex repos, but right now we don't have a good way to
> >>guess
> >> > where folks put the Adobe stuff.
> >> >
> >> > -Alex
> >>
> >>
>
>

Re: [FALCONJX][FLEXJS] XML handling (was Re: [FlexJS] Back port)

Posted by Michael Schmalle <te...@gmail.com>.
This all came back to the beginning. The tests(Falcon, etal) were a
nightmare, I'm talking 2012.

When I started writing the FalconJX compiler and created falcon.jx and
falcon.jx.tests Eclipse projects, I needed something that worked, so I
created the template file so it would work in the two projects I was
developing. I didn't need to run the falcon tests all the time.

Anyway, it's just one of those legacy hacks that can be corrected by
somebody that knows how to fix it. :)

Mike

On Mon, Feb 15, 2016 at 12:16 PM, Josh Tynjala <jo...@gmail.com>
wrote:

> I think I found that you need to add unittest.properties in both compiler
> and compiler.jx. The readme file has details about what properties should
> be defined. It's near the bottom, as I recall, which means it's easy to
> miss.
>
> I agree with Harbs that we should probably make this simpler. Instead of a
> separate properties file for tests, why not use env.properties?
>
> - Josh
> On Feb 15, 2016 8:01 AM, "Harbs" <ha...@gmail.com> wrote:
>
> > Where do I need to set the unittest.properties file?
> >
> > I’m happy to do so, but I think it would be great if we could at least
> get
> > some instructions on everything needed to build from source.
> >
> > Every time I come back to this, I have trouble. Maybe it’s just me, but
> it
> > seems like it raises the bar needed to contribute.
> >
> > On Feb 15, 2016, at 5:01 PM, Alex Harui <ah...@adobe.com> wrote:
> >
> > >
> > >
> > > On 2/14/16, 11:52 PM, "Harbs" <ha...@gmail.com> wrote:
> > >
> > >> Cleaning the repo seemed to have helped somewhat, but I still could
> not
> > >> compile, and I’m assuming because I need to build falcon:
> > >> Buildfile:
> > >>
> >
> /Users/harbs/Documents/ApacheFlex/flex-asjs/frameworks/projects/XML/build.
> > >> xml
> > >>
> > >> clean:
> > >>
> > >> check-falcon-home:
> > >>    [echo] FALCON_HOME is
> > >> /Users/harbs/Documents/ApacheFlex/flex-falcon/compiler
> > >>
> > >> check-falconjx-home:
> > >>    [echo] FALCONJX_HOME is
> > >> /Users/harbs/Documents/ApacheFlex/flex-falcon/compiler.jx
> > >
> > > This implies you still have environment variables set somehow.  The
> > > defaults would use relative paths with ../ in them.
> > > Do you have an env.properties file or local.properties file?
> > >
> > >
> > >>
> > >> unit.tests:
> > >>   [junit] unittest.properties not found
> > >>   [junit] environment property - FLEX_HOME =
> > >>
> > /Users/harbs/Documents/ApacheFlex/flex-falcon/compiler/generated/dist/sdk
> > >>   [junit] environment property - PLAYERGLOBAL_HOME =
> > >>
> >
> /Users/harbs/Documents/ApacheFlex/flex-falcon/compiler/generated/dist/sdk/
> > >> frameworks/libs/player
> > >>   [junit] environment property - PLAYERGLOBAL_VERSION = 11.1
> > >>   [junit] environment property - TLF_HOME = null
> > >>   [junit] environment property - AIR_HOME = null
> > >>   [junit] environment property - FLASHPLAYER_DEBUGGER = null
> > >
> > > I will spend time today trying to get the build to work without
> > > unittest.properties files, but I think it will still require setting
> > > PLAYERGLOBAL_HOME, AIR_HOME, FLASHPLAYER_DEBUGGER and maybe
> > > PLAYERGLOBAL_VERSION in the environment.  I have spent several hours
> > > already trying to make sure folks don't have to specify relative paths
> to
> > > other Apache Flex repos, but right now we don't have a good way to
> guess
> > > where folks put the Adobe stuff.
> > >
> > > -Alex
> >
> >
>

Re: [FALCONJX][FLEXJS] XML handling (was Re: [FlexJS] Back port)

Posted by Alex Harui <ah...@adobe.com>.
And there is a template-unittest.properties file in compiler.tests which
explains the options.

The README supposedly contains sufficient information to build from
sources since several PMC members have successfully done so and voted to
release.

I don't know how much time to devote to make the build system simpler.
Some place have full time build engineers.  Should I become a full-time
build engineer and stop developing features?  Everyone has their favorite
way of configuring their system.  I am not enjoying trying to guess what
people want to do.  This is not my itch that I want to scratch, but
apparently, nobody else has the time to make it better.  They just want to
complain.  I've been using scripts that set environment variables for
years.  It seems to work for me.

I will try to get the build system to read an env.properties file from a
repo root.  I don't think we can have an uber env.properties.  We can't
guarantee all repos will stay in sync.

-Alex

On 2/15/16, 9:16 AM, "Josh Tynjala" <jo...@gmail.com> wrote:

>I think I found that you need to add unittest.properties in both compiler
>and compiler.jx. The readme file has details about what properties should
>be defined. It's near the bottom, as I recall, which means it's easy to
>miss.
>
>I agree with Harbs that we should probably make this simpler. Instead of a
>separate properties file for tests, why not use env.properties?
>
>- Josh
>On Feb 15, 2016 8:01 AM, "Harbs" <ha...@gmail.com> wrote:
>
>> Where do I need to set the unittest.properties file?
>>
>> I’m happy to do so, but I think it would be great if we could at least
>>get
>> some instructions on everything needed to build from source.
>>
>> Every time I come back to this, I have trouble. Maybe it’s just me, but
>>it
>> seems like it raises the bar needed to contribute.
>>
>> On Feb 15, 2016, at 5:01 PM, Alex Harui <ah...@adobe.com> wrote:
>>
>> >
>> >
>> > On 2/14/16, 11:52 PM, "Harbs" <ha...@gmail.com> wrote:
>> >
>> >> Cleaning the repo seemed to have helped somewhat, but I still could
>>not
>> >> compile, and I’m assuming because I need to build falcon:
>> >> Buildfile:
>> >>
>> 
>>/Users/harbs/Documents/ApacheFlex/flex-asjs/frameworks/projects/XML/build
>>.
>> >> xml
>> >>
>> >> clean:
>> >>
>> >> check-falcon-home:
>> >>    [echo] FALCON_HOME is
>> >> /Users/harbs/Documents/ApacheFlex/flex-falcon/compiler
>> >>
>> >> check-falconjx-home:
>> >>    [echo] FALCONJX_HOME is
>> >> /Users/harbs/Documents/ApacheFlex/flex-falcon/compiler.jx
>> >
>> > This implies you still have environment variables set somehow.  The
>> > defaults would use relative paths with ../ in them.
>> > Do you have an env.properties file or local.properties file?
>> >
>> >
>> >>
>> >> unit.tests:
>> >>   [junit] unittest.properties not found
>> >>   [junit] environment property - FLEX_HOME =
>> >>
>> 
>>/Users/harbs/Documents/ApacheFlex/flex-falcon/compiler/generated/dist/sdk
>> >>   [junit] environment property - PLAYERGLOBAL_HOME =
>> >>
>> 
>>/Users/harbs/Documents/ApacheFlex/flex-falcon/compiler/generated/dist/sdk
>>/
>> >> frameworks/libs/player
>> >>   [junit] environment property - PLAYERGLOBAL_VERSION = 11.1
>> >>   [junit] environment property - TLF_HOME = null
>> >>   [junit] environment property - AIR_HOME = null
>> >>   [junit] environment property - FLASHPLAYER_DEBUGGER = null
>> >
>> > I will spend time today trying to get the build to work without
>> > unittest.properties files, but I think it will still require setting
>> > PLAYERGLOBAL_HOME, AIR_HOME, FLASHPLAYER_DEBUGGER and maybe
>> > PLAYERGLOBAL_VERSION in the environment.  I have spent several hours
>> > already trying to make sure folks don't have to specify relative
>>paths to
>> > other Apache Flex repos, but right now we don't have a good way to
>>guess
>> > where folks put the Adobe stuff.
>> >
>> > -Alex
>>
>>


Re: [FALCONJX][FLEXJS] XML handling (was Re: [FlexJS] Back port)

Posted by Josh Tynjala <jo...@gmail.com>.
I think I found that you need to add unittest.properties in both compiler
and compiler.jx. The readme file has details about what properties should
be defined. It's near the bottom, as I recall, which means it's easy to
miss.

I agree with Harbs that we should probably make this simpler. Instead of a
separate properties file for tests, why not use env.properties?

- Josh
On Feb 15, 2016 8:01 AM, "Harbs" <ha...@gmail.com> wrote:

> Where do I need to set the unittest.properties file?
>
> I’m happy to do so, but I think it would be great if we could at least get
> some instructions on everything needed to build from source.
>
> Every time I come back to this, I have trouble. Maybe it’s just me, but it
> seems like it raises the bar needed to contribute.
>
> On Feb 15, 2016, at 5:01 PM, Alex Harui <ah...@adobe.com> wrote:
>
> >
> >
> > On 2/14/16, 11:52 PM, "Harbs" <ha...@gmail.com> wrote:
> >
> >> Cleaning the repo seemed to have helped somewhat, but I still could not
> >> compile, and I’m assuming because I need to build falcon:
> >> Buildfile:
> >>
> /Users/harbs/Documents/ApacheFlex/flex-asjs/frameworks/projects/XML/build.
> >> xml
> >>
> >> clean:
> >>
> >> check-falcon-home:
> >>    [echo] FALCON_HOME is
> >> /Users/harbs/Documents/ApacheFlex/flex-falcon/compiler
> >>
> >> check-falconjx-home:
> >>    [echo] FALCONJX_HOME is
> >> /Users/harbs/Documents/ApacheFlex/flex-falcon/compiler.jx
> >
> > This implies you still have environment variables set somehow.  The
> > defaults would use relative paths with ../ in them.
> > Do you have an env.properties file or local.properties file?
> >
> >
> >>
> >> unit.tests:
> >>   [junit] unittest.properties not found
> >>   [junit] environment property - FLEX_HOME =
> >>
> /Users/harbs/Documents/ApacheFlex/flex-falcon/compiler/generated/dist/sdk
> >>   [junit] environment property - PLAYERGLOBAL_HOME =
> >>
> /Users/harbs/Documents/ApacheFlex/flex-falcon/compiler/generated/dist/sdk/
> >> frameworks/libs/player
> >>   [junit] environment property - PLAYERGLOBAL_VERSION = 11.1
> >>   [junit] environment property - TLF_HOME = null
> >>   [junit] environment property - AIR_HOME = null
> >>   [junit] environment property - FLASHPLAYER_DEBUGGER = null
> >
> > I will spend time today trying to get the build to work without
> > unittest.properties files, but I think it will still require setting
> > PLAYERGLOBAL_HOME, AIR_HOME, FLASHPLAYER_DEBUGGER and maybe
> > PLAYERGLOBAL_VERSION in the environment.  I have spent several hours
> > already trying to make sure folks don't have to specify relative paths to
> > other Apache Flex repos, but right now we don't have a good way to guess
> > where folks put the Adobe stuff.
> >
> > -Alex
>
>

Re: [FALCONJX][FLEXJS] XML handling (was Re: [FlexJS] Back port)

Posted by Harbs <ha...@gmail.com>.
Where do I need to set the unittest.properties file?

I’m happy to do so, but I think it would be great if we could at least get some instructions on everything needed to build from source.

Every time I come back to this, I have trouble. Maybe it’s just me, but it seems like it raises the bar needed to contribute.

On Feb 15, 2016, at 5:01 PM, Alex Harui <ah...@adobe.com> wrote:

> 
> 
> On 2/14/16, 11:52 PM, "Harbs" <ha...@gmail.com> wrote:
> 
>> Cleaning the repo seemed to have helped somewhat, but I still could not
>> compile, and I’m assuming because I need to build falcon:
>> Buildfile: 
>> /Users/harbs/Documents/ApacheFlex/flex-asjs/frameworks/projects/XML/build.
>> xml
>> 
>> clean:
>> 
>> check-falcon-home:
>>    [echo] FALCON_HOME is
>> /Users/harbs/Documents/ApacheFlex/flex-falcon/compiler
>> 
>> check-falconjx-home:
>>    [echo] FALCONJX_HOME is
>> /Users/harbs/Documents/ApacheFlex/flex-falcon/compiler.jx
> 
> This implies you still have environment variables set somehow.  The
> defaults would use relative paths with ../ in them.
> Do you have an env.properties file or local.properties file?
> 
> 
>> 
>> unit.tests:
>>   [junit] unittest.properties not found
>>   [junit] environment property - FLEX_HOME =
>> /Users/harbs/Documents/ApacheFlex/flex-falcon/compiler/generated/dist/sdk
>>   [junit] environment property - PLAYERGLOBAL_HOME =
>> /Users/harbs/Documents/ApacheFlex/flex-falcon/compiler/generated/dist/sdk/
>> frameworks/libs/player
>>   [junit] environment property - PLAYERGLOBAL_VERSION = 11.1
>>   [junit] environment property - TLF_HOME = null
>>   [junit] environment property - AIR_HOME = null
>>   [junit] environment property - FLASHPLAYER_DEBUGGER = null
> 
> I will spend time today trying to get the build to work without
> unittest.properties files, but I think it will still require setting
> PLAYERGLOBAL_HOME, AIR_HOME, FLASHPLAYER_DEBUGGER and maybe
> PLAYERGLOBAL_VERSION in the environment.  I have spent several hours
> already trying to make sure folks don't have to specify relative paths to
> other Apache Flex repos, but right now we don't have a good way to guess
> where folks put the Adobe stuff.
> 
> -Alex


Re: [FALCONJX][FLEXJS] XML handling (was Re: [FlexJS] Back port)

Posted by Harbs <ha...@gmail.com>.
I would vote to have a single file which contains settings for all environment variables for all projects.

Can we adjust ALL the builds in all projects to look in ../properties/env.properties for environment variables? (i.e. in a folder on the same level as the repo)

It would require manually adding a properties file, but it would have the advantage of:
1) Being outside all the repos, so deleting and checking out the repos will have no effect on this.
2) A single file can be used for all projects
3) It will make it very clear what variables need to be set and where to set them.

On Feb 15, 2016, at 5:01 PM, Alex Harui <ah...@adobe.com> wrote:

> I will spend time today trying to get the build to work without
> unittest.properties files, but I think it will still require setting
> PLAYERGLOBAL_HOME, AIR_HOME, FLASHPLAYER_DEBUGGER and maybe
> PLAYERGLOBAL_VERSION in the environment.


Re: [FALCONJX][FLEXJS] XML handling (was Re: [FlexJS] Back port)

Posted by Alex Harui <ah...@adobe.com>.

On 2/14/16, 11:52 PM, "Harbs" <ha...@gmail.com> wrote:

>Cleaning the repo seemed to have helped somewhat, but I still could not
>compile, and I’m assuming because I need to build falcon:
>Buildfile: 
>/Users/harbs/Documents/ApacheFlex/flex-asjs/frameworks/projects/XML/build.
>xml
>
>clean:
>
>check-falcon-home:
>     [echo] FALCON_HOME is
>/Users/harbs/Documents/ApacheFlex/flex-falcon/compiler
>
>check-falconjx-home:
>     [echo] FALCONJX_HOME is
>/Users/harbs/Documents/ApacheFlex/flex-falcon/compiler.jx

This implies you still have environment variables set somehow.  The
defaults would use relative paths with ../ in them.
Do you have an env.properties file or local.properties file?


>
>unit.tests:
>    [junit] unittest.properties not found
>    [junit] environment property - FLEX_HOME =
>/Users/harbs/Documents/ApacheFlex/flex-falcon/compiler/generated/dist/sdk
>    [junit] environment property - PLAYERGLOBAL_HOME =
>/Users/harbs/Documents/ApacheFlex/flex-falcon/compiler/generated/dist/sdk/
>frameworks/libs/player
>    [junit] environment property - PLAYERGLOBAL_VERSION = 11.1
>    [junit] environment property - TLF_HOME = null
>    [junit] environment property - AIR_HOME = null
>    [junit] environment property - FLASHPLAYER_DEBUGGER = null

I will spend time today trying to get the build to work without
unittest.properties files, but I think it will still require setting
PLAYERGLOBAL_HOME, AIR_HOME, FLASHPLAYER_DEBUGGER and maybe
PLAYERGLOBAL_VERSION in the environment.  I have spent several hours
already trying to make sure folks don't have to specify relative paths to
other Apache Flex repos, but right now we don't have a good way to guess
where folks put the Adobe stuff.

-Alex



Re: [FALCONJX][FLEXJS] XML handling (was Re: [FlexJS] Back port)

Posted by Harbs <ha...@gmail.com>.
Cleaning the repo seemed to have helped somewhat, but I still could not compile, and I’m assuming because I need to build falcon:
Buildfile: /Users/harbs/Documents/ApacheFlex/flex-asjs/frameworks/projects/XML/build.xml

clean:

check-falcon-home:
     [echo] FALCON_HOME is /Users/harbs/Documents/ApacheFlex/flex-falcon/compiler

check-falconjx-home:
     [echo] FALCONJX_HOME is /Users/harbs/Documents/ApacheFlex/flex-falcon/compiler.jx
[available] DEPRECATED - <available> used to override an existing property.
[available]   Build file should not reuse the same property name for different values.

more-props:

compile-asjs:
     [echo] Cross-compiling XML-0.6.0.swc
     [echo] FALCONJX_HOME: /Users/harbs/Documents/ApacheFlex/flex-asjs/../flex-falcon/compiler.jx
     [java] /Users/harbs/Documents/ApacheFlex/flex-asjs/frameworks/projects/XML/src/main/resources/compile-asjs-config.xml:49
     [java] unable to open '/Users/harbs/Documents/ApacheFlex/flex-asjs/frameworks/externs/Core.swc'.
     [java] /Users/harbs/Documents/ApacheFlex/flex-asjs/frameworks/projects/XML/src/main/resources/compile-asjs-config.xml (line: 49)
     [java]         </library-path>
     [java] 
     [java] 
     [java] command line
     [java] unable to open '/Users/harbs/Documents/ApacheFlex/flex-falcon/externs/js/out/bin/js.swc'.
     [java] 
     [java] 
     [java] command line
     [java] unable to open '/Users/harbs/Documents/ApacheFlex/flex-falcon/externs/GCL/out/bin/GCL.swc'.
     [java] 
     [java] 
     [java] Java Result: 5

compile-extern-swc:
     [echo] Compiling target/externs/XML-0.6.0.swc
     [echo] FLEX_HOME: /Users/harbs/Documents/ApacheFlex/flex-asjs
     [echo] FALCON_HOME: /Users/harbs/Documents/ApacheFlex/flex-asjs/../flex-falcon/compiler/generated/dist/sdk
    [compc] Loading configuration: /Users/harbs/Documents/ApacheFlex/flex-asjs/frameworks/projects/XML/src/main/resources/compile-asjs-config.xml
    [compc] 
    [compc] /Users/harbs/Documents/ApacheFlex/flex-asjs/frameworks/projects/XML/src/main/resources/compile-asjs-config.xml:49
    [compc] Error: unable to open '/Users/harbs/Documents/ApacheFlex/flex-asjs/frameworks/externs/Core.swc'.
    [compc] /Users/harbs/Documents/ApacheFlex/flex-asjs/frameworks/projects/XML/src/main/resources/compile-asjs-config.xml (line: 49)
    [compc]         </library-path>
    [compc] 
    [compc] 
    [compc] command line
    [compc] Error: unable to open '/Users/harbs/Documents/ApacheFlex/flex-falcon/externs/js/out/bin/js.swc'.
    [compc] 
    [compc] 
    [compc] command line
    [compc] Error: unable to open '/Users/harbs/Documents/ApacheFlex/flex-falcon/externs/GCL/out/bin/GCL.swc'.
    [compc] 
    [compc] 

I tried to do that, and I get the following error (I removed my env.properties file):

Harbss-MacBook-Pro:flex-falcon harbs$ ant
Buildfile: /Users/harbs/Documents/ApacheFlex/flex-falcon/build.xml

sdk:

download:

prepare:
     [echo] Making lib directory /Users/harbs/Documents/ApacheFlex/flex-falcon/compiler/lib

all:

check-dependency:

download-dependency:

check-dependency:

download-dependency:
     [copy] Warning: /Users/harbs/Documents/ApacheFlex/flex-falcon/compiler/in/temp/commons-cli-1.2 does not exist.

check-dependency:

download-dependency:
     [copy] Warning: /Users/harbs/Documents/ApacheFlex/flex-falcon/compiler/in/temp/commons-io-2.4 does not exist.

check-dependency:

download-dependency:

check-dependency:

download-dependency:
     [copy] Warning: /Users/harbs/Documents/ApacheFlex/flex-falcon/compiler/in/temp does not exist.

check-dependency:

download-dependency:
     [copy] Warning: /Users/harbs/Documents/ApacheFlex/flex-falcon/compiler/in/temp/jflex-1.6.0 does not exist.

check-dependency:

download-dependency:

check-dependency:

download-dependency:

main:

setup:

set.raw.as.tokenizer.uptodate:

raw.as.tokenizer:

set.raw.asdoc.tokenizer.uptodate:

raw.asdoc.tokenizer:

set.raw.mxml.tokenizer.uptodate:

raw.mxml.tokenizer:

jflex:

annotate.class:

set.as.parser.uptodate:

as.parser:

set.metadata.parser.uptodate:

metadata.parser:

set.css.lexer.and.parser.uptodate:

css.lexer.and.parser:

set.css.tree.uptodate:

css.tree:

antlr:

node.adapter:

unknown.tree.pattern.input.output:

set.unknown.tree.handler.patterns.uptodate:

unknown.tree.handler.patterns:

set.cmc.emitter.uptodate:

cmc.emitter:

set.css.emitter.uptodate:

css.emitter:

jburg:

eclipse:

src.depend:

compile:

problem.localizer:

set.messages.en.uptodate:

localization:

version-info:

set.compiler.jar.uptodate:

compiler.jar:

set.falcon.asc.jar.uptodate:

falcon.asc.jar:

set.falcon.mxmlc.jar.uptodate:

falcon.mxmlc.jar:

set.falcon.compc.jar.uptodate:

falcon.compc.jar:

set.falcon.optimizer.jar.uptodate:

falcon.optimizer.jar:

set.falcon.swfdump.jar.uptodate:

falcon.swfdump.jar:

set.falcon.flextasks.jar.uptodate:

falcon.flextasks.jar:

jar:

dist-dev:

sdk:

javadoc:

tests:

download:

prepare:

junit-jar-check:

junit-jar:

main:

compile.unit.tests:
   [delete] Deleting directory /Users/harbs/Documents/ApacheFlex/flex-falcon/compiler.tests/classes
    [mkdir] Created dir: /Users/harbs/Documents/ApacheFlex/flex-falcon/compiler.tests/classes
    [javac] Compiling 67 source files to /Users/harbs/Documents/ApacheFlex/flex-falcon/compiler.tests/classes

unit.tests:
    [junit] unittest.properties not found
    [junit] environment property - FLEX_HOME = /Users/harbs/Documents/ApacheFlex/flex-falcon/compiler/generated/dist/sdk
    [junit] environment property - PLAYERGLOBAL_HOME = /Users/harbs/Documents/ApacheFlex/flex-falcon/compiler/generated/dist/sdk/frameworks/libs/player
    [junit] environment property - PLAYERGLOBAL_VERSION = 11.1
    [junit] environment property - TLF_HOME = null
    [junit] environment property - AIR_HOME = null
    [junit] environment property - FLASHPLAYER_DEBUGGER = null
    [junit] Running org.apache.flex.compiler.internal.css.CSSArrayPropertyValueTests
    [junit] /Users/harbs/Documents/ApacheFlex/flex-falcon/compiler.tests/temp/CSSArrayPropertyValueTests1302202013659801041.mxml(0): This tag could not be resolved to an ActionScript class. It will be ignored.
    [junit] /Users/harbs/Documents/ApacheFlex/flex-falcon/compiler.tests/temp/CSSArrayPropertyValueTests6113005395456480931.mxml(0): This tag could not be resolved to an ActionScript class. It will be ignored.
    [junit] Tests run: 2, Failures: 2, Errors: 0, Skipped: 0, Time elapsed: 0.694 sec

BUILD FAILED
/Users/harbs/Documents/ApacheFlex/flex-falcon/build.xml:82: The following error occurred while executing this line:
/Users/harbs/Documents/ApacheFlex/flex-falcon/compiler.tests/build.xml:103: Tests failed

On Feb 15, 2016, at 8:47 AM, Harbs <ha...@gmail.com> wrote:

> OK. I’ll try to clean my repos and try again.
> 
> On Feb 15, 2016, at 8:30 AM, Alex Harui <ah...@adobe.com> wrote:
> 
>> 
>> 
>> On 2/14/16, 7:51 AM, "Harbs" <ha...@gmail.com> wrote:
>> 
>>> The main build.xml is not working either. I can’t seem to get anything to
>>> build.
>>> 
>>> I just checked out the latest source from all repos.
>>> 
>>> When I try to build falcon, I get an error in junit. It cannot seem to
>>> find TLF_HOME, AIR_HOME or FLASHPLAYER_DEBUGGER.
>> 
>> Please post console output somewhere.  In theory the default build should
>> not need TLF_HOME.
>> 
>>> 
>>> When trying to build flex-asjs, I get the error that it can’t get
>>> https://search.maven.org/remotecontent?filepath=/org/apache/flex/flex-tool
>>> -api/1.0.0/flex-tool-api-1.0.0.jar
>> 
>> This implies your flex-sdk is not in sync.  Change
>> d103170c3246e34dabea342ec6d70d32c53017a7 removed the slash before the
>> "org".
>> 
>> 
>>> 
>>> When trying to just build XML, I get this error: Could not load
>>> definitions from resource flexTasks.tasks. It could not be found.
>> 
>> I just synced the e4x branch, unset my FLEX_HOME, ASJS_HOME, FALCONJX_HOME
>> and FALCON_HOME environment variables and ran ant at the root of flex-asjs
>> and everything built.  It correctly defaulted to the appropriate folders
>> in ../flex-falcon.  If you have tried to set those variables, try not
>> setting them at all and let it choose for you.
>> 
>> I also just committed modifications of frameworks/projects/XML/build.xml
>> and got it to correctly pick up the right folders and attempt to build the
>> XML files.
>> 
>> In looking at the output in your earlier posts, it occurred to me that
>> maybe you have tried to convert your repo working copy to an
>> IDE-compatible folder.  The build.xml files don't currently support that.
>> I have updated the FB project files in the develop branch so they seem to
>> work together without having to mix the AIR SDK into the repo files.  The
>> files expect that you are using some sort of FlexJS sdk that you've
>> installed via the installer, but they only use the compiler in the SDK,
>> they don't use any of the SWCs, they only use the files in the repo.
>> 
>> HTH,
>> -Alex
>> 
> 


Re: [FALCONJX][FLEXJS] XML handling (was Re: [FlexJS] Back port)

Posted by Harbs <ha...@gmail.com>.
OK. I’ll try to clean my repos and try again.

On Feb 15, 2016, at 8:30 AM, Alex Harui <ah...@adobe.com> wrote:

> 
> 
> On 2/14/16, 7:51 AM, "Harbs" <ha...@gmail.com> wrote:
> 
>> The main build.xml is not working either. I can’t seem to get anything to
>> build.
>> 
>> I just checked out the latest source from all repos.
>> 
>> When I try to build falcon, I get an error in junit. It cannot seem to
>> find TLF_HOME, AIR_HOME or FLASHPLAYER_DEBUGGER.
> 
> Please post console output somewhere.  In theory the default build should
> not need TLF_HOME.
> 
>> 
>> When trying to build flex-asjs, I get the error that it can’t get
>> https://search.maven.org/remotecontent?filepath=/org/apache/flex/flex-tool
>> -api/1.0.0/flex-tool-api-1.0.0.jar
> 
> This implies your flex-sdk is not in sync.  Change
> d103170c3246e34dabea342ec6d70d32c53017a7 removed the slash before the
> "org".
> 
> 
>> 
>> When trying to just build XML, I get this error: Could not load
>> definitions from resource flexTasks.tasks. It could not be found.
> 
> I just synced the e4x branch, unset my FLEX_HOME, ASJS_HOME, FALCONJX_HOME
> and FALCON_HOME environment variables and ran ant at the root of flex-asjs
> and everything built.  It correctly defaulted to the appropriate folders
> in ../flex-falcon.  If you have tried to set those variables, try not
> setting them at all and let it choose for you.
> 
> I also just committed modifications of frameworks/projects/XML/build.xml
> and got it to correctly pick up the right folders and attempt to build the
> XML files.
> 
> In looking at the output in your earlier posts, it occurred to me that
> maybe you have tried to convert your repo working copy to an
> IDE-compatible folder.  The build.xml files don't currently support that.
> I have updated the FB project files in the develop branch so they seem to
> work together without having to mix the AIR SDK into the repo files.  The
> files expect that you are using some sort of FlexJS sdk that you've
> installed via the installer, but they only use the compiler in the SDK,
> they don't use any of the SWCs, they only use the files in the repo.
> 
> HTH,
> -Alex
> 


Re: [FALCONJX][FLEXJS] XML handling (was Re: [FlexJS] Back port)

Posted by Alex Harui <ah...@adobe.com>.

On 2/14/16, 7:51 AM, "Harbs" <ha...@gmail.com> wrote:

>The main build.xml is not working either. I can’t seem to get anything to
>build.
>
>I just checked out the latest source from all repos.
>
>When I try to build falcon, I get an error in junit. It cannot seem to
>find TLF_HOME, AIR_HOME or FLASHPLAYER_DEBUGGER.

Please post console output somewhere.  In theory the default build should
not need TLF_HOME.

>
>When trying to build flex-asjs, I get the error that it can’t get
>https://search.maven.org/remotecontent?filepath=/org/apache/flex/flex-tool
>-api/1.0.0/flex-tool-api-1.0.0.jar

This implies your flex-sdk is not in sync.  Change
d103170c3246e34dabea342ec6d70d32c53017a7 removed the slash before the
"org".


>
>When trying to just build XML, I get this error: Could not load
>definitions from resource flexTasks.tasks. It could not be found.

I just synced the e4x branch, unset my FLEX_HOME, ASJS_HOME, FALCONJX_HOME
and FALCON_HOME environment variables and ran ant at the root of flex-asjs
and everything built.  It correctly defaulted to the appropriate folders
in ../flex-falcon.  If you have tried to set those variables, try not
setting them at all and let it choose for you.

I also just committed modifications of frameworks/projects/XML/build.xml
and got it to correctly pick up the right folders and attempt to build the
XML files.

In looking at the output in your earlier posts, it occurred to me that
maybe you have tried to convert your repo working copy to an
IDE-compatible folder.  The build.xml files don't currently support that.
I have updated the FB project files in the develop branch so they seem to
work together without having to mix the AIR SDK into the repo files.  The
files expect that you are using some sort of FlexJS sdk that you've
installed via the installer, but they only use the compiler in the SDK,
they don't use any of the SWCs, they only use the files in the repo.

HTH,
-Alex


Re: [FALCONJX][FLEXJS] XML handling (was Re: [FlexJS] Back port)

Posted by Harbs <ha...@gmail.com>.
The main build.xml is not working either. I can’t seem to get anything to build.

I just checked out the latest source from all repos.

When I try to build falcon, I get an error in junit. It cannot seem to find TLF_HOME, AIR_HOME or FLASHPLAYER_DEBUGGER.

When trying to build flex-asjs, I get the error that it can’t get https://search.maven.org/remotecontent?filepath=/org/apache/flex/flex-tool-api/1.0.0/flex-tool-api-1.0.0.jar

When trying to just build XML, I get this error: Could not load definitions from resource flexTasks.tasks. It could not be found.

On Feb 14, 2016, at 5:19 PM, Alex Harui <ah...@adobe.com> wrote:

> Did you try my suggestions about picking up default FALCON/FALCONJX_HOME
> selection from the main build.xml?
> 
> I think the downloads.xml in flex-sdk is not up to date.  Maybe it didn't
> sync flex-sdk properly.
> 
> HTH,
> -Alex
> 
> On 2/14/16, 4:23 AM, "Harbs" <ha...@gmail.com> wrote:
> 
>> Thanks. The file location was indeed a problem.
>> 
>> I’m really suffering from not really understanding the whole process.
>> 
>> Running ant on flex-asjs results in the following error:
>> /Users/harbs/Documents/ApacheFlex/flex-asjs/build.xml:1552: The following
>> error occurred while executing this line:
>> /Users/harbs/Documents/ApacheFlex/flex-asjs/build.xml:1691: The following
>> error occurred while executing this line:
>> /Users/harbs/git/apache/flex/flex-sdk/build.xml:178: The following error
>> occurred while executing this line:
>> /Users/harbs/git/apache/flex/flex-sdk/modules/build.xml:64: The following
>> error occurred while executing this line:
>> /Users/harbs/git/apache/flex/flex-sdk/modules/downloads.xml:606: Can't
>> get 
>> https://search.maven.org/remotecontent?filepath=/org/apache/flex/flex-tool
>> -api/1.0.0/flex-tool-api-1.0.0.jar to
>> /Users/harbs/git/apache/flex/flex-sdk/in/flex-tool-api.jar
>> 
>> 
>> When I try just  building XML, I tried pointing the falcon paths to 2
>> separate places, and neither worked:
>> 
>> Harbss-MacBook-Pro:XML harbs$ ant
>> Buildfile: 
>> /Users/harbs/Documents/ApacheFlex/flex-asjs/frameworks/projects/XML/build.
>> xml
>> 
>> clean:
>> 
>> compile-asjs:
>>    [echo] properties:
>> /Users/harbs/Documents/ApacheFlex/flex-asjs/env.properties
>>    [echo] Cross-compiling XML-0.6.0.swc
>>    [echo] FALCONJX_HOME:
>> /Users/harbs/Documents/ApacheFlex/flex-falcon/compiler.jx
>>    [java] 
>> /Users/harbs/Documents/ApacheFlex/flex-asjs/frameworks/projects/XML/src/ma
>> in/resources/compile-asjs-config.xml:49
>>    [java] unable to open
>> '/Users/harbs/Documents/ApacheFlex/flex-asjs/frameworks/externs/Core.swc'.
>>    [java] 
>> /Users/harbs/Documents/ApacheFlex/flex-asjs/frameworks/projects/XML/src/ma
>> in/resources/compile-asjs-config.xml (line: 49)
>>    [java]         </library-path>
>>    [java] 
>>    [java] 
>>    [java] command line
>>    [java] unable to open
>> '/Users/harbs/Documents/ApacheFlex/flex-falcon/externs/js/out/bin/js.swc'.
>>    [java] 
>>    [java] 
>>    [java] command line
>>    [java] unable to open
>> '/Users/harbs/Documents/ApacheFlex/flex-falcon/externs/GCL/out/bin/GCL.swc
>> '.
>>    [java] 
>>    [java] 
>>    [java] Java Result: 5
>> 
>> compile-extern-swc:
>>    [echo] Compiling target/externs/XML-0.6.0.swc
>>    [echo] FLEX_HOME: /Users/harbs/Documents/ApacheFlex/flex-asjs
>>    [echo] FALCON_HOME:
>> /Users/harbs/Documents/ApacheFlex/flex-falcon/compiler
>> [taskdef] Could not load definitions from resource flexTasks.tasks. It
>> could not be found.
>> 
>> BUILD FAILED
>> /Users/harbs/Documents/ApacheFlex/flex-asjs/frameworks/projects/XML/build.
>> xml:151: Problem: failed to create task or type compc
>> Cause: The name is undefined.
>> Action: Check the spelling.
>> Action: Check that any custom tasks/types have been declared.
>> Action: Check that any <presetdef>/<macrodef> declarations have taken
>> place.
>> 
>> 
>> Total time: 0 seconds
>> Harbss-MacBook-Pro:XML harbs$ ant
>> Buildfile: 
>> /Users/harbs/Documents/ApacheFlex/flex-asjs/frameworks/projects/XML/build.
>> xml
>> 
>> clean:
>> 
>> compile-asjs:
>>    [echo] properties:
>> /Users/harbs/Documents/ApacheFlex/flex-asjs/env.properties
>>    [echo] Cross-compiling XML-0.6.0.swc
>>    [echo] FALCONJX_HOME:
>> /Users/harbs/Documents/ApacheFlex/ApproveFalcon/apache-flex-falconjx-0.5.0
>> -src/compiler.jx
>>    [java] 
>> /Users/harbs/Documents/ApacheFlex/flex-asjs/frameworks/projects/XML/src/ma
>> in/resources/compile-asjs-config.xml:49
>>    [java] unable to open
>> '/Users/harbs/Documents/ApacheFlex/flex-asjs/frameworks/externs/Core.swc'.
>>    [java] 
>> /Users/harbs/Documents/ApacheFlex/flex-asjs/frameworks/projects/XML/src/ma
>> in/resources/compile-asjs-config.xml (line: 49)
>>    [java]         </library-path>
>>    [java] 
>>    [java] 
>>    [java] Java Result: 5
>> 
>> compile-extern-swc:
>>    [echo] Compiling target/externs/XML-0.6.0.swc
>>    [echo] FLEX_HOME: /Users/harbs/Documents/ApacheFlex/flex-asjs
>>    [echo] FALCON_HOME:
>> /Users/harbs/Documents/ApacheFlex/ApproveFalcon/apache-flex-falconjx-0.5.0
>> -src/compiler
>> [taskdef] Could not load definitions from resource flexTasks.tasks. It
>> could not be found.
>> 
>> BUILD FAILED
>> /Users/harbs/Documents/ApacheFlex/flex-asjs/frameworks/projects/XML/build.
>> xml:151: Problem: failed to create task or type compc
>> Cause: The name is undefined.
>> Action: Check the spelling.
>> Action: Check that any custom tasks/types have been declared.
>> Action: Check that any <presetdef>/<macrodef> declarations have taken
>> place.
>> 
>> On Feb 12, 2016, at 5:12 PM, Josh Tynjala <jo...@gmail.com> wrote:
>> 
>>>> I’m not exactly sure what the variables are supposed to point to
>>> 
>>> Check the READme file at the root of the repository. Be sure to read
>>> through all of the numbered steps after the list of environment
>>> variables.
>>> The steps explain in more detail what paths you should be using. For
>>> instance, it says that FALCON_HOME should include
>>> compiler/generated/dist/sdk in the path.
>>> 
>>>> and I get the following errors:
>>> 
>>> Since it is echoing values like ${env.FALCONJX_HOME}, it doesn't seem
>>> to be
>>> finding your env.properties file. Did you save it in the root directory
>>> of
>>> the flex-asjs repository? Relative to your XML project, that would be
>>> ../../../env.properties.
>>> 
>>> I just checked out your branch, and I ran ant in the
>>> frameworks/projects/XML directory. It was able to find my env.properties
>>> file, so perhaps your file is in the wrong location.
>>> 
>>> - Josh
>>> 
>>> 
>>> 
>>> On Fri, Feb 12, 2016 at 2:03 AM, Harbs <ha...@gmail.com> wrote:
>>> 
>>>> I had already done pretty close to this (using outdated files, so I
>>>> just
>>>> updated it).
>>>> 
>>>> I’m running into environment variable issues again and I tried to set
>>>> up a
>>>> env.properties file to set them, but that’s not working. (I’m not
>>>> exactly
>>>> sure what the variables are supposed to point to)
>>>> 
>>>> Here’s the file I created:
>>>> 
>>>> 
>>>> env.AIR_HOME=/Users/harbs/Documents/ApacheFlex/frameworks/AIRSDK_Compile
>>>> r
>>>> 
>>>> env.FLASHPLAYER_DEBUGGER=/Users/harbs/Documents/ApacheFlex/frameworks/Fl
>>>> ash
>>>> Player Debugger.app/Contents/MacOS/Flash Player Debugger
>>>> env.FALCON_HOME=/Users/harbs/Documents/ApacheFlex/flex-falcon/compiler
>>>> 
>>>> env.FALCONJX_HOME=/Users/harbs/Documents/ApacheFlex/flex-falcon/compiler
>>>> .jx
>>>> 
>>>> and I get the following errors:
>>>> compile-asjs:
>>>>    [echo] Cross-compiling XML-0.6.0.swc
>>>>    [echo] FALCONJX_HOME: ${env.FALCONJX_HOME}
>>>>    [java] Error: Unable to access jarfile
>>>> 
>>>> /Users/harbs/Documents/ApacheFlex/flex-asjs/frameworks/projects/XML/${en
>>>> v.FALCONJX_HOME}/lib/compc.jar
>>>>    [java] Java Result: 1
>>>> 
>>>> compile-extern-swc:
>>>>    [echo] Compiling target/externs/XML-0.6.0.swc
>>>>    [echo] FLEX_HOME: /Users/harbs/Documents/ApacheFlex/flex-asjs
>>>>    [echo] FALCON_HOME: ${env.FALCON_HOME}
>>>> 
>>>> 
>>>> How do we simplify setting environment variables? What I’ve been doing
>>>> is
>>>> writing shell scripts for every custom build I do, but that’s
>>>> ridiculous,
>>>> and it creates a barrier for others wanting to get involved.
>>>> 
>>>> On Feb 11, 2016, at 5:59 PM, Alex Harui <ah...@adobe.com> wrote:
>>>> 
>>>>> IIRC, you are trying to get the build to work in a new XML folder?
>>>>> 
>>>>> In theory, you can copy any build.xml from, say Binding into the root
>>>>> of
>>>>> XML.  Open it and search for Binding and replace with XML.
>>>>> 
>>>>> Next, copy the src/main/resources folder from Binding.  Open
>>>>> compile-config.xml and search and replace Binding.
>>>>> 
>>>>> Open compile-asjs-config.xml and do the same.
>>>>> 
>>>>> If you don't have a src/main/flex/XMLClasses.as file, create one and
>>>>> list
>>>>> the files you want to compile.  If you don't want a particular class
>>>>> in
>>>>> the AS version of the SWC, put it in a COMPILE::AS3 block.
>>>>> 
>>>>> Open basic-manifest.xml and comment everything out.  This is the list
>>>>> of
>>>>> components that go in MXML, but I think you are emulating classes that
>>>> are
>>>>> already in the fx: namespace so you shouldn't need anything.
>>>>> 
>>>>> Then running "ant" from XML should "do the right thing".
>>>>> 
>>>>> To integrate into the main build, open frameworks/build.xml, search
>>>>> for
>>>>> Binding and clone the patterns you see.
>>>>> 
>>>>> HTH,
>>>>> -Alex
>>>>> 
>>>>> On 2/11/16, 1:25 AM, "Harbs" <ha...@gmail.com> wrote:
>>>>> 
>>>>>> OK. I merged and copied the new folder structure. Unfortunately I
>>>>>> have
>>>> no
>>>>>> idea how to set up the compilation. I just copied the folder
>>>>>> structure
>>>>>> like a monkey, but I have no idea how it’s supposed to work.
>>>>>> 
>>>>>> Can someone help me set up the scripts so it can actually compile
>>>>>> something? Once I understand how the compilation is supposed to
>>>>>> work, I
>>>>>> can continue with this.
>>>>>> 
>>>>>> Harbs
>>>>>> 
>>>>>> On Feb 11, 2016, at 10:56 AM, Harbs <ha...@gmail.com> wrote:
>>>>>> 
>>>>>>> OK. I’m up to #2. I know of a number of problems/holes in the
>>>>>>> implementation as it stands and there’s probably a lot of problems
>>>>>>> I’m
>>>>>>> not aware of, but I’m going to try to get to the point where this
>>>>>>> compiles and actually does something to make the problems more
>>>>>>> visible.
>>>>>>> 
>>>>>>> Maybe some other folks can even help at that point… ;-)
>>>>>>> 
>>>>>>> On Feb 8, 2016, at 11:00 AM, Harbs <ha...@gmail.com> wrote:
>>>>>>> 
>>>>>>>> So here’s my current plan:
>>>>>>>> 1. Finish up the methods (minus filtering) in the next day or two.
>>>>>>>> 2. Sync up XML with the current FlexJS folder structure and get
>>>>>>>> rid of
>>>>>>>> some junk (like all the JXON classes).
>>>>>>>> 3. Get this all to compile.
>>>>>>>> 4. Figure out the whole filtering issue.
>>>>>>>> 5. Create test cases.
>>>>>>> 
>>>>>> 
>>>>> 
>>>> 
>>>> 
>> 
> 


Re: [FALCONJX][FLEXJS] XML handling (was Re: [FlexJS] Back port)

Posted by Alex Harui <ah...@adobe.com>.
Did you try my suggestions about picking up default FALCON/FALCONJX_HOME
selection from the main build.xml?

I think the downloads.xml in flex-sdk is not up to date.  Maybe it didn't
sync flex-sdk properly.

HTH,
-Alex

On 2/14/16, 4:23 AM, "Harbs" <ha...@gmail.com> wrote:

>Thanks. The file location was indeed a problem.
>
>I’m really suffering from not really understanding the whole process.
>
>Running ant on flex-asjs results in the following error:
>/Users/harbs/Documents/ApacheFlex/flex-asjs/build.xml:1552: The following
>error occurred while executing this line:
>/Users/harbs/Documents/ApacheFlex/flex-asjs/build.xml:1691: The following
>error occurred while executing this line:
>/Users/harbs/git/apache/flex/flex-sdk/build.xml:178: The following error
>occurred while executing this line:
>/Users/harbs/git/apache/flex/flex-sdk/modules/build.xml:64: The following
>error occurred while executing this line:
>/Users/harbs/git/apache/flex/flex-sdk/modules/downloads.xml:606: Can't
>get 
>https://search.maven.org/remotecontent?filepath=/org/apache/flex/flex-tool
>-api/1.0.0/flex-tool-api-1.0.0.jar to
>/Users/harbs/git/apache/flex/flex-sdk/in/flex-tool-api.jar
>
>
>When I try just  building XML, I tried pointing the falcon paths to 2
>separate places, and neither worked:
>
>Harbss-MacBook-Pro:XML harbs$ ant
>Buildfile: 
>/Users/harbs/Documents/ApacheFlex/flex-asjs/frameworks/projects/XML/build.
>xml
>
>clean:
>
>compile-asjs:
>     [echo] properties:
>/Users/harbs/Documents/ApacheFlex/flex-asjs/env.properties
>     [echo] Cross-compiling XML-0.6.0.swc
>     [echo] FALCONJX_HOME:
>/Users/harbs/Documents/ApacheFlex/flex-falcon/compiler.jx
>     [java] 
>/Users/harbs/Documents/ApacheFlex/flex-asjs/frameworks/projects/XML/src/ma
>in/resources/compile-asjs-config.xml:49
>     [java] unable to open
>'/Users/harbs/Documents/ApacheFlex/flex-asjs/frameworks/externs/Core.swc'.
>     [java] 
>/Users/harbs/Documents/ApacheFlex/flex-asjs/frameworks/projects/XML/src/ma
>in/resources/compile-asjs-config.xml (line: 49)
>     [java]         </library-path>
>     [java] 
>     [java] 
>     [java] command line
>     [java] unable to open
>'/Users/harbs/Documents/ApacheFlex/flex-falcon/externs/js/out/bin/js.swc'.
>     [java] 
>     [java] 
>     [java] command line
>     [java] unable to open
>'/Users/harbs/Documents/ApacheFlex/flex-falcon/externs/GCL/out/bin/GCL.swc
>'.
>     [java] 
>     [java] 
>     [java] Java Result: 5
>
>compile-extern-swc:
>     [echo] Compiling target/externs/XML-0.6.0.swc
>     [echo] FLEX_HOME: /Users/harbs/Documents/ApacheFlex/flex-asjs
>     [echo] FALCON_HOME:
>/Users/harbs/Documents/ApacheFlex/flex-falcon/compiler
>  [taskdef] Could not load definitions from resource flexTasks.tasks. It
>could not be found.
>
>BUILD FAILED
>/Users/harbs/Documents/ApacheFlex/flex-asjs/frameworks/projects/XML/build.
>xml:151: Problem: failed to create task or type compc
>Cause: The name is undefined.
>Action: Check the spelling.
>Action: Check that any custom tasks/types have been declared.
>Action: Check that any <presetdef>/<macrodef> declarations have taken
>place.
>
>
>Total time: 0 seconds
>Harbss-MacBook-Pro:XML harbs$ ant
>Buildfile: 
>/Users/harbs/Documents/ApacheFlex/flex-asjs/frameworks/projects/XML/build.
>xml
>
>clean:
>
>compile-asjs:
>     [echo] properties:
>/Users/harbs/Documents/ApacheFlex/flex-asjs/env.properties
>     [echo] Cross-compiling XML-0.6.0.swc
>     [echo] FALCONJX_HOME:
>/Users/harbs/Documents/ApacheFlex/ApproveFalcon/apache-flex-falconjx-0.5.0
>-src/compiler.jx
>     [java] 
>/Users/harbs/Documents/ApacheFlex/flex-asjs/frameworks/projects/XML/src/ma
>in/resources/compile-asjs-config.xml:49
>     [java] unable to open
>'/Users/harbs/Documents/ApacheFlex/flex-asjs/frameworks/externs/Core.swc'.
>     [java] 
>/Users/harbs/Documents/ApacheFlex/flex-asjs/frameworks/projects/XML/src/ma
>in/resources/compile-asjs-config.xml (line: 49)
>     [java]         </library-path>
>     [java] 
>     [java] 
>     [java] Java Result: 5
>
>compile-extern-swc:
>     [echo] Compiling target/externs/XML-0.6.0.swc
>     [echo] FLEX_HOME: /Users/harbs/Documents/ApacheFlex/flex-asjs
>     [echo] FALCON_HOME:
>/Users/harbs/Documents/ApacheFlex/ApproveFalcon/apache-flex-falconjx-0.5.0
>-src/compiler
>  [taskdef] Could not load definitions from resource flexTasks.tasks. It
>could not be found.
>
>BUILD FAILED
>/Users/harbs/Documents/ApacheFlex/flex-asjs/frameworks/projects/XML/build.
>xml:151: Problem: failed to create task or type compc
>Cause: The name is undefined.
>Action: Check the spelling.
>Action: Check that any custom tasks/types have been declared.
>Action: Check that any <presetdef>/<macrodef> declarations have taken
>place.
>
>On Feb 12, 2016, at 5:12 PM, Josh Tynjala <jo...@gmail.com> wrote:
>
>>> I’m not exactly sure what the variables are supposed to point to
>> 
>> Check the READme file at the root of the repository. Be sure to read
>> through all of the numbered steps after the list of environment
>>variables.
>> The steps explain in more detail what paths you should be using. For
>> instance, it says that FALCON_HOME should include
>> compiler/generated/dist/sdk in the path.
>> 
>>> and I get the following errors:
>> 
>> Since it is echoing values like ${env.FALCONJX_HOME}, it doesn't seem
>>to be
>> finding your env.properties file. Did you save it in the root directory
>>of
>> the flex-asjs repository? Relative to your XML project, that would be
>> ../../../env.properties.
>> 
>> I just checked out your branch, and I ran ant in the
>> frameworks/projects/XML directory. It was able to find my env.properties
>> file, so perhaps your file is in the wrong location.
>> 
>> - Josh
>> 
>> 
>> 
>> On Fri, Feb 12, 2016 at 2:03 AM, Harbs <ha...@gmail.com> wrote:
>> 
>>> I had already done pretty close to this (using outdated files, so I
>>>just
>>> updated it).
>>> 
>>> I’m running into environment variable issues again and I tried to set
>>>up a
>>> env.properties file to set them, but that’s not working. (I’m not
>>>exactly
>>> sure what the variables are supposed to point to)
>>> 
>>> Here’s the file I created:
>>> 
>>> 
>>>env.AIR_HOME=/Users/harbs/Documents/ApacheFlex/frameworks/AIRSDK_Compile
>>>r
>>> 
>>>env.FLASHPLAYER_DEBUGGER=/Users/harbs/Documents/ApacheFlex/frameworks/Fl
>>>ash
>>> Player Debugger.app/Contents/MacOS/Flash Player Debugger
>>> env.FALCON_HOME=/Users/harbs/Documents/ApacheFlex/flex-falcon/compiler
>>> 
>>>env.FALCONJX_HOME=/Users/harbs/Documents/ApacheFlex/flex-falcon/compiler
>>>.jx
>>> 
>>> and I get the following errors:
>>> compile-asjs:
>>>     [echo] Cross-compiling XML-0.6.0.swc
>>>     [echo] FALCONJX_HOME: ${env.FALCONJX_HOME}
>>>     [java] Error: Unable to access jarfile
>>> 
>>>/Users/harbs/Documents/ApacheFlex/flex-asjs/frameworks/projects/XML/${en
>>>v.FALCONJX_HOME}/lib/compc.jar
>>>     [java] Java Result: 1
>>> 
>>> compile-extern-swc:
>>>     [echo] Compiling target/externs/XML-0.6.0.swc
>>>     [echo] FLEX_HOME: /Users/harbs/Documents/ApacheFlex/flex-asjs
>>>     [echo] FALCON_HOME: ${env.FALCON_HOME}
>>> 
>>> 
>>> How do we simplify setting environment variables? What I’ve been doing
>>>is
>>> writing shell scripts for every custom build I do, but that’s
>>>ridiculous,
>>> and it creates a barrier for others wanting to get involved.
>>> 
>>> On Feb 11, 2016, at 5:59 PM, Alex Harui <ah...@adobe.com> wrote:
>>> 
>>>> IIRC, you are trying to get the build to work in a new XML folder?
>>>> 
>>>> In theory, you can copy any build.xml from, say Binding into the root
>>>>of
>>>> XML.  Open it and search for Binding and replace with XML.
>>>> 
>>>> Next, copy the src/main/resources folder from Binding.  Open
>>>> compile-config.xml and search and replace Binding.
>>>> 
>>>> Open compile-asjs-config.xml and do the same.
>>>> 
>>>> If you don't have a src/main/flex/XMLClasses.as file, create one and
>>>>list
>>>> the files you want to compile.  If you don't want a particular class
>>>>in
>>>> the AS version of the SWC, put it in a COMPILE::AS3 block.
>>>> 
>>>> Open basic-manifest.xml and comment everything out.  This is the list
>>>>of
>>>> components that go in MXML, but I think you are emulating classes that
>>> are
>>>> already in the fx: namespace so you shouldn't need anything.
>>>> 
>>>> Then running "ant" from XML should "do the right thing".
>>>> 
>>>> To integrate into the main build, open frameworks/build.xml, search
>>>>for
>>>> Binding and clone the patterns you see.
>>>> 
>>>> HTH,
>>>> -Alex
>>>> 
>>>> On 2/11/16, 1:25 AM, "Harbs" <ha...@gmail.com> wrote:
>>>> 
>>>>> OK. I merged and copied the new folder structure. Unfortunately I
>>>>>have
>>> no
>>>>> idea how to set up the compilation. I just copied the folder
>>>>>structure
>>>>> like a monkey, but I have no idea how it’s supposed to work.
>>>>> 
>>>>> Can someone help me set up the scripts so it can actually compile
>>>>> something? Once I understand how the compilation is supposed to
>>>>>work, I
>>>>> can continue with this.
>>>>> 
>>>>> Harbs
>>>>> 
>>>>> On Feb 11, 2016, at 10:56 AM, Harbs <ha...@gmail.com> wrote:
>>>>> 
>>>>>> OK. I’m up to #2. I know of a number of problems/holes in the
>>>>>> implementation as it stands and there’s probably a lot of problems
>>>>>>I’m
>>>>>> not aware of, but I’m going to try to get to the point where this
>>>>>> compiles and actually does something to make the problems more
>>>>>>visible.
>>>>>> 
>>>>>> Maybe some other folks can even help at that point… ;-)
>>>>>> 
>>>>>> On Feb 8, 2016, at 11:00 AM, Harbs <ha...@gmail.com> wrote:
>>>>>> 
>>>>>>> So here’s my current plan:
>>>>>>> 1. Finish up the methods (minus filtering) in the next day or two.
>>>>>>> 2. Sync up XML with the current FlexJS folder structure and get
>>>>>>>rid of
>>>>>>> some junk (like all the JXON classes).
>>>>>>> 3. Get this all to compile.
>>>>>>> 4. Figure out the whole filtering issue.
>>>>>>> 5. Create test cases.
>>>>>> 
>>>>> 
>>>> 
>>> 
>>> 
>


Re: [FALCONJX][FLEXJS] XML handling (was Re: [FlexJS] Back port)

Posted by Harbs <ha...@gmail.com>.
Thanks. The file location was indeed a problem.

I’m really suffering from not really understanding the whole process.

Running ant on flex-asjs results in the following error:
/Users/harbs/Documents/ApacheFlex/flex-asjs/build.xml:1552: The following error occurred while executing this line:
/Users/harbs/Documents/ApacheFlex/flex-asjs/build.xml:1691: The following error occurred while executing this line:
/Users/harbs/git/apache/flex/flex-sdk/build.xml:178: The following error occurred while executing this line:
/Users/harbs/git/apache/flex/flex-sdk/modules/build.xml:64: The following error occurred while executing this line:
/Users/harbs/git/apache/flex/flex-sdk/modules/downloads.xml:606: Can't get https://search.maven.org/remotecontent?filepath=/org/apache/flex/flex-tool-api/1.0.0/flex-tool-api-1.0.0.jar to /Users/harbs/git/apache/flex/flex-sdk/in/flex-tool-api.jar


When I try just  building XML, I tried pointing the falcon paths to 2 separate places, and neither worked:

Harbss-MacBook-Pro:XML harbs$ ant
Buildfile: /Users/harbs/Documents/ApacheFlex/flex-asjs/frameworks/projects/XML/build.xml

clean:

compile-asjs:
     [echo] properties: /Users/harbs/Documents/ApacheFlex/flex-asjs/env.properties
     [echo] Cross-compiling XML-0.6.0.swc
     [echo] FALCONJX_HOME: /Users/harbs/Documents/ApacheFlex/flex-falcon/compiler.jx
     [java] /Users/harbs/Documents/ApacheFlex/flex-asjs/frameworks/projects/XML/src/main/resources/compile-asjs-config.xml:49
     [java] unable to open '/Users/harbs/Documents/ApacheFlex/flex-asjs/frameworks/externs/Core.swc'.
     [java] /Users/harbs/Documents/ApacheFlex/flex-asjs/frameworks/projects/XML/src/main/resources/compile-asjs-config.xml (line: 49)
     [java]         </library-path>
     [java] 
     [java] 
     [java] command line
     [java] unable to open '/Users/harbs/Documents/ApacheFlex/flex-falcon/externs/js/out/bin/js.swc'.
     [java] 
     [java] 
     [java] command line
     [java] unable to open '/Users/harbs/Documents/ApacheFlex/flex-falcon/externs/GCL/out/bin/GCL.swc'.
     [java] 
     [java] 
     [java] Java Result: 5

compile-extern-swc:
     [echo] Compiling target/externs/XML-0.6.0.swc
     [echo] FLEX_HOME: /Users/harbs/Documents/ApacheFlex/flex-asjs
     [echo] FALCON_HOME: /Users/harbs/Documents/ApacheFlex/flex-falcon/compiler
  [taskdef] Could not load definitions from resource flexTasks.tasks. It could not be found.

BUILD FAILED
/Users/harbs/Documents/ApacheFlex/flex-asjs/frameworks/projects/XML/build.xml:151: Problem: failed to create task or type compc
Cause: The name is undefined.
Action: Check the spelling.
Action: Check that any custom tasks/types have been declared.
Action: Check that any <presetdef>/<macrodef> declarations have taken place.


Total time: 0 seconds
Harbss-MacBook-Pro:XML harbs$ ant
Buildfile: /Users/harbs/Documents/ApacheFlex/flex-asjs/frameworks/projects/XML/build.xml

clean:

compile-asjs:
     [echo] properties: /Users/harbs/Documents/ApacheFlex/flex-asjs/env.properties
     [echo] Cross-compiling XML-0.6.0.swc
     [echo] FALCONJX_HOME: /Users/harbs/Documents/ApacheFlex/ApproveFalcon/apache-flex-falconjx-0.5.0-src/compiler.jx
     [java] /Users/harbs/Documents/ApacheFlex/flex-asjs/frameworks/projects/XML/src/main/resources/compile-asjs-config.xml:49
     [java] unable to open '/Users/harbs/Documents/ApacheFlex/flex-asjs/frameworks/externs/Core.swc'.
     [java] /Users/harbs/Documents/ApacheFlex/flex-asjs/frameworks/projects/XML/src/main/resources/compile-asjs-config.xml (line: 49)
     [java]         </library-path>
     [java] 
     [java] 
     [java] Java Result: 5

compile-extern-swc:
     [echo] Compiling target/externs/XML-0.6.0.swc
     [echo] FLEX_HOME: /Users/harbs/Documents/ApacheFlex/flex-asjs
     [echo] FALCON_HOME: /Users/harbs/Documents/ApacheFlex/ApproveFalcon/apache-flex-falconjx-0.5.0-src/compiler
  [taskdef] Could not load definitions from resource flexTasks.tasks. It could not be found.

BUILD FAILED
/Users/harbs/Documents/ApacheFlex/flex-asjs/frameworks/projects/XML/build.xml:151: Problem: failed to create task or type compc
Cause: The name is undefined.
Action: Check the spelling.
Action: Check that any custom tasks/types have been declared.
Action: Check that any <presetdef>/<macrodef> declarations have taken place.

On Feb 12, 2016, at 5:12 PM, Josh Tynjala <jo...@gmail.com> wrote:

>> I’m not exactly sure what the variables are supposed to point to
> 
> Check the READme file at the root of the repository. Be sure to read
> through all of the numbered steps after the list of environment variables.
> The steps explain in more detail what paths you should be using. For
> instance, it says that FALCON_HOME should include
> compiler/generated/dist/sdk in the path.
> 
>> and I get the following errors:
> 
> Since it is echoing values like ${env.FALCONJX_HOME}, it doesn't seem to be
> finding your env.properties file. Did you save it in the root directory of
> the flex-asjs repository? Relative to your XML project, that would be
> ../../../env.properties.
> 
> I just checked out your branch, and I ran ant in the
> frameworks/projects/XML directory. It was able to find my env.properties
> file, so perhaps your file is in the wrong location.
> 
> - Josh
> 
> 
> 
> On Fri, Feb 12, 2016 at 2:03 AM, Harbs <ha...@gmail.com> wrote:
> 
>> I had already done pretty close to this (using outdated files, so I just
>> updated it).
>> 
>> I’m running into environment variable issues again and I tried to set up a
>> env.properties file to set them, but that’s not working. (I’m not exactly
>> sure what the variables are supposed to point to)
>> 
>> Here’s the file I created:
>> 
>> env.AIR_HOME=/Users/harbs/Documents/ApacheFlex/frameworks/AIRSDK_Compiler
>> env.FLASHPLAYER_DEBUGGER=/Users/harbs/Documents/ApacheFlex/frameworks/Flash
>> Player Debugger.app/Contents/MacOS/Flash Player Debugger
>> env.FALCON_HOME=/Users/harbs/Documents/ApacheFlex/flex-falcon/compiler
>> env.FALCONJX_HOME=/Users/harbs/Documents/ApacheFlex/flex-falcon/compiler.jx
>> 
>> and I get the following errors:
>> compile-asjs:
>>     [echo] Cross-compiling XML-0.6.0.swc
>>     [echo] FALCONJX_HOME: ${env.FALCONJX_HOME}
>>     [java] Error: Unable to access jarfile
>> /Users/harbs/Documents/ApacheFlex/flex-asjs/frameworks/projects/XML/${env.FALCONJX_HOME}/lib/compc.jar
>>     [java] Java Result: 1
>> 
>> compile-extern-swc:
>>     [echo] Compiling target/externs/XML-0.6.0.swc
>>     [echo] FLEX_HOME: /Users/harbs/Documents/ApacheFlex/flex-asjs
>>     [echo] FALCON_HOME: ${env.FALCON_HOME}
>> 
>> 
>> How do we simplify setting environment variables? What I’ve been doing is
>> writing shell scripts for every custom build I do, but that’s ridiculous,
>> and it creates a barrier for others wanting to get involved.
>> 
>> On Feb 11, 2016, at 5:59 PM, Alex Harui <ah...@adobe.com> wrote:
>> 
>>> IIRC, you are trying to get the build to work in a new XML folder?
>>> 
>>> In theory, you can copy any build.xml from, say Binding into the root of
>>> XML.  Open it and search for Binding and replace with XML.
>>> 
>>> Next, copy the src/main/resources folder from Binding.  Open
>>> compile-config.xml and search and replace Binding.
>>> 
>>> Open compile-asjs-config.xml and do the same.
>>> 
>>> If you don't have a src/main/flex/XMLClasses.as file, create one and list
>>> the files you want to compile.  If you don't want a particular class in
>>> the AS version of the SWC, put it in a COMPILE::AS3 block.
>>> 
>>> Open basic-manifest.xml and comment everything out.  This is the list of
>>> components that go in MXML, but I think you are emulating classes that
>> are
>>> already in the fx: namespace so you shouldn't need anything.
>>> 
>>> Then running "ant" from XML should "do the right thing".
>>> 
>>> To integrate into the main build, open frameworks/build.xml, search for
>>> Binding and clone the patterns you see.
>>> 
>>> HTH,
>>> -Alex
>>> 
>>> On 2/11/16, 1:25 AM, "Harbs" <ha...@gmail.com> wrote:
>>> 
>>>> OK. I merged and copied the new folder structure. Unfortunately I have
>> no
>>>> idea how to set up the compilation. I just copied the folder structure
>>>> like a monkey, but I have no idea how it’s supposed to work.
>>>> 
>>>> Can someone help me set up the scripts so it can actually compile
>>>> something? Once I understand how the compilation is supposed to work, I
>>>> can continue with this.
>>>> 
>>>> Harbs
>>>> 
>>>> On Feb 11, 2016, at 10:56 AM, Harbs <ha...@gmail.com> wrote:
>>>> 
>>>>> OK. I’m up to #2. I know of a number of problems/holes in the
>>>>> implementation as it stands and there’s probably a lot of problems I’m
>>>>> not aware of, but I’m going to try to get to the point where this
>>>>> compiles and actually does something to make the problems more visible.
>>>>> 
>>>>> Maybe some other folks can even help at that point… ;-)
>>>>> 
>>>>> On Feb 8, 2016, at 11:00 AM, Harbs <ha...@gmail.com> wrote:
>>>>> 
>>>>>> So here’s my current plan:
>>>>>> 1. Finish up the methods (minus filtering) in the next day or two.
>>>>>> 2. Sync up XML with the current FlexJS folder structure and get rid of
>>>>>> some junk (like all the JXON classes).
>>>>>> 3. Get this all to compile.
>>>>>> 4. Figure out the whole filtering issue.
>>>>>> 5. Create test cases.
>>>>> 
>>>> 
>>> 
>> 
>> 


Re: [FALCONJX][FLEXJS] XML handling (was Re: [FlexJS] Back port)

Posted by Josh Tynjala <jo...@gmail.com>.
> I’m not exactly sure what the variables are supposed to point to

Check the READme file at the root of the repository. Be sure to read
through all of the numbered steps after the list of environment variables.
The steps explain in more detail what paths you should be using. For
instance, it says that FALCON_HOME should include
compiler/generated/dist/sdk in the path.

> and I get the following errors:

Since it is echoing values like ${env.FALCONJX_HOME}, it doesn't seem to be
finding your env.properties file. Did you save it in the root directory of
the flex-asjs repository? Relative to your XML project, that would be
../../../env.properties.

I just checked out your branch, and I ran ant in the
frameworks/projects/XML directory. It was able to find my env.properties
file, so perhaps your file is in the wrong location.

- Josh



On Fri, Feb 12, 2016 at 2:03 AM, Harbs <ha...@gmail.com> wrote:

> I had already done pretty close to this (using outdated files, so I just
> updated it).
>
> I’m running into environment variable issues again and I tried to set up a
> env.properties file to set them, but that’s not working. (I’m not exactly
> sure what the variables are supposed to point to)
>
> Here’s the file I created:
>
> env.AIR_HOME=/Users/harbs/Documents/ApacheFlex/frameworks/AIRSDK_Compiler
> env.FLASHPLAYER_DEBUGGER=/Users/harbs/Documents/ApacheFlex/frameworks/Flash
> Player Debugger.app/Contents/MacOS/Flash Player Debugger
> env.FALCON_HOME=/Users/harbs/Documents/ApacheFlex/flex-falcon/compiler
> env.FALCONJX_HOME=/Users/harbs/Documents/ApacheFlex/flex-falcon/compiler.jx
>
> and I get the following errors:
> compile-asjs:
>      [echo] Cross-compiling XML-0.6.0.swc
>      [echo] FALCONJX_HOME: ${env.FALCONJX_HOME}
>      [java] Error: Unable to access jarfile
> /Users/harbs/Documents/ApacheFlex/flex-asjs/frameworks/projects/XML/${env.FALCONJX_HOME}/lib/compc.jar
>      [java] Java Result: 1
>
> compile-extern-swc:
>      [echo] Compiling target/externs/XML-0.6.0.swc
>      [echo] FLEX_HOME: /Users/harbs/Documents/ApacheFlex/flex-asjs
>      [echo] FALCON_HOME: ${env.FALCON_HOME}
>
>
> How do we simplify setting environment variables? What I’ve been doing is
> writing shell scripts for every custom build I do, but that’s ridiculous,
> and it creates a barrier for others wanting to get involved.
>
> On Feb 11, 2016, at 5:59 PM, Alex Harui <ah...@adobe.com> wrote:
>
> > IIRC, you are trying to get the build to work in a new XML folder?
> >
> > In theory, you can copy any build.xml from, say Binding into the root of
> > XML.  Open it and search for Binding and replace with XML.
> >
> > Next, copy the src/main/resources folder from Binding.  Open
> > compile-config.xml and search and replace Binding.
> >
> > Open compile-asjs-config.xml and do the same.
> >
> > If you don't have a src/main/flex/XMLClasses.as file, create one and list
> > the files you want to compile.  If you don't want a particular class in
> > the AS version of the SWC, put it in a COMPILE::AS3 block.
> >
> > Open basic-manifest.xml and comment everything out.  This is the list of
> > components that go in MXML, but I think you are emulating classes that
> are
> > already in the fx: namespace so you shouldn't need anything.
> >
> > Then running "ant" from XML should "do the right thing".
> >
> > To integrate into the main build, open frameworks/build.xml, search for
> > Binding and clone the patterns you see.
> >
> > HTH,
> > -Alex
> >
> > On 2/11/16, 1:25 AM, "Harbs" <ha...@gmail.com> wrote:
> >
> >> OK. I merged and copied the new folder structure. Unfortunately I have
> no
> >> idea how to set up the compilation. I just copied the folder structure
> >> like a monkey, but I have no idea how it’s supposed to work.
> >>
> >> Can someone help me set up the scripts so it can actually compile
> >> something? Once I understand how the compilation is supposed to work, I
> >> can continue with this.
> >>
> >> Harbs
> >>
> >> On Feb 11, 2016, at 10:56 AM, Harbs <ha...@gmail.com> wrote:
> >>
> >>> OK. I’m up to #2. I know of a number of problems/holes in the
> >>> implementation as it stands and there’s probably a lot of problems I’m
> >>> not aware of, but I’m going to try to get to the point where this
> >>> compiles and actually does something to make the problems more visible.
> >>>
> >>> Maybe some other folks can even help at that point… ;-)
> >>>
> >>> On Feb 8, 2016, at 11:00 AM, Harbs <ha...@gmail.com> wrote:
> >>>
> >>>> So here’s my current plan:
> >>>> 1. Finish up the methods (minus filtering) in the next day or two.
> >>>> 2. Sync up XML with the current FlexJS folder structure and get rid of
> >>>> some junk (like all the JXON classes).
> >>>> 3. Get this all to compile.
> >>>> 4. Figure out the whole filtering issue.
> >>>> 5. Create test cases.
> >>>
> >>
> >
>
>

Re: [FALCONJX][FLEXJS] XML handling (was Re: [FlexJS] Back port)

Posted by Alex Harui <ah...@adobe.com>.

On 2/12/16, 2:03 AM, "Harbs" <ha...@gmail.com> wrote:
>
>How do we simplify setting environment variables?

I think the problem is that some of the default setting logic in the main
flex-asjs/build.xml needs to be propagated to each individual project's.
It is hard to know what configurations folks will use.  Try copying the
check-falcon-home and check-falconjx-home targets and see if that makes
things better.

HTH,
-Alex


Re: [FALCONJX][FLEXJS] XML handling (was Re: [FlexJS] Back port)

Posted by Harbs <ha...@gmail.com>.
I had already done pretty close to this (using outdated files, so I just updated it).

I’m running into environment variable issues again and I tried to set up a env.properties file to set them, but that’s not working. (I’m not exactly sure what the variables are supposed to point to)

Here’s the file I created:

env.AIR_HOME=/Users/harbs/Documents/ApacheFlex/frameworks/AIRSDK_Compiler
env.FLASHPLAYER_DEBUGGER=/Users/harbs/Documents/ApacheFlex/frameworks/Flash Player Debugger.app/Contents/MacOS/Flash Player Debugger
env.FALCON_HOME=/Users/harbs/Documents/ApacheFlex/flex-falcon/compiler
env.FALCONJX_HOME=/Users/harbs/Documents/ApacheFlex/flex-falcon/compiler.jx

and I get the following errors:
compile-asjs:
     [echo] Cross-compiling XML-0.6.0.swc
     [echo] FALCONJX_HOME: ${env.FALCONJX_HOME}
     [java] Error: Unable to access jarfile /Users/harbs/Documents/ApacheFlex/flex-asjs/frameworks/projects/XML/${env.FALCONJX_HOME}/lib/compc.jar
     [java] Java Result: 1

compile-extern-swc:
     [echo] Compiling target/externs/XML-0.6.0.swc
     [echo] FLEX_HOME: /Users/harbs/Documents/ApacheFlex/flex-asjs
     [echo] FALCON_HOME: ${env.FALCON_HOME}


How do we simplify setting environment variables? What I’ve been doing is writing shell scripts for every custom build I do, but that’s ridiculous, and it creates a barrier for others wanting to get involved.

On Feb 11, 2016, at 5:59 PM, Alex Harui <ah...@adobe.com> wrote:

> IIRC, you are trying to get the build to work in a new XML folder?
> 
> In theory, you can copy any build.xml from, say Binding into the root of
> XML.  Open it and search for Binding and replace with XML.
> 
> Next, copy the src/main/resources folder from Binding.  Open
> compile-config.xml and search and replace Binding.
> 
> Open compile-asjs-config.xml and do the same.
> 
> If you don't have a src/main/flex/XMLClasses.as file, create one and list
> the files you want to compile.  If you don't want a particular class in
> the AS version of the SWC, put it in a COMPILE::AS3 block.
> 
> Open basic-manifest.xml and comment everything out.  This is the list of
> components that go in MXML, but I think you are emulating classes that are
> already in the fx: namespace so you shouldn't need anything.
> 
> Then running "ant" from XML should "do the right thing".
> 
> To integrate into the main build, open frameworks/build.xml, search for
> Binding and clone the patterns you see.
> 
> HTH,
> -Alex
> 
> On 2/11/16, 1:25 AM, "Harbs" <ha...@gmail.com> wrote:
> 
>> OK. I merged and copied the new folder structure. Unfortunately I have no
>> idea how to set up the compilation. I just copied the folder structure
>> like a monkey, but I have no idea how it’s supposed to work.
>> 
>> Can someone help me set up the scripts so it can actually compile
>> something? Once I understand how the compilation is supposed to work, I
>> can continue with this.
>> 
>> Harbs
>> 
>> On Feb 11, 2016, at 10:56 AM, Harbs <ha...@gmail.com> wrote:
>> 
>>> OK. I’m up to #2. I know of a number of problems/holes in the
>>> implementation as it stands and there’s probably a lot of problems I’m
>>> not aware of, but I’m going to try to get to the point where this
>>> compiles and actually does something to make the problems more visible.
>>> 
>>> Maybe some other folks can even help at that point… ;-)
>>> 
>>> On Feb 8, 2016, at 11:00 AM, Harbs <ha...@gmail.com> wrote:
>>> 
>>>> So here’s my current plan:
>>>> 1. Finish up the methods (minus filtering) in the next day or two.
>>>> 2. Sync up XML with the current FlexJS folder structure and get rid of
>>>> some junk (like all the JXON classes).
>>>> 3. Get this all to compile.
>>>> 4. Figure out the whole filtering issue.
>>>> 5. Create test cases.
>>> 
>> 
> 


Re: [FALCONJX][FLEXJS] XML handling (was Re: [FlexJS] Back port)

Posted by Alex Harui <ah...@adobe.com>.
IIRC, you are trying to get the build to work in a new XML folder?

In theory, you can copy any build.xml from, say Binding into the root of
XML.  Open it and search for Binding and replace with XML.

Next, copy the src/main/resources folder from Binding.  Open
compile-config.xml and search and replace Binding.

Open compile-asjs-config.xml and do the same.

If you don't have a src/main/flex/XMLClasses.as file, create one and list
the files you want to compile.  If you don't want a particular class in
the AS version of the SWC, put it in a COMPILE::AS3 block.

Open basic-manifest.xml and comment everything out.  This is the list of
components that go in MXML, but I think you are emulating classes that are
already in the fx: namespace so you shouldn't need anything.

Then running "ant" from XML should "do the right thing".

To integrate into the main build, open frameworks/build.xml, search for
Binding and clone the patterns you see.

HTH,
-Alex

On 2/11/16, 1:25 AM, "Harbs" <ha...@gmail.com> wrote:

>OK. I merged and copied the new folder structure. Unfortunately I have no
>idea how to set up the compilation. I just copied the folder structure
>like a monkey, but I have no idea how it’s supposed to work.
>
>Can someone help me set up the scripts so it can actually compile
>something? Once I understand how the compilation is supposed to work, I
>can continue with this.
>
>Harbs
>
>On Feb 11, 2016, at 10:56 AM, Harbs <ha...@gmail.com> wrote:
>
>> OK. I’m up to #2. I know of a number of problems/holes in the
>>implementation as it stands and there’s probably a lot of problems I’m
>>not aware of, but I’m going to try to get to the point where this
>>compiles and actually does something to make the problems more visible.
>> 
>> Maybe some other folks can even help at that point… ;-)
>> 
>> On Feb 8, 2016, at 11:00 AM, Harbs <ha...@gmail.com> wrote:
>> 
>>> So here’s my current plan:
>>> 1. Finish up the methods (minus filtering) in the next day or two.
>>> 2. Sync up XML with the current FlexJS folder structure and get rid of
>>>some junk (like all the JXON classes).
>>> 3. Get this all to compile.
>>> 4. Figure out the whole filtering issue.
>>> 5. Create test cases.
>> 
>


Re: [FALCONJX][FLEXJS] XML handling (was Re: [FlexJS] Back port)

Posted by Harbs <ha...@gmail.com>.
OK. I merged and copied the new folder structure. Unfortunately I have no idea how to set up the compilation. I just copied the folder structure like a monkey, but I have no idea how it’s supposed to work.

Can someone help me set up the scripts so it can actually compile something? Once I understand how the compilation is supposed to work, I can continue with this.

Harbs

On Feb 11, 2016, at 10:56 AM, Harbs <ha...@gmail.com> wrote:

> OK. I’m up to #2. I know of a number of problems/holes in the implementation as it stands and there’s probably a lot of problems I’m not aware of, but I’m going to try to get to the point where this compiles and actually does something to make the problems more visible.
> 
> Maybe some other folks can even help at that point… ;-)
> 
> On Feb 8, 2016, at 11:00 AM, Harbs <ha...@gmail.com> wrote:
> 
>> So here’s my current plan:
>> 1. Finish up the methods (minus filtering) in the next day or two.
>> 2. Sync up XML with the current FlexJS folder structure and get rid of some junk (like all the JXON classes).
>> 3. Get this all to compile.
>> 4. Figure out the whole filtering issue.
>> 5. Create test cases.
> 


Re: [FALCONJX][FLEXJS] XML handling (was Re: [FlexJS] Back port)

Posted by Harbs <ha...@gmail.com>.
OK. I’m up to #2. I know of a number of problems/holes in the implementation as it stands and there’s probably a lot of problems I’m not aware of, but I’m going to try to get to the point where this compiles and actually does something to make the problems more visible.

Maybe some other folks can even help at that point… ;-)

On Feb 8, 2016, at 11:00 AM, Harbs <ha...@gmail.com> wrote:

> So here’s my current plan:
> 1. Finish up the methods (minus filtering) in the next day or two.
> 2. Sync up XML with the current FlexJS folder structure and get rid of some junk (like all the JXON classes).
> 3. Get this all to compile.
> 4. Figure out the whole filtering issue.
> 5. Create test cases.


Re: [FALCONJX][FLEXJS] XML handling (was Re: [FlexJS] Back port)

Posted by Alex Harui <ah...@adobe.com>.

On 2/9/16, 12:55 PM, "Harbs" <ha...@gmail.com> wrote:

>> Are you
>> implementing XMLList as an Array or dynamic class with numeric property
>> names?
>
>I am using Object.defineProperty to assign the numeric property names.
>There’s always length+1 numeric properties assigned.
>
>I was planning on adding a “0" property to XML as well.

OK.  If that becomes painful, we could try to call a get() method instead.

>
>> I don't think this is the same.  The spec says resolveValue is added so
>>it
>> is functionality unique to XML and XMLList handling.  valueOf is used by
>> the runtime in other places.  It looks like resolveValue is only used
>>in a
>> few specific cases.  It might have to be completely handled in the AS
>> implementation.  I don't know if the compiler needs to do anything.  It
>> looks like if you have some XML like:
>> 
>>    var xml:XML = <node><child /></node>
>> 
>> Then do:
>> 
>>    var myChild:XMLList = xml.myChild;
>> 
>> then myChild will be assigned an empty XMLList since there is no myChild
>> tag in xml.  But amazingly, if you then do:
>> 
>>    myChild[0] = foo;
>> 
>> The implementation is supposed to use resolveValue to add a myChild
>> property to the xml so the net is:
>> 
>>   <node><child /><myChild>foo</myChild></node>
>
>Right. Every XMLList returned by public methods of XML has a targetObject
>object which refers to “this” and when the XMLList is altered, that’s
>supposed to be modified. (I have not done this bit yet.) I’m not sure why
>I need resolveValue for this.

Not sure either.  I think it gives the XMLList a chance to create the
property on the targetObject XML.

-Alex


Re: [FALCONJX][FLEXJS] XML handling (was Re: [FlexJS] Back port)

Posted by Harbs <ha...@gmail.com>.
> Are you
> implementing XMLList as an Array or dynamic class with numeric property
> names?

I am using Object.defineProperty to assign the numeric property names. There’s always length+1 numeric properties assigned.

I was planning on adding a “0" property to XML as well.

> I don't think this is the same.  The spec says resolveValue is added so it
> is functionality unique to XML and XMLList handling.  valueOf is used by
> the runtime in other places.  It looks like resolveValue is only used in a
> few specific cases.  It might have to be completely handled in the AS
> implementation.  I don't know if the compiler needs to do anything.  It
> looks like if you have some XML like:
> 
>    var xml:XML = <node><child /></node>
> 
> Then do:
> 
>    var myChild:XMLList = xml.myChild;
> 
> then myChild will be assigned an empty XMLList since there is no myChild
> tag in xml.  But amazingly, if you then do:
> 
>    myChild[0] = foo;
> 
> The implementation is supposed to use resolveValue to add a myChild
> property to the xml so the net is:
> 
>   <node><child /><myChild>foo</myChild></node>

Right. Every XMLList returned by public methods of XML has a targetObject object which refers to “this” and when the XMLList is altered, that’s supposed to be modified. (I have not done this bit yet.) I’m not sure why I need resolveValue for this.

On Feb 9, 2016, at 8:04 PM, Alex Harui <ah...@adobe.com> wrote:

> 
> 
> On 2/9/16, 1:39 AM, "Harbs" <ha...@gmail.com> wrote:
> 
>> Thanks for this. It’s really good to have someone else go through this
>> and give me a sanity check. Most of this is very much in line with what
>> I’ve already done.
>> 
>> Some comments:
>> 
>>> [[get]]
>> someXML[x] is only valid when x is 0 and that returns someXML and not a
>> child of someXML.
> 
> OK, I hadn't realized that.  That makes me wonder if we need to intercept
> all bracket calls on XML and XMLList and call child(int).  Are you
> implementing XMLList as an Array or dynamic class with numeric property
> names?  It might be better to implement a get() method and have the
> compiler call that with ints or property names.  Apparently we are
> supposed to blur the distinction between XML and XMLList.  I suppose
> another trick would be to create a "0" property on XML.
> 
>> 
>>> [[defaultValue]]
>> I’m not even sure what this means. I’ve implemented valueOf() and
>> toString(). I’m not clear on when [[defaultValue]] is used.
> 
> I think it is used in automatic type conversion.  See [1].  Maybe you can
> just implement valueOf() to call toString().
> 
>> 
>>> [[hasProperty]]
>> I implemented hasOwnProperty() I’m not sure we need to do anything else.
> 
> OK. Makes sense.
> 
>> 
>>> [[deepCopy]]
>> Yes. AFAICT, copy() is the the same as [[deepCopy]]
> 
> Agreed.
> 
>> 
>>> [[resolveValue]]
>> Ditto. I implemented valueOf(). Not sure if it’s the same.
> 
> I don't think this is the same.  The spec says resolveValue is added so it
> is functionality unique to XML and XMLList handling.  valueOf is used by
> the runtime in other places.  It looks like resolveValue is only used in a
> few specific cases.  It might have to be completely handled in the AS
> implementation.  I don't know if the compiler needs to do anything.  It
> looks like if you have some XML like:
> 
>    var xml:XML = <node><child /></node>
> 
> Then do:
> 
>    var myChild:XMLList = xml.myChild;
> 
> then myChild will be assigned an empty XMLList since there is no myChild
> tag in xml.  But amazingly, if you then do:
> 
>    myChild[0] = foo;
> 
> The implementation is supposed to use resolveValue to add a myChild
> property to the xml so the net is:
> 
>   <node><child /><myChild>foo</myChild></node>
> 
>> 
>>> [[append]] maps to concat()
>> That’s for XMLList. (which I’ve already done) What do we do for XML? Not
>> implement it? throw an error?
> 
> If I understand the spec, it never gets called on XML.  When the compiler
> sees the "+" operator, the generated code is supposed to generate a new
> XMLList.
> 
> Thanks for working on the E4X. It will be pretty cool when it starts
> working.
> 
> -Alex
> 
> [1] 
> http://www.i-programmer.info/programming/javascript/2951-objects-with-value
> s.html
> 


Re: [FALCONJX][FLEXJS] XML handling (was Re: [FlexJS] Back port)

Posted by Harbs <ha...@gmail.com>.
I’m working on toXMLString, and I need to write new lines. Is there a recommended way of writing new lines in a platform agnostic manner?

Re: [FALCONJX][FLEXJS] XML handling (was Re: [FlexJS] Back port)

Posted by Alex Harui <ah...@adobe.com>.

On 2/10/16, 3:23 AM, "Harbs" <ha...@gmail.com> wrote:

>I missed an issue here:
>
>Taking an example from the spec:
>e.employee.(name == "Jim").setChildren(<name>John</name> + <age>35</age>);
>
>or:
>var employeedata = <name>Fred</name> + <age>28</age> +
><hobby>skiing</hobby>;
>
>We need a method to concatenate two or more XML objects into an XML
>object. I see two ways to do this:
>
>1. Add a concat method to XML which returns a new XMLList with the XML
>object and the value passed in. If we do this, the compiler will not need
>to differentiate between XML and XMLList. Either one can be on either
>side of the operator.
>2. The compiler will need to create an XMLList for any XML object used.
>
>It seems to me that option #1 is simpler and less error prone.

You are probably right, but the spec says that the runtime (and therefore
our compiler) should generate an empty XMLList when an expression only
contains XML objects.  I have a feeling that before we're done, we'll be
needing the compiler to do some other stuff related to automatic type
conversion.  Otherwise, I think you will need to have the implementation
check the type various things at runtime to see if they are XML or
XMLList.  In theory the compiler already knows.

-Alex

>
>On Feb 9, 2016, at 8:04 PM, Alex Harui <ah...@adobe.com> wrote:
>
>>>> [[append]] maps to concat()
>>> That’s for XMLList. (which I’ve already done) What do we do for XML?
>>>Not
>>> implement it? throw an error?
>> 
>> If I understand the spec, it never gets called on XML.  When the
>>compiler
>> sees the "+" operator, the generated code is supposed to generate a new
>> XMLList.
>


Re: [FALCONJX][FLEXJS] XML handling (was Re: [FlexJS] Back port)

Posted by Harbs <ha...@gmail.com>.
I missed an issue here:

Taking an example from the spec:
e.employee.(name == "Jim").setChildren(<name>John</name> + <age>35</age>);

or:
var employeedata = <name>Fred</name> + <age>28</age> + <hobby>skiing</hobby>;

We need a method to concatenate two or more XML objects into an XML object. I see two ways to do this:

1. Add a concat method to XML which returns a new XMLList with the XML object and the value passed in. If we do this, the compiler will not need to differentiate between XML and XMLList. Either one can be on either side of the operator.
2. The compiler will need to create an XMLList for any XML object used.

It seems to me that option #1 is simpler and less error prone.

On Feb 9, 2016, at 8:04 PM, Alex Harui <ah...@adobe.com> wrote:

>>> [[append]] maps to concat()
>> That’s for XMLList. (which I’ve already done) What do we do for XML? Not
>> implement it? throw an error?
> 
> If I understand the spec, it never gets called on XML.  When the compiler
> sees the "+" operator, the generated code is supposed to generate a new
> XMLList.


Re: [FALCONJX][FLEXJS] XML handling (was Re: [FlexJS] Back port)

Posted by Alex Harui <ah...@adobe.com>.

On 2/9/16, 1:39 AM, "Harbs" <ha...@gmail.com> wrote:

>Thanks for this. It’s really good to have someone else go through this
>and give me a sanity check. Most of this is very much in line with what
>I’ve already done.
>
>Some comments:
>
>> [[get]]
>someXML[x] is only valid when x is 0 and that returns someXML and not a
>child of someXML.

OK, I hadn't realized that.  That makes me wonder if we need to intercept
all bracket calls on XML and XMLList and call child(int).  Are you
implementing XMLList as an Array or dynamic class with numeric property
names?  It might be better to implement a get() method and have the
compiler call that with ints or property names.  Apparently we are
supposed to blur the distinction between XML and XMLList.  I suppose
another trick would be to create a "0" property on XML.

>
>> [[defaultValue]]
>I’m not even sure what this means. I’ve implemented valueOf() and
>toString(). I’m not clear on when [[defaultValue]] is used.

I think it is used in automatic type conversion.  See [1].  Maybe you can
just implement valueOf() to call toString().

>
>> [[hasProperty]]
>I implemented hasOwnProperty() I’m not sure we need to do anything else.

OK. Makes sense.

>
>> [[deepCopy]]
>Yes. AFAICT, copy() is the the same as [[deepCopy]]

Agreed.

>
>> [[resolveValue]]
>Ditto. I implemented valueOf(). Not sure if it’s the same.

I don't think this is the same.  The spec says resolveValue is added so it
is functionality unique to XML and XMLList handling.  valueOf is used by
the runtime in other places.  It looks like resolveValue is only used in a
few specific cases.  It might have to be completely handled in the AS
implementation.  I don't know if the compiler needs to do anything.  It
looks like if you have some XML like:

    var xml:XML = <node><child /></node>

Then do:

    var myChild:XMLList = xml.myChild;

then myChild will be assigned an empty XMLList since there is no myChild
tag in xml.  But amazingly, if you then do:

    myChild[0] = foo;

The implementation is supposed to use resolveValue to add a myChild
property to the xml so the net is:

   <node><child /><myChild>foo</myChild></node>

>
>> [[append]] maps to concat()
>That’s for XMLList. (which I’ve already done) What do we do for XML? Not
>implement it? throw an error?

If I understand the spec, it never gets called on XML.  When the compiler
sees the "+" operator, the generated code is supposed to generate a new
XMLList.

Thanks for working on the E4X. It will be pretty cool when it starts
working.

-Alex

[1] 
http://www.i-programmer.info/programming/javascript/2951-objects-with-value
s.html


Re: [FALCONJX][FLEXJS] XML handling (was Re: [FlexJS] Back port)

Posted by Harbs <ha...@gmail.com>.
Thanks for this. It’s really good to have someone else go through this and give me a sanity check. Most of this is very much in line with what I’ve already done.

Some comments:

> [[get]]
someXML[x] is only valid when x is 0 and that returns someXML and not a child of someXML.

> [[put]]
Yes.

> [[delete]]
Yes.

> [[deleteByIndex]]
Probably. I think I’m using an alternate “remove by index” method internally, but I’ll probably name it something else to avoid issues.

> [[defaultValue]]
I’m not even sure what this means. I’ve implemented valueOf() and toString(). I’m not clear on when [[defaultValue]] is used.

> [[hasProperty]]
I implemented hasOwnProperty() I’m not sure we need to do anything else.

> [[deepCopy]]
Yes. AFAICT, copy() is the the same as [[deepCopy]]

> [[descendants]]
Yes.

> [[equals]]
Yes.

> [[resolveValue]]
Ditto. I implemented valueOf(). Not sure if it’s the same.

> [[insert]]
Yes.

> [[replace]]
Yes.

> [[addInScopeNamespaces]]
Yes.

> [[append]] maps to concat()
That’s for XMLList. (which I’ve already done) What do we do for XML? Not implement it? throw an error?

On Feb 9, 2016, at 2:56 AM, Alex Harui <ah...@adobe.com> wrote:

> OK, I looked at what is coded up so far on the compiler side and looked at
> the spec some more.  We've taken the approach so far of making up public
> method names that have a pretty close mapping to the internal methods.  It
> seems to me that we should not try to obfuscate the method names.  So what
> if there is a setChild() or filter() method on our JS version of XML.
> 
> One notable difference in the mapping is that the compiler has already
> parsed the @ prefix for attributes into its own token, so it makes it
> easier to call setAttribute() vs setChild() so the internal implementation
> doesn't have to bother to determine what is being "put".
> 
> Here's what I came up with:
> 
> [[get]] maps to attribute() and child() methods.  I think we need to
> handle someXML[x] where x is a numeric property name (0, 1, 2, 3, etc).
> We could see if we know the key is an integer and output elements()[x].
> 
> [[put]] maps to setAttribute() and setChild() methods.  The setAttribute()
> and setChild() implementations should call [[deepCopy]] on the value.  I
> don't think the compiler should call [[deepCopy]].
> 
> [[delete]] maps to removeChild().
> 
> [[deleteByIndex]] maps to removeChildAt() methods.  The implementation
> probably needs to throw the TypeError if removeChildAt() is called on an
> XML object.  For now, I think you'll get an NPE if there isn't a
> removeChildAt() on XML.
> 
> [[defaultValue]] This is not currently implemented in the compiler.  We
> should probably take this on when we get around to handling other
> ActionScript automatic type conversions.
> 
> [[hasProperty]] This is not currently implemented in the compiler.
> 
> [[deepCopy]] I think the compiler doesn't need to do anything here and the
> implementation will handle it.
> 
> [[descendants]] The compiler is mapping ".." to descendants() calls.
> 
> [[equals]] The compiler will have to look for "==" and call and equals()
> method.
> 
> [[resolveValue]] I'm not quite sure what to do here.
> 
> [[insert]] I think the compiler doesn't need to do anything here and the
> implementation will handle it.
> 
> [[replace]] I think the compiler doesn't need to do anything here and the
> implementation will handle it.
> 
> [[addInScopeNamespaces]] I think the compiler doesn't need to do anything
> here and the implementation will handle it.
> 
> [[append]] maps to concat()
> 
> 
> Another area of work is handling things like:
> 
> -typeof
> 
> -instanceof
> 
> These are already caught and converted to calls to
> org.apache.flex.utils.Language.  I think the Language implementation will
> have to become smart about XML.
> 
> Thoughts?
> -Alex
> 
> 
> On 2/8/16, 8:30 AM, "Alex Harui" <ah...@adobe.com> wrote:
> 
>> 
>> 
>> On 2/8/16, 1:00 AM, "Harbs" <ha...@gmail.com> wrote:
>>> However the spec does not specify bracket notation internally, so that’s
>>> not very clear. It could just be I’m not very experienced at reading
>>> specification documentation… ;-)
>> 
>> I'm not good at reading specs, probably because I find it boring.  This
>> spec [1] seems to describe some not-so-common notation like the double
>> brackets in section 9.1.1.
>> 
>> [1] 
>> http://www.ecma-international.org/publications/files/ECMA-ST-WITHDRAWN/Ecm
>> a
>> -357.pdf
>> 
>> 
>>> 
>>> I have implemented some of the internal methods/properties, but not all.
>>> I’m not sure it makes sense to implement them all.
>> 
>> Implementing the internal methods/properties does not seem to be required
>> by the spec.  But which ones are you thinking of skipping?
>> 
>>> 
>>> It could be it makes sense to modify things a bit, but right now my
>>> priority is to get all this working. Apparently, some feel that the ECMA
>>> spec has some problems with it which might have been patched[1], but I’m
>>> not sure exactly which.
>> 
>> There could certainly be bugs everywhere: in the spec, in the Flash
>> implementation, in the Mozilla implementation which apparently isn't
>> available anymore.
>> 
>>> 
>>> Right now, I’m pretty close to having all the methods in place (after
>>> quite a few rewrites). The only thing I have not even started on is
>>> filtering. I have no actually tried to compile any of this, so that will
>>> be a whole task in itself. (BTW, you can see what I currently have done
>>> in the e4x branch.)
>> 
>> I have not looked closely at what you committed, but I'm quite excited
>> that you are making any sort of progress on this.
>> 
>>> 
>>> So here’s my current plan:
>>> 1. Finish up the methods (minus filtering) in the next day or two.
>>> 2. Sync up XML with the current FlexJS folder structure and get rid of
>>> some junk (like all the JXON classes).
>>> 3. Get this all to compile.
>>> 4. Figure out the whole filtering issue.
>>> 5. Create test cases.
>>> 
>>> Once this is done (or mostly done), it probably makes sense to get a
>>> sanity check and decide whether to rewrite some of what I’ve done.
>>> 
>>> Makes sense?
>> 
>> Sounds reasonable.  I spent more time skimming the spec this morning.  I
>> think there are a lot more cases that the compiler doesn't handle.  You
>> and I may need to coordinate on when to work on those things, not that I'm
>> looking forward to having to do all that work.  The key to success looks
>> like it will be how the compiler can or can't know the resolved type of
>> something.  The spec is about how to change the runtime, but we can't
>> change the runtime and need to detect when an object is XML and generate
>> different code.  I have some concerns about whether that will start to
>> affect compiler performance, but I guess we'll just have to see, or maybe
>> I'll put XML checking in some conditional so you can opt in.
>> 
>> The link you posted didn't seem to point to any particular bug in E4X, but
>> it was an interesting discussion in how the JS runtimes don't want to take
>> on the complexity of E4X.  It would be interesting if there is a
>> functional subset of E4X that we could implement that would draw in the
>> E4X folks, especially the Node folks that appear to be stuck with handling
>> XML documents for legacy support reasons.
>> 
>>> 
>>> [1]https://bugs.chromium.org/p/v8/issues/detail?id=235#c75
>> 
>> -Alex
>> 
> 


Re: [FALCONJX][FLEXJS] XML handling (was Re: [FlexJS] Back port)

Posted by Alex Harui <ah...@adobe.com>.
OK, I looked at what is coded up so far on the compiler side and looked at
the spec some more.  We've taken the approach so far of making up public
method names that have a pretty close mapping to the internal methods.  It
seems to me that we should not try to obfuscate the method names.  So what
if there is a setChild() or filter() method on our JS version of XML.

One notable difference in the mapping is that the compiler has already
parsed the @ prefix for attributes into its own token, so it makes it
easier to call setAttribute() vs setChild() so the internal implementation
doesn't have to bother to determine what is being "put".

Here's what I came up with:

[[get]] maps to attribute() and child() methods.  I think we need to
handle someXML[x] where x is a numeric property name (0, 1, 2, 3, etc).
We could see if we know the key is an integer and output elements()[x].

[[put]] maps to setAttribute() and setChild() methods.  The setAttribute()
and setChild() implementations should call [[deepCopy]] on the value.  I
don't think the compiler should call [[deepCopy]].

[[delete]] maps to removeChild().

[[deleteByIndex]] maps to removeChildAt() methods.  The implementation
probably needs to throw the TypeError if removeChildAt() is called on an
XML object.  For now, I think you'll get an NPE if there isn't a
removeChildAt() on XML.

[[defaultValue]] This is not currently implemented in the compiler.  We
should probably take this on when we get around to handling other
ActionScript automatic type conversions.

[[hasProperty]] This is not currently implemented in the compiler.

[[deepCopy]] I think the compiler doesn't need to do anything here and the
implementation will handle it.

[[descendants]] The compiler is mapping ".." to descendants() calls.

[[equals]] The compiler will have to look for "==" and call and equals()
method.

[[resolveValue]] I'm not quite sure what to do here.

[[insert]] I think the compiler doesn't need to do anything here and the
implementation will handle it.

[[replace]] I think the compiler doesn't need to do anything here and the
implementation will handle it.

[[addInScopeNamespaces]] I think the compiler doesn't need to do anything
here and the implementation will handle it.

[[append]] maps to concat()


Another area of work is handling things like:

-typeof

-instanceof

These are already caught and converted to calls to
org.apache.flex.utils.Language.  I think the Language implementation will
have to become smart about XML.

Thoughts?
-Alex


On 2/8/16, 8:30 AM, "Alex Harui" <ah...@adobe.com> wrote:

>
>
>On 2/8/16, 1:00 AM, "Harbs" <ha...@gmail.com> wrote:
>>However the spec does not specify bracket notation internally, so that’s
>>not very clear. It could just be I’m not very experienced at reading
>>specification documentation… ;-)
>
>I'm not good at reading specs, probably because I find it boring.  This
>spec [1] seems to describe some not-so-common notation like the double
>brackets in section 9.1.1.
>
>[1] 
>http://www.ecma-international.org/publications/files/ECMA-ST-WITHDRAWN/Ecm
>a
>-357.pdf
>
>
>>
>>I have implemented some of the internal methods/properties, but not all.
>>I’m not sure it makes sense to implement them all.
>
>Implementing the internal methods/properties does not seem to be required
>by the spec.  But which ones are you thinking of skipping?
>
>>
>>It could be it makes sense to modify things a bit, but right now my
>>priority is to get all this working. Apparently, some feel that the ECMA
>>spec has some problems with it which might have been patched[1], but I’m
>>not sure exactly which.
>
>There could certainly be bugs everywhere: in the spec, in the Flash
>implementation, in the Mozilla implementation which apparently isn't
>available anymore.
>
>>
>>Right now, I’m pretty close to having all the methods in place (after
>>quite a few rewrites). The only thing I have not even started on is
>>filtering. I have no actually tried to compile any of this, so that will
>>be a whole task in itself. (BTW, you can see what I currently have done
>>in the e4x branch.)
>
>I have not looked closely at what you committed, but I'm quite excited
>that you are making any sort of progress on this.
>
>>
>>So here’s my current plan:
>>1. Finish up the methods (minus filtering) in the next day or two.
>>2. Sync up XML with the current FlexJS folder structure and get rid of
>>some junk (like all the JXON classes).
>>3. Get this all to compile.
>>4. Figure out the whole filtering issue.
>>5. Create test cases.
>>
>>Once this is done (or mostly done), it probably makes sense to get a
>>sanity check and decide whether to rewrite some of what I’ve done.
>>
>>Makes sense?
>
>Sounds reasonable.  I spent more time skimming the spec this morning.  I
>think there are a lot more cases that the compiler doesn't handle.  You
>and I may need to coordinate on when to work on those things, not that I'm
>looking forward to having to do all that work.  The key to success looks
>like it will be how the compiler can or can't know the resolved type of
>something.  The spec is about how to change the runtime, but we can't
>change the runtime and need to detect when an object is XML and generate
>different code.  I have some concerns about whether that will start to
>affect compiler performance, but I guess we'll just have to see, or maybe
>I'll put XML checking in some conditional so you can opt in.
>
>The link you posted didn't seem to point to any particular bug in E4X, but
>it was an interesting discussion in how the JS runtimes don't want to take
>on the complexity of E4X.  It would be interesting if there is a
>functional subset of E4X that we could implement that would draw in the
>E4X folks, especially the Node folks that appear to be stuck with handling
>XML documents for legacy support reasons.
>
>>
>>[1]https://bugs.chromium.org/p/v8/issues/detail?id=235#c75
>
>-Alex
>


Re: [FALCONJX][FLEXJS] XML handling (was Re: [FlexJS] Back port)

Posted by Alex Harui <ah...@adobe.com>.

On 2/8/16, 1:00 AM, "Harbs" <ha...@gmail.com> wrote:
>However the spec does not specify bracket notation internally, so that’s
>not very clear. It could just be I’m not very experienced at reading
>specification documentation… ;-)

I'm not good at reading specs, probably because I find it boring.  This
spec [1] seems to describe some not-so-common notation like the double
brackets in section 9.1.1.

[1] 
http://www.ecma-international.org/publications/files/ECMA-ST-WITHDRAWN/Ecma
-357.pdf


>
>I have implemented some of the internal methods/properties, but not all.
>I’m not sure it makes sense to implement them all.

Implementing the internal methods/properties does not seem to be required
by the spec.  But which ones are you thinking of skipping?

>
>It could be it makes sense to modify things a bit, but right now my
>priority is to get all this working. Apparently, some feel that the ECMA
>spec has some problems with it which might have been patched[1], but I’m
>not sure exactly which.

There could certainly be bugs everywhere: in the spec, in the Flash
implementation, in the Mozilla implementation which apparently isn't
available anymore.

>
>Right now, I’m pretty close to having all the methods in place (after
>quite a few rewrites). The only thing I have not even started on is
>filtering. I have no actually tried to compile any of this, so that will
>be a whole task in itself. (BTW, you can see what I currently have done
>in the e4x branch.)

I have not looked closely at what you committed, but I'm quite excited
that you are making any sort of progress on this.

>
>So here’s my current plan:
>1. Finish up the methods (minus filtering) in the next day or two.
>2. Sync up XML with the current FlexJS folder structure and get rid of
>some junk (like all the JXON classes).
>3. Get this all to compile.
>4. Figure out the whole filtering issue.
>5. Create test cases.
>
>Once this is done (or mostly done), it probably makes sense to get a
>sanity check and decide whether to rewrite some of what I’ve done.
>
>Makes sense?

Sounds reasonable.  I spent more time skimming the spec this morning.  I
think there are a lot more cases that the compiler doesn't handle.  You
and I may need to coordinate on when to work on those things, not that I'm
looking forward to having to do all that work.  The key to success looks
like it will be how the compiler can or can't know the resolved type of
something.  The spec is about how to change the runtime, but we can't
change the runtime and need to detect when an object is XML and generate
different code.  I have some concerns about whether that will start to
affect compiler performance, but I guess we'll just have to see, or maybe
I'll put XML checking in some conditional so you can opt in.

The link you posted didn't seem to point to any particular bug in E4X, but
it was an interesting discussion in how the JS runtimes don't want to take
on the complexity of E4X.  It would be interesting if there is a
functional subset of E4X that we could implement that would draw in the
E4X folks, especially the Node folks that appear to be stuck with handling
XML documents for legacy support reasons.

>
>[1]https://bugs.chromium.org/p/v8/issues/detail?id=235#c75

-Alex


Re: [FALCONJX][FLEXJS] XML handling (was Re: [FlexJS] Back port)

Posted by Harbs <ha...@gmail.com>.
Yes.

The internal methods are definitely different than the public APIs. For example, there is both a [[Replace]] internal method as well as a replace() API. The two do very different things. I also just realized that there is both [[InScopeNamespaces]] and inScopeNamespaces().

You are right that I was confused by [[Length]] which does refer to the length of the internal list of properties and not the length(). However the spec does not specify bracket notation internally, so that’s not very clear. It could just be I’m not very experienced at reading specification documentation… ;-)

I have implemented some of the internal methods/properties, but not all. I’m not sure it makes sense to implement them all.

It could be it makes sense to modify things a bit, but right now my priority is to get all this working. Apparently, some feel that the ECMA spec has some problems with it which might have been patched[1], but I’m not sure exactly which.

Right now, I’m pretty close to having all the methods in place (after quite a few rewrites). The only thing I have not even started on is filtering. I have no actually tried to compile any of this, so that will be a whole task in itself. (BTW, you can see what I currently have done in the e4x branch.)

So here’s my current plan:
1. Finish up the methods (minus filtering) in the next day or two.
2. Sync up XML with the current FlexJS folder structure and get rid of some junk (like all the JXON classes).
3. Get this all to compile.
4. Figure out the whole filtering issue.
5. Create test cases.

Once this is done (or mostly done), it probably makes sense to get a sanity check and decide whether to rewrite some of what I’ve done.

Makes sense?

[1]https://bugs.chromium.org/p/v8/issues/detail?id=235#c75

On Feb 8, 2016, at 7:09 AM, Alex Harui <ah...@adobe.com> wrote:

> Harbs,
> 
> Is it possible you are being tricked by the difference between the XML
> length() method and the Object length property?  The following outputs 1
> for me:
> 
> var xml:XML = <node><child /></node>;
> 		trace(xml.length());
> 
> 
> AFAICT, the spec is recommending an internal implementation that is not
> quite a 1:1 mapping to the public API.  It suggests keeping an ordered
> list of child nodes based upon how the Insert function got called so that
> if there is a "get" with a numeric property name, there is a specific
> behavior (conversion to XMLList and subsequent access of the correct
> child).  It does not seem to specify that there are properties like [0],
> [1], [2] on the XML object itself.  Rather, the get function is called
> with a numeric property name.
> 
> I really hadn't looked at the spec in any great detail until tonight, but
> it made me wonder if FalconJX should be outputting calls to insert,
> replace, put, get, etc.  We would add some sort of prefix and/or suffix to
> the internal methods so they don't really appear in the public API.
> 
> Thoughts?
> -Alex
> 
> On 2/7/16, 9:38 AM, "Harbs" <ha...@gmail.com> wrote:
> 
>> Yeah. Except an XML object always has a length of 0… AFAIK, xmlObj[1]
>> always returns undefined. The only valid index on an XML object is 0
>> which returns the XML object (to blur the distinction between XMLList and
>> XML). I think xmlList[0] is the same as xmlList[0][0][0][0]...
>> 
>> I think I’m just going to ignore this part of the spec because I’m
>> storing everything in a _children array and dealing with that.
>> 
>> On Feb 7, 2016, at 6:59 PM, Andy Dufilie <an...@gmail.com> wrote:
>> 
>>> The insert code looks fine to me, assuming children of XML are stored as
>>> properties "0", "1", "2", ...
>>> It's shifting all children with index >= i and saving P starting at
>>> child
>>> index i.
>>> 
>>> [[Put]] is overwriting a child at a given index, and
>>> insertChildBefore/insertChildAfter/prependChild should be doing the same
>>> type of operation as insert.
>> 
> 


Re: [FALCONJX][FLEXJS] XML handling (was Re: [FlexJS] Back port)

Posted by Alex Harui <ah...@adobe.com>.
Harbs,

Is it possible you are being tricked by the difference between the XML
length() method and the Object length property?  The following outputs 1
for me:

var xml:XML = <node><child /></node>;
		trace(xml.length());


AFAICT, the spec is recommending an internal implementation that is not
quite a 1:1 mapping to the public API.  It suggests keeping an ordered
list of child nodes based upon how the Insert function got called so that
if there is a "get" with a numeric property name, there is a specific
behavior (conversion to XMLList and subsequent access of the correct
child).  It does not seem to specify that there are properties like [0],
[1], [2] on the XML object itself.  Rather, the get function is called
with a numeric property name.

I really hadn't looked at the spec in any great detail until tonight, but
it made me wonder if FalconJX should be outputting calls to insert,
replace, put, get, etc.  We would add some sort of prefix and/or suffix to
the internal methods so they don't really appear in the public API.

Thoughts?
-Alex

On 2/7/16, 9:38 AM, "Harbs" <ha...@gmail.com> wrote:

>Yeah. Except an XML object always has a length of 0… AFAIK, xmlObj[1]
>always returns undefined. The only valid index on an XML object is 0
>which returns the XML object (to blur the distinction between XMLList and
>XML). I think xmlList[0] is the same as xmlList[0][0][0][0]...
>
>I think I’m just going to ignore this part of the spec because I’m
>storing everything in a _children array and dealing with that.
>
>On Feb 7, 2016, at 6:59 PM, Andy Dufilie <an...@gmail.com> wrote:
>
>> The insert code looks fine to me, assuming children of XML are stored as
>> properties "0", "1", "2", ...
>> It's shifting all children with index >= i and saving P starting at
>>child
>> index i.
>> 
>> [[Put]] is overwriting a child at a given index, and
>> insertChildBefore/insertChildAfter/prependChild should be doing the same
>> type of operation as insert.
>


Re: [FALCONJX][FLEXJS] XML handling (was Re: [FlexJS] Back port)

Posted by Harbs <ha...@gmail.com>.
Yeah. Except an XML object always has a length of 0… AFAIK, xmlObj[1] always returns undefined. The only valid index on an XML object is 0 which returns the XML object (to blur the distinction between XMLList and XML). I think xmlList[0] is the same as xmlList[0][0][0][0]...

I think I’m just going to ignore this part of the spec because I’m storing everything in a _children array and dealing with that.

On Feb 7, 2016, at 6:59 PM, Andy Dufilie <an...@gmail.com> wrote:

> The insert code looks fine to me, assuming children of XML are stored as
> properties "0", "1", "2", ...
> It's shifting all children with index >= i and saving P starting at child
> index i.
> 
> [[Put]] is overwriting a child at a given index, and
> insertChildBefore/insertChildAfter/prependChild should be doing the same
> type of operation as insert.


Re: [FALCONJX][FLEXJS] XML handling (was Re: [FlexJS] Back port)

Posted by Andy Dufilie <an...@gmail.com>.
The insert code looks fine to me, assuming children of XML are stored as
properties "0", "1", "2", ...
It's shifting all children with index >= i and saving P starting at child
index i.

[[Put]] is overwriting a child at a given index, and
insertChildBefore/insertChildAfter/prependChild should be doing the same
type of operation as insert.