Compilation works, execution doesn't
Moderators: North, BetaSteward, noxx, jeffwadsworth, JayDi, TheElk801, LevelX, CCGHQ Admins
Compilation works, execution doesn't
by Ratosai » 10 Aug 2014, 17:10
Hi, I recently found Xmage and want to contribute, but I'm having trouble getting the compiled code to run correctly on Windows 8. I cloned the repository for Xmage, updated java, installed Maven, and compiled Xmage through the command line (using "mvn clean install -DskipTests", as some tests failed). I tried running the various startClientWin7.bat files in the "release" folders, but those gave "unable to access jar file", even though the path was correct. The "target" folders were also created and populated with the executable jars, but running them didn't work either. For example, running the jar in "Xmage.Client/target" makes the Xmage logo pop up briefly, then go away without actually launching the program. What am I doing wrong?
Re: Compilation works, execution doesn't
by LevelX » 10 Aug 2014, 18:32
I don't use it that way, so it's hard to assist you.
If you want to create a IDE independant compilation you can use the included perl script:
build-and-package.pl
That's the one I use to create a new version.
If you use Netbeans IDE I can be of more help I guess.
https://github.com/magefree/mage/wiki/Developer-Getting-Started
If you want to create a IDE independant compilation you can use the included perl script:
build-and-package.pl
That's the one I use to create a new version.
If you use Netbeans IDE I can be of more help I guess.
https://github.com/magefree/mage/wiki/Developer-Getting-Started
-
LevelX - DEVELOPER
- Posts: 1677
- Joined: 08 Dec 2011, 15:08
- Has thanked: 174 times
- Been thanked: 374 times
Re: Compilation works, execution doesn't
by Ratosai » 10 Aug 2014, 21:11
That worked beautifully, thank you! I completely overlooked the Utils folder.
Re: Compilation works, execution doesn't
by rlinne » 15 Aug 2014, 00:56
Sorry to revive a dead thread but I am having a similar issue in running the dev build.
I have tried the instructions provided at the Getting started section of GitHub and running the build-and-package.pl script in the Utils folder. I have also attempted a command line install with maven and received this error in both IDE (Netbeans) and command line.
"Failed to execute goal org.codehaus.mojo:exec-maven-plugin:1.2.1:exec (default-cli) on project mage-server: Command execution failed. Process exited with an error: 1 (Exit value: 1) -> [Help 1]"
Any ideas on what I can do resolve this and start with development?
Thanks!
I have tried the instructions provided at the Getting started section of GitHub and running the build-and-package.pl script in the Utils folder. I have also attempted a command line install with maven and received this error in both IDE (Netbeans) and command line.
"Failed to execute goal org.codehaus.mojo:exec-maven-plugin:1.2.1:exec (default-cli) on project mage-server: Command execution failed. Process exited with an error: 1 (Exit value: 1) -> [Help 1]"
Any ideas on what I can do resolve this and start with development?
Thanks!
- rlinne
- Posts: 1
- Joined: 15 Aug 2014, 00:50
- Has thanked: 0 time
- Been thanked: 0 time
Re: Compilation works, execution doesn't
by LevelX » 15 Aug 2014, 07:36
Ok, You have compiled all projects with success?rlinne wrote:Sorry to revive a dead thread but I am having a similar issue in running the dev build.
I have tried the instructions provided at the Getting started section of GitHub and running the build-and-package.pl script in the Utils folder. I have also attempted a command line install with maven and received this error in both IDE (Netbeans) and command line.
"Failed to execute goal org.codehaus.mojo:exec-maven-plugin:1.2.1:exec (default-cli) on project mage-server: Command execution failed. Process exited with an error: 1 (Exit value: 1) -> [Help 1]"
Any ideas on what I can do resolve this and start with development?
Thanks!
Now you try to start the XMage server component from IDE and got that error?
Check that you have some things set to properties of Server project:
And than start the Server in debug mode by using the context menu:
What OS System and Version of Netbeans and Java do you use?
-
LevelX - DEVELOPER
- Posts: 1677
- Joined: 08 Dec 2011, 15:08
- Has thanked: 174 times
- Been thanked: 374 times
Re: Compilation works, execution doesn't
by JJ-Marcel » 28 Aug 2014, 03:25
Figured maybe I could add to this thread with another build issue (not sure if you guys prefer new threads for new issues or not).
I checked out the code a number of days ago and finally had a chance to take a closer look. I've installed NetBeans since that seems to be the standard here but when trying to clean and build the project I'm failing a test, not the one mentioned above, but rather the test using Humility and Progenitus.
Windows 7. Java is up-to-date. Local repository is up-to-date.
I checked out the code a number of days ago and finally had a chance to take a closer look. I've installed NetBeans since that seems to be the standard here but when trying to clean and build the project I'm failing a test, not the one mentioned above, but rather the test using Humility and Progenitus.
- Code: Select all
testHumilityDeactivatesReplacementEffectAbilities(org.mage.test.cards.replacement.ZoneChangeReplacementTest) Time elapsed: 0.279 sec <<< FAILURE!
java.lang.AssertionError: (Graveyard) Card counts are not equal (Progenitus) expected:<1> but was:<0>
at org.junit.Assert.fail(Assert.java:91)
at org.junit.Assert.failNotEquals(Assert.java:645)
at org.junit.Assert.assertEquals(Assert.java:126)
at org.junit.Assert.assertEquals(Assert.java:470)
at org.mage.test.serverside.base.impl.CardTestPlayerAPIImpl.assertGraveyardCount(CardTestPlayerAPIImpl.java:640)
at org.mage.test.cards.replacement.ZoneChangeReplacementTest.testHumilityDeactivatesReplacementEffectAbilities(ZoneChangeReplacementTest.java:156)
Windows 7. Java is up-to-date. Local repository is up-to-date.
- JJ-Marcel
- Posts: 4
- Joined: 28 Aug 2014, 02:52
- Has thanked: 0 time
- Been thanked: 0 time
Re: Compilation works, execution doesn't
by LevelX » 28 Aug 2014, 06:27
Hello JJ-Marcel,JJ-Marcel wrote:Figured maybe I could add to this thread with another build issue (not sure if you guys prefer new threads for new issues or not).
I checked out the code a number of days ago and finally had a chance to take a closer look. I've installed NetBeans since that seems to be the standard here but when trying to clean and build the project I'm failing a test, not the one mentioned above, but rather the test using Humility and Progenitus.
that's perfectly fine because this bug is still not resolved in XMage.
https://github.com/magefree/mage/issues/533
So your envirement is ready to work and contribute.
If you have any more questions, this forum is the right place to ask.
Regards
LevelX2
-
LevelX - DEVELOPER
- Posts: 1677
- Joined: 08 Dec 2011, 15:08
- Has thanked: 174 times
- Been thanked: 374 times
Re: Compilation works, execution doesn't
by JJ-Marcel » 01 Sep 2014, 02:35
Great, unfortunately I'm now having an issue running Mage.Server. I can run Mage.Client, but I can't get the local server up as it's throwing some maven exceptions at me.
- Code: Select all
Failed to execute goal org.codehaus.mojo:exec-maven-plugin:1.2.1:exec (default-cli) on project mage-server: Command execution failed. Process exited with an error: 1 (Exit value: 1) -> [Help 1]
org.apache.maven.lifecycle.LifecycleExecutionException: Failed to execute goal org.codehaus.mojo:exec-maven-plugin:1.2.1:exec (default-cli) on project mage-server: Command execution failed.
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:217)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:153)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:145)
at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:84)
- Code: Select all
Some problems were encountered while building the effective model for org.mage:mage-stats:war:1.3.0
'dependencies.dependency.(groupId:artifactId:type:classifier)' must be unique: net.minidev:json-smart:jar -> duplicate declaration of version 1.1.1 @ line 71, column 21
'dependencies.dependency.(groupId:artifactId:type:classifier)' must be unique: org.aspectj:aspectjrt:jar -> duplicate declaration of version 1.6.11 @ line 77, column 21
'build.plugins.plugin.version' for org.apache.maven.plugins:maven-war-plugin is missing. @ line 146, column 21
- JJ-Marcel
- Posts: 4
- Joined: 28 Aug 2014, 02:52
- Has thanked: 0 time
- Been thanked: 0 time
Re: Compilation works, execution doesn't
by LevelX » 01 Sep 2014, 05:40
I guess you set parameter like shown two post earlier and start it in debug mode?JJ-Marcel wrote:Great, unfortunately I'm now having an issue running Mage.Server. I can run Mage.Client, but I can't get the local server up as it's throwing some maven exceptions at me.
Is the code you showed the full output if you try to start debug for the server project? If not can you please show the complete log.
Here is the start of the output if I start it on my system.
- Code: Select all
NetBeans: JPDA Listening Start...
JPDA Address: Notebook:60180
Port:60180
cd C:\Users\Developer\Documents\NetBeansProjects\mageNew\Mage.Server; "JAVA_HOME=C:\\Program Files\\Java\\jdk1.8.0_11" cmd /c "\"\"C:\\Program Files\\NetBeans 8.0\\java\\maven\\bin\\mvn.bat\" -Dexec.args=\"-Xdebug -Xrunjdwp:transport=dt_socket,server=n,address=60180 -Xverify:none -client -Xss2m -Xms128m -Xmx512m -XX:PermSize=256m -classpath %classpath mage.server.Main -testMode=true -adminPassword=chef\" -Dexec.executable=\"C:\\Program Files\\Java\\jdk1.8.0_11\\bin\\java.exe\" -Dexec.classpathScope=runtime -Djpda.listen=true -Djpda.address=60180 -Dmaven.ext.class.path=\"C:\\Program Files\\NetBeans 8.0\\java\\maven-nblib\\netbeans-eventspy.jar\" -Dfile.encoding=UTF-8 process-classes org.codehaus.mojo:exec-maven-plugin:1.2:exec\""
Scanning for projects...
------------------------------------------------------------------------
Building Mage Server 1.3.0
------------------------------------------------------------------------
--- maven-jaxb2-plugin:0.7.4:generate (default) @ mage-server ---
Cannot find CatalogManager.properties
Skipped XJC execution. Generated sources were up-to-date.
--- maven-resources-plugin:2.5:resources (default-resources) @ mage-server ---
[debug] execute contextualize
Using 'UTF-8' encoding to copy filtered resources.
Copying 2 resources
Copying 0 resource
Copying 1 resource
--- maven-compiler-plugin:2.0.2:compile (default-compile) @ mage-server ---
Nothing to compile - all classes are up to date
You can ignore this, It comes from a new project not finished yet and has no influence on XMage server or client.JJ-Marcel wrote:Some problems were encountered while building the effective model for org.mage:mage-stats:war:1.3.0
-
LevelX - DEVELOPER
- Posts: 1677
- Joined: 08 Dec 2011, 15:08
- Has thanked: 174 times
- Been thanked: 374 times
Re: Compilation works, execution doesn't
by LevelX » 01 Sep 2014, 05:45
Did you deactivate the "Compile on save" option in [Project]->Properties/Build/Compile/ tab? It brings up sometimes strange bugs. So best you deactivate it.JJ-Marcel wrote:Great, unfortunately I'm now having an issue running Mage.Server. I can run Mage.Client, but I can't get the local server up as it's throwing some maven exceptions at me.
-
LevelX - DEVELOPER
- Posts: 1677
- Joined: 08 Dec 2011, 15:08
- Has thanked: 174 times
- Been thanked: 374 times
Re: Compilation works, execution doesn't
by JJ-Marcel » 02 Sep 2014, 01:29
Ah, you know what, I did not have my parameters set for the Mage Server project exactly like your posted image. Making that change fixed it, thanks! That would probably be helpful in the getting started guide. I presume this would also indeed be the solution for rlinne since his error seemed to be the same, although he has not responded.
- JJ-Marcel
- Posts: 4
- Joined: 28 Aug 2014, 02:52
- Has thanked: 0 time
- Been thanked: 0 time
Re: Compilation works, execution doesn't
by LevelX » 02 Sep 2014, 06:30
Great that you got it to work.JJ-Marcel wrote:Ah, you know what, I did not have my parameters set for the Mage Server project exactly like your posted image. Making that change fixed it, thanks! That would probably be helpful in the getting started guide. I presume this would also indeed be the solution for rlinne since his error seemed to be the same, although he has not responded.
What was the causing parameter difference you did not set?
-
LevelX - DEVELOPER
- Posts: 1677
- Joined: 08 Dec 2011, 15:08
- Has thanked: 174 times
- Been thanked: 374 times
12 posts
• Page 1 of 1
Who is online
Users browsing this forum: No registered users and 21 guests