Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Problem with Gradle and AspectJ #6

Closed
martinschaef opened this issue Jun 11, 2015 · 5 comments
Closed

Problem with Gradle and AspectJ #6

martinschaef opened this issue Jun 11, 2015 · 5 comments
Labels

Comments

@martinschaef
Copy link

I tried infer on my project:
https://github.com/martinschaef/bixie/tree/master/tool
calling gradle clean and then
infer -- gradle build
and it replies with

Starting analysis (Infer version v0.1.0)
Analysis done
3 files analyzed
No issues found

However, there are significantly more java files in this project. What am I doing wrong?

@sblackshear
Copy link
Contributor

Hi Martin,
You are not doing anything wrong--looks like there's an issue with Infer's Gradle support. The Gradle wrapper is quite primitive and just looks for calls to javac in the verbose output for Gradle. For some reason, these calls do not appear for your compileJava rule (I suspect it has something to do with the `ant options?).

I was able to get a little further by bypassing Gradle with find src/main/ -name *.java | xargs infer -- javac -cp .:lib/* from bixie/tool/, but then I ran into #3. We're working on fixing both that and the Gradle problem; thanks for the report!

@martinschaef
Copy link
Author

Hi Sam ... small world! Are you with Facebook now? I'll follow the other issue as well then. Are you going to release a new version or should I build from source?

@sblackshear
Copy link
Contributor

Hi Martin,
Yes, I work at FB part-time now and am joining full-time in the fall! I am not sure what our policy on releasing new binaries is going to be--my guess is that we'll push bugfixes to source ASAP but that we will only release binaries for new major versions. So it might be worthwhile to try building from source.

@martinschaef
Copy link
Author

Ok. The gradle problem is that I do some aspect weaving stuff which overrides the compileJava task. Once my I remove line 43 and 44-65 in build.gradle it finds everything but runs into the exception which you mentioned in the other issue. Thanks.

@martinschaef martinschaef changed the title Only 3 out of many Java files analyzed for Gradle project Problem with Gradle and AspectJ Jun 11, 2015
@irpap irpap added the java label Jun 15, 2015
@jvillard
Copy link
Contributor

Hi @martinschaef , #3 has been closed by the latest Infer release and it looks like this would solve your issue too. Feel free to reopen if v0.1.1 doesn't fix it for you.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

4 participants