You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@flex.apache.org by "wim.deblauwe" <wi...@gmail.com> on 2013/12/23 13:33:33 UTC

Flexmojos 6 and IntelliJ 13

Hi,

I am migrating to Flexmojos 6 and IntelliJ 13 cannot seem to import my
project. The log file of intelliJ shows: 

[ERROR] Cannot generate flex config for
/Users/wdb/Work/tmsng/flux-git/client-app-air/pom.xml
java.lang.reflect.InvocationTargetException
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
	at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
	at java.lang.reflect.Method.invoke(Method.java:597)
	at
com.intellij.flex.maven.IdeaConfiguratorFlexmojos5.build(IdeaConfiguratorFlexmojos5.java:107)
	at
com.intellij.flex.maven.IdeaConfiguratorFlexmojos5.build(IdeaConfiguratorFlexmojos5.java:130)
	at
com.intellij.flex.maven.IdeaConfiguratorFlexmojos5.generate(IdeaConfiguratorFlexmojos5.java:45)
	at
com.intellij.flex.maven.GeneratorServer.generate(GeneratorServer.java:185)
	at
com.intellij.flex.maven.GeneratorServer.access$200(GeneratorServer.java:44)
	at com.intellij.flex.maven.GeneratorServer$1.run(GeneratorServer.java:104)
	at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:439)
	at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303)
	at java.util.concurrent.FutureTask.run(FutureTask.java:138)
	at
java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:895)
	at
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:918)
	at java.lang.Thread.run(Thread.java:695)
Caused by:
net.flexmojos.oss.plugin.compiler.attributes.MavenRuntimeException: Missing
resource bundle
'com.adobe.flex.framework:flash-integration:rb.swc:es_ES:4.10.0.20130801'
	at
net.flexmojos.oss.plugin.compiler.AbstractFlexCompilerMojo.getCompiledResouceBundles_aroundBody30(AbstractFlexCompilerMojo.java:1856)
	at
net.flexmojos.oss.plugin.compiler.AbstractFlexCompilerMojo.getCompiledResouceBundles_aroundBody31$advice(AbstractFlexCompilerMojo.java:40)
	at
net.flexmojos.oss.plugin.compiler.AbstractFlexCompilerMojo.getCompiledResouceBundles(AbstractFlexCompilerMojo.java:1)
	at
net.flexmojos.oss.plugin.compiler.AbstractFlexCompilerMojo.getLibraryPath(AbstractFlexCompilerMojo.java:2314)
	at
net.flexmojos.oss.plugin.compiler.AbstractFlexCompilerMojo.getLibraryPath_aroundBody136(AbstractFlexCompilerMojo.java:2307)
	at
net.flexmojos.oss.plugin.compiler.AbstractFlexCompilerMojo.getLibraryPath_aroundBody137$advice(AbstractFlexCompilerMojo.java:40)
	at
net.flexmojos.oss.plugin.compiler.AbstractFlexCompilerMojo.getLibraryPath(AbstractFlexCompilerMojo.java:1)
	... 16 more

Where can I find
com.adobe.flex.framework:flash-integration:rb.swc:es_ES:4.10.0.20130801 ?

Anybody else has this issue?

regards,

Wim



--
View this message in context: http://apache-flex-users.2333346.n4.nabble.com/Flexmojos-6-and-IntelliJ-13-tp4262.html
Sent from the Apache Flex Users mailing list archive at Nabble.com.

AW: Flexmojos 6 and IntelliJ 13

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

Well the entire I18N handling is somewhat a little hack here. The problem is that you reference an empty 0 byte file as a maven dependency. Then during compile time Flexmojos downloads missing rb files for the languages the build should be compiled against. I think if this is not available there might be issues. But in case of missing locales I always thought there was a fallback mechanism to English ... could you please whip up an almost empty dummy project that reproduces that problem, then I'll have a look into it. The problem is that I didn't write Flexmojos, I am just maintaining it ... some parts of FM do mystical stuff that I have to dig into a little deeper ... I18N is one of these areas ;-)

But I can confirm that not all libs have resource bundles for all supported locales. The Mavenizer simply deploys what it can find. If something is missing, it's simply not deployed.

Chris

-----Ursprüngliche Nachricht-----
Von: Alexander Doroshko [mailto:alexander.doroshko@jetbrains.com] 
Gesendet: Montag, 23. Dezember 2013 17:33
An: users@flex.apache.org
Betreff: Re: Flexmojos 6 and IntelliJ 13

Workaround is to copy it from some other locale.

I'd like somebody from Flex SDK team to check, isn't that a bug that locale-specific subfolders of [Flex SDK]/frameworks/locale have different sets of *_rb.swc files?

If the absence of *_rb.swc file in standard SDK distribution doesn't prevent the app from being compiled using command line compiler, but causes errors in case of Flexmojos, then that's a question to Chris: 
isn't it a Flexmojos bug?

Alexander


On 23.12.2013 18:35, wim.deblauwe wrote:
> You are right, the Apache Flex SDK 4.11 does not have the 
> 'flash-integration_rb.swc' file in the 'frameworks/locale/es_ES' 
> folder. Any idea on how to get it there ?
>


AW: AW: Flexmojos 6 and IntelliJ 13

Posted by Christofer Dutz <ch...@c-ware.de>.
I have to admit that I only got to know this because of failing Unit-Tests ...
Will add this to the list of things I have to do next year :-)

Merry Christmas to all of you :-)

-----Ursprüngliche Nachricht-----
Von: wim.deblauwe [mailto:wim.deblauwe@gmail.com] 
Gesendet: Dienstag, 24. Dezember 2013 14:24
An: users@flex.apache.org
Betreff: Re: AW: Flexmojos 6 and IntelliJ 13

Great! This works indeed. I was totally unaware that this is possible. Would be good to add it in the docs.



--
View this message in context: http://apache-flex-users.2333346.n4.nabble.com/Flexmojos-6-and-IntelliJ-13-tp4262p4282.html
Sent from the Apache Flex Users mailing list archive at Nabble.com.

Re: AW: Flexmojos 6 and IntelliJ 13

Posted by "wim.deblauwe" <wi...@gmail.com>.
Great! This works indeed. I was totally unaware that this is possible. Would
be good to add it in the docs.



--
View this message in context: http://apache-flex-users.2333346.n4.nabble.com/Flexmojos-6-and-IntelliJ-13-tp4262p4282.html
Sent from the Apache Flex Users mailing list archive at Nabble.com.

AW: Flexmojos 6 and IntelliJ 13

Posted by Christofer Dutz <ch...@c-ware.de>.
But how does the Compiler then actually function correctly? Does it automatically fallback to en_US?

In Flexmojos there is this feature called locale-chains in which you can specify the order in which the languages are selected.

Here an example from the testsuite:

  <build>
    <plugins>
      <plugin>
        <groupId>net.flexmojos.oss</groupId>
        <artifactId>flexmojos-maven-plugin</artifactId>
        <configuration>
          <localesCompiled>
            <locale>en_US</locale>
            <locale>pt_PT,pt_BR,en_US</locale>
          </localesCompiled>
        </configuration>
      </plugin>
    </plugins>
  </build>

In this case the two "languages" en_US and, pt_PT are available in the application, but the compiler uses pt_BR if a pt_PT resource bundle is not available and if even pt_PT is not available it falls back to en_US.

I find this concept far more flexible than having the compiler automatically fallback to English ... so could you give the following resource configuration a try:

          <localesCompiled>
            <locale>en_US</locale>
            <locale>es_ES,en_US</locale>
          </localesCompiled>

It should do the trick.

Chris

-----Ursprüngliche Nachricht-----
Von: Alex Harui [mailto:aharui@adobe.com] 
Gesendet: Dienstag, 24. Dezember 2013 05:34
An: users@flex.apache.org
Betreff: Re: Flexmojos 6 and IntelliJ 13

My FB 4.7 comes with Adobe Flex 4.6 and the flash-integration_rb.swc is not in there either.  AFAIK, this is ok from the SDK's perspective.
Flexmojos will have to be tolerant of that.

On 12/23/13 8:32 AM, "Alexander Doroshko"
<al...@jetbrains.com> wrote:

>Workaround is to copy it from some other locale.
>
>I'd like somebody from Flex SDK team to check, isn't that a bug that 
>locale-specific subfolders of [Flex SDK]/frameworks/locale have 
>different sets of *_rb.swc files?
>
>If the absence of *_rb.swc file in standard SDK distribution doesn't 
>prevent the app from being compiled using command line compiler, but 
>causes errors in case of Flexmojos, then that's a question to Chris:
>isn't it a Flexmojos bug?
>
>Alexander
>
>
>On 23.12.2013 18:35, wim.deblauwe wrote:
>> You are right, the Apache Flex SDK 4.11 does not have the  
>>'flash-integration_rb.swc' file in the 'frameworks/locale/es_ES'
>>folder. Any
>> idea on how to get it there ?
>>
>


Re: Flexmojos 6 and IntelliJ 13

Posted by Alex Harui <ah...@adobe.com>.
My FB 4.7 comes with Adobe Flex 4.6 and the flash-integration_rb.swc is
not in there either.  AFAIK, this is ok from the SDK's perspective.
Flexmojos will have to be tolerant of that.

On 12/23/13 8:32 AM, "Alexander Doroshko"
<al...@jetbrains.com> wrote:

>Workaround is to copy it from some other locale.
>
>I'd like somebody from Flex SDK team to check, isn't that a bug that
>locale-specific subfolders of [Flex SDK]/frameworks/locale have
>different sets of *_rb.swc files?
>
>If the absence of *_rb.swc file in standard SDK distribution doesn't
>prevent the app from being compiled using command line compiler, but
>causes errors in case of Flexmojos, then that's a question to Chris:
>isn't it a Flexmojos bug?
>
>Alexander
>
>
>On 23.12.2013 18:35, wim.deblauwe wrote:
>> You are right, the Apache Flex SDK 4.11 does not have the
>> 'flash-integration_rb.swc' file in the 'frameworks/locale/es_ES'
>>folder. Any
>> idea on how to get it there ?
>>
>


Re: Flexmojos 6 and IntelliJ 13

Posted by Alexander Doroshko <al...@jetbrains.com>.
Workaround is to copy it from some other locale.

I'd like somebody from Flex SDK team to check, isn't that a bug that 
locale-specific subfolders of [Flex SDK]/frameworks/locale have 
different sets of *_rb.swc files?

If the absence of *_rb.swc file in standard SDK distribution doesn't 
prevent the app from being compiled using command line compiler, but 
causes errors in case of Flexmojos, then that's a question to Chris: 
isn't it a Flexmojos bug?

Alexander


On 23.12.2013 18:35, wim.deblauwe wrote:
> You are right, the Apache Flex SDK 4.11 does not have the
> 'flash-integration_rb.swc' file in the 'frameworks/locale/es_ES' folder. Any
> idea on how to get it there ?
>


Re: Flexmojos 6 and IntelliJ 13

Posted by "wim.deblauwe" <wi...@gmail.com>.
You are right, the Apache Flex SDK 4.11 does not have the
'flash-integration_rb.swc' file in the 'frameworks/locale/es_ES' folder. Any
idea on how to get it there ?



--
View this message in context: http://apache-flex-users.2333346.n4.nabble.com/Flexmojos-6-and-IntelliJ-13-tp4262p4270.html
Sent from the Apache Flex Users mailing list archive at Nabble.com.

Re: Flexmojos 6 and IntelliJ 13

Posted by Alexander Doroshko <al...@jetbrains.com>.
Make sure that Flex SDK that  you have mavenized includes [Flex 
SDK]frameworks/locale/es_ES. As far as I understand Mavenizer must have 
copied correct files to correct place automatically.

On 23.12.2013 18:12, wim.deblauwe wrote:
> I solved it by manually copying the en_US swc in my local repo and naming it
> es_ES. I am aware that this could lead to Spanish users seeing English text,
> but I don't think I am showing any of those strings. If somebody knows the
> proper way of solving this, I would be glad to hear it.
>
>
>
> --
> View this message in context: http://apache-flex-users.2333346.n4.nabble.com/Flexmojos-6-and-IntelliJ-13-tp4262p4268.html
> Sent from the Apache Flex Users mailing list archive at Nabble.com.


Re: Flexmojos 6 and IntelliJ 13

Posted by "wim.deblauwe" <wi...@gmail.com>.
I solved it by manually copying the en_US swc in my local repo and naming it
es_ES. I am aware that this could lead to Spanish users seeing English text,
but I don't think I am showing any of those strings. If somebody knows the
proper way of solving this, I would be glad to hear it.



--
View this message in context: http://apache-flex-users.2333346.n4.nabble.com/Flexmojos-6-and-IntelliJ-13-tp4262p4268.html
Sent from the Apache Flex Users mailing list archive at Nabble.com.

Re: Flexmojos 6 and IntelliJ 13

Posted by Alexander Doroshko <al...@jetbrains.com>.
Import in IntelliJ IDEA works correctly only for compilable flexmojos 
projects.
I hope Chris or someone will help you to resolve the issue.

Alexander

On 23.12.2013 16:58, wim.deblauwe wrote:
> I thought it did, but I did not compile my project fully. I just now tried to
> build it fully on the command line and it fails with the same exception:
>
> [ERROR] Failed to execute goal
> net.flexmojos.oss:flexmojos-maven-plugin:6.0.1:compile-swf
> (default-compile-swf) on project client-app-web:
> java.lang.reflect.InvocationTargetException: Missing resource bundle
> 'com.adobe.flex.framework:flash-integration:rb.swc:es_ES:4.11.0.20131017' ->
> [Help 1]
>
> This is how my plugin is configured:
>
> <plugin>
> 				<groupId>net.flexmojos.oss</groupId>
> 				<artifactId>flexmojos-maven-plugin</artifactId>
> 				<executions>
> 					<execution>
> 						<goals>
> 							<goal>wrapper</goal>
> 						</goals>
> 					</execution>
> 				</executions>
> 				<configuration>
> 					
> 					<defines>
> 						<property>
> 							<name>APP::version</name>
> 							<value>"${project.version}"</value>
> 						</property>
> 					</defines>
> 					<useNetwork>true</useNetwork>
> 					<parameters>
> 						<title>My Application</title>
> 					</parameters>
> 					<localesSourcePath>src/main/locales/{locale}</localesSourcePath>
> 					<localesCompiled>
> 						<compiled>fr_FR</compiled>
> 						<compiled>en_US</compiled>
> 						<compiled>es_ES</compiled>
> 						<compiled>de_DE</compiled>
> 						<compiled>it_IT</compiled>
> 						<compiled>pt_PT</compiled>
> 					</localesCompiled>
> 					<keepAs3Metadatas>
> 						<keepAs3Metadata>Autowired</keepAs3Metadata>
> 					</keepAs3Metadatas>
> 					<licenses>
>                          <flashbuilder45>xxxxxx</flashbuilder45>
> 					</licenses>
> 					<templateURI>folder:${basedir}/html-template</templateURI>
> 					<storepass />
> 				</configuration>
> 			</plugin>
>
> Note that this project was working fine with Flexmojos 4.
>
> regards,
>
> Wim
>
>
>
>
> --
> View this message in context: http://apache-flex-users.2333346.n4.nabble.com/Flexmojos-6-and-IntelliJ-13-tp4262p4264.html
> Sent from the Apache Flex Users mailing list archive at Nabble.com.


Re: Flexmojos 6 and IntelliJ 13

Posted by "wim.deblauwe" <wi...@gmail.com>.
I thought it did, but I did not compile my project fully. I just now tried to
build it fully on the command line and it fails with the same exception:

[ERROR] Failed to execute goal
net.flexmojos.oss:flexmojos-maven-plugin:6.0.1:compile-swf
(default-compile-swf) on project client-app-web:
java.lang.reflect.InvocationTargetException: Missing resource bundle
'com.adobe.flex.framework:flash-integration:rb.swc:es_ES:4.11.0.20131017' ->
[Help 1]

This is how my plugin is configured:

<plugin>
				<groupId>net.flexmojos.oss</groupId>
				<artifactId>flexmojos-maven-plugin</artifactId>
				<executions>
					<execution>
						<goals>
							<goal>wrapper</goal>
						</goals>
					</execution>
				</executions>
				<configuration>
					
					<defines>
						<property>
							<name>APP::version</name>
							<value>"${project.version}"</value>
						</property>
					</defines>
					<useNetwork>true</useNetwork>
					<parameters>
						<title>My Application</title>
					</parameters>
					<localesSourcePath>src/main/locales/{locale}</localesSourcePath>
					<localesCompiled>
						<compiled>fr_FR</compiled>
						<compiled>en_US</compiled>
						<compiled>es_ES</compiled>
						<compiled>de_DE</compiled>
						<compiled>it_IT</compiled>
						<compiled>pt_PT</compiled>
					</localesCompiled>
					<keepAs3Metadatas>
						<keepAs3Metadata>Autowired</keepAs3Metadata>
					</keepAs3Metadatas>
					<licenses>
                        <flashbuilder45>xxxxxx</flashbuilder45>
					</licenses>
					<templateURI>folder:${basedir}/html-template</templateURI>
					<storepass />
				</configuration>
			</plugin>

Note that this project was working fine with Flexmojos 4.

regards,

Wim




--
View this message in context: http://apache-flex-users.2333346.n4.nabble.com/Flexmojos-6-and-IntelliJ-13-tp4262p4264.html
Sent from the Apache Flex Users mailing list archive at Nabble.com.

Re: Flexmojos 6 and IntelliJ 13

Posted by Alexander Doroshko <al...@jetbrains.com>.
Does 'mvn compile' from command line finish successfully?
Is it possible to email me (directly) a sample project?

Alexander

On 23.12.2013 16:33, wim.deblauwe wrote:
> Hi,
>
> I am migrating to Flexmojos 6 and IntelliJ 13 cannot seem to import my
> project. The log file of intelliJ shows:
>
> [ERROR] Cannot generate flex config for
> /Users/wdb/Work/tmsng/flux-git/client-app-air/pom.xml
> java.lang.reflect.InvocationTargetException
> 	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> 	at
> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
> 	at
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
> 	at java.lang.reflect.Method.invoke(Method.java:597)
> 	at
> com.intellij.flex.maven.IdeaConfiguratorFlexmojos5.build(IdeaConfiguratorFlexmojos5.java:107)
> 	at
> com.intellij.flex.maven.IdeaConfiguratorFlexmojos5.build(IdeaConfiguratorFlexmojos5.java:130)
> 	at
> com.intellij.flex.maven.IdeaConfiguratorFlexmojos5.generate(IdeaConfiguratorFlexmojos5.java:45)
> 	at
> com.intellij.flex.maven.GeneratorServer.generate(GeneratorServer.java:185)
> 	at
> com.intellij.flex.maven.GeneratorServer.access$200(GeneratorServer.java:44)
> 	at com.intellij.flex.maven.GeneratorServer$1.run(GeneratorServer.java:104)
> 	at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:439)
> 	at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303)
> 	at java.util.concurrent.FutureTask.run(FutureTask.java:138)
> 	at
> java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:895)
> 	at
> java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:918)
> 	at java.lang.Thread.run(Thread.java:695)
> Caused by:
> net.flexmojos.oss.plugin.compiler.attributes.MavenRuntimeException: Missing
> resource bundle
> 'com.adobe.flex.framework:flash-integration:rb.swc:es_ES:4.10.0.20130801'
> 	at
> net.flexmojos.oss.plugin.compiler.AbstractFlexCompilerMojo.getCompiledResouceBundles_aroundBody30(AbstractFlexCompilerMojo.java:1856)
> 	at
> net.flexmojos.oss.plugin.compiler.AbstractFlexCompilerMojo.getCompiledResouceBundles_aroundBody31$advice(AbstractFlexCompilerMojo.java:40)
> 	at
> net.flexmojos.oss.plugin.compiler.AbstractFlexCompilerMojo.getCompiledResouceBundles(AbstractFlexCompilerMojo.java:1)
> 	at
> net.flexmojos.oss.plugin.compiler.AbstractFlexCompilerMojo.getLibraryPath(AbstractFlexCompilerMojo.java:2314)
> 	at
> net.flexmojos.oss.plugin.compiler.AbstractFlexCompilerMojo.getLibraryPath_aroundBody136(AbstractFlexCompilerMojo.java:2307)
> 	at
> net.flexmojos.oss.plugin.compiler.AbstractFlexCompilerMojo.getLibraryPath_aroundBody137$advice(AbstractFlexCompilerMojo.java:40)
> 	at
> net.flexmojos.oss.plugin.compiler.AbstractFlexCompilerMojo.getLibraryPath(AbstractFlexCompilerMojo.java:1)
> 	... 16 more
>
> Where can I find
> com.adobe.flex.framework:flash-integration:rb.swc:es_ES:4.10.0.20130801 ?
>
> Anybody else has this issue?
>
> regards,
>
> Wim
>
>
>
> --
> View this message in context: http://apache-flex-users.2333346.n4.nabble.com/Flexmojos-6-and-IntelliJ-13-tp4262.html
> Sent from the Apache Flex Users mailing list archive at Nabble.com.