Giter Club home page Giter Club logo

Comments (6)

radsz avatar radsz commented on August 26, 2024

Hi,

Did you use Maven to execute phases clean/compile/install of JaCoP? JaCoP is distributed as Maven project and those classes that are missing for you will be generated by Maven.

If you use Maven you should not have those compiler errors.

Hope that helps.

best,
Radek

from jacop.

vittali avatar vittali commented on August 26, 2024

Hi Radek

Thanks for getting back to me, I imported the project into eclipse as a
maven project.
But running maven from the command line gives me the same problem:

$ mvn clean
$ mvn compile
[INFO] Scanning for projects...
[WARNING]
[WARNING] Some problems were encountered while building the effective model
for org:jacop:jar:4.0.0
[WARNING] 'build.pluginManagement.plugins.plugin.(groupId:artifactId)' must
be unique but found duplicate declaration of plugin
org.apache.maven.plugins:maven-surefire-plugin @ line 215, column 25
[WARNING] 'build.pluginManagement.plugins.plugin.(groupId:artifactId)' must
be unique but found duplicate declaration of plugin
org.apache.maven.plugins:maven-site-plugin @ line 220, column 25
[WARNING]
[WARNING] It is highly recommended to fix these problems because they
threaten the stability of your build.
[WARNING]
[WARNING] For this reason, future Maven versions might no longer support
building such malformed projects.
[WARNING]
[INFO]

[INFO]

[INFO] Building jacop 4.0.0

[INFO]

[INFO]

[INFO] --- maven-resources-plugin:2.6:resources (default-resources) @ jacop

[INFO] Using 'UTF-8' encoding to copy filtered resources.
[INFO] skip non existing resourceDirectory
/home/p/kepler/jacop-4/src/main/resources
[INFO]

[INFO] --- maven-compiler-plugin:2.5.1:compile (default-compile) @ jacop

[INFO] Compiling 364 source files to /home/p/kepler/jacop-4/target/classes
[INFO] -------------------------------------------------------------
[ERROR] COMPILATION ERROR :
[INFO] -------------------------------------------------------------
[ERROR]
/home/p/kepler/jacop-4/src/main/java/org/jacop/fz/SimpleNode.java:[6,28]
error: cannot find symbol
[ERROR] symbol: class Node
/home/p/kepler/jacop-4/src/main/java/org/jacop/fz/ASTSetLiteral.java:[11,23]
error: cannot find symbol [ERROR] symbol: class Parser location: class
ASTSetLiteral
/home/p/kepler/jacop-4/src/main/java/org/jacop/fz/SimpleNode.java:[8,12]
error: cannot find symbol
[ERROR] symbol: class Node location: class SimpleNode
/home/p/kepler/jacop-4/src/main/java/org/jacop/fz/SimpleNode.java:[9,12]
error: cannot find symbol
[ERROR] symbol: class Node location: class SimpleNode
/home/p/kepler/jacop-4/src/main/java/org/jacop/fz/SimpleNode.java:[12,12]
error: cannot find symbol
[ERROR] symbol: class Parser location: class SimpleNode

... many more errors

Note: compiling with java 8.

On Sat, Apr 12, 2014 at 10:26 AM, radsz [email protected] wrote:

Hi,

Did you use Maven to execute phases clean/compile/install of JaCoP? JaCoP
is distributed as Maven project and those classes that are missing for you
will be generated by Maven.

If you use Maven you should not have those compiler errors.

Hope that helps.

best,
Radek

Reply to this email directly or view it on GitHubhttps://github.com//issues/5#issuecomment-40275047
.

from jacop.

radsz avatar radsz commented on August 26, 2024

Hi,

I downloaded master branch in zip form from github. I opened the project in InteliJ (this is the IDE I use) and I did clean/compile/install for JaCoP maven project. I did it with 1.7 Java. I do not have 1.8 version installed.

It builds successfully.

Thus, somewhere (Maven, Eclipse, Java 1.8) lies your problem. Not sure where. Usually, Eclipse and Maven projects are the first suspect. Can you run "mvn clean install" from the terminal window?

best,
Radek

P.S. We have a jar file available for download at Sourceforge if you have problems building yourself.

from jacop.

vittali avatar vittali commented on August 26, 2024

Hi
I recloned the git and run mvn clean install before I imported the
project into eclipse and it works. So thanks a lot for this.

I now have warnings that my eclipse settings turn into errors ( this is on
purpose to enforce certain rules ), for example:

  1. File Alldiff.java
    public static String[] xmlAttributes = {"list"};
    -> this hides a field in the super class

  2. File AndBool.java
    public void consistency(Store store) {
    -> add missing override annotation ( see Item 36 Bloch, "Consistenly use
    the override annotation )

I would suggest that 2) should be fixed as it seems to be a clearly
identified best practice.
I am less sure about 1) . Is my workspace compiler setting to strict or is
this something that could be improved upon in the code ? For example by
making xmlAttributes to protected ( rather than public) and reassigning
the string in the constructor of Alldiff + adding public getters ? What do
you think ?

Peter

On Sat, Apr 12, 2014 at 8:01 PM, radsz [email protected] wrote:

Hi,

I downloaded master branch in zip form from github. I opened the project
in InteliJ (this is the IDE I use) and I did clean/compile/install for
JaCoP maven project. I did it with 1.7 Java. I do not have 1.8 version
installed.

It builds successfully.

Thus, somewhere (Maven, Eclipse, Java 1.8) lies your problem. Not sure
where. Usually, Eclipse and Maven projects are the first suspect. Can you
run "mvn clean install" from the terminal window?

best,
Radek

P.S. We have a jar file available for download at Sourceforge if you have
problems building yourself.

Reply to this email directly or view it on GitHubhttps://github.com//issues/5#issuecomment-40287172
.

from jacop.

radsz avatar radsz commented on August 26, 2024

Hi,

Thanks for persistence in solving your problems. It gives us some feedback what we can do better to make it easier for people to start with JaCoP. IDEs can be differently setup and your strict Eclipse setup is less forgiving than other IDEs.

Concerning remaining two warnings.

This xml attribute is not used, we were planning to use it for some xml support but then we dropped it so this code will most likely be removed in future versions. An item to clean up the code.

Override annotation is a pain. It has been changed somewhat between 1.5 and 1.6 version. I will recheck behavior for it in 1.6, 1.7, and 1.8 and if I can get rid of warnings in all three different Java versions then we will fix this issue too.

Thanks for feedback.

best,
Radek

from jacop.

vittali avatar vittali commented on August 26, 2024

Hi Radek
Thanks a lot for your support. In fact override annotation in eclipse is
really fun. You can select the packages that are missing overrides and then
right click "clean source". You can configure what "clean" means, but the
default setting will add overrides automatically where necessary. This is a
great feature.
Thanks again
Peter

On Mon, Apr 14, 2014 at 1:17 PM, radsz [email protected] wrote:

Hi,

Thanks for persistence in solving your problems. It gives us some feedback
what we can do better to make it easier for people to start with JaCoP.
IDEs can be differently setup and your strict Eclipse setup is less
forgiving than other IDEs.

Concerning remaining two warnings.

This xml attribute is not used, we were planning to use it for some xml
support but then we dropped it so this code will most likely be removed in
future versions. An item to clean up the code.

Override annotation is a pain. It has been changed somewhat between 1.5
and 1.6 version. I will recheck behavior for it in 1.6, 1.7, and 1.8 and if
I can get rid of warnings in all three different Java versions then we will
fix this issue too.

Thanks for feedback.

best,
Radek

Reply to this email directly or view it on GitHubhttps://github.com//issues/5#issuecomment-40355403
.

from jacop.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.