You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@groovy.apache.org by Cédric Champeau <ce...@gmail.com> on 2018/05/22 19:02:56 UTC

Troubles with IDEA setup

Hi team,

I've been trying to figure out what is happening for hours now, but I
cannot find any reason. I'm working on master, after removing all IDEA
state (.iml, .ipr, .iws), regenerating the IDEA files using:

./gradlew jar idea --rerun-tasks

And then I open the project in IDEA and try to run a unit test. But then
the IDE is stuck in "Groovyc: semantic analysis [tests of groovy-xml and 8
more]". CPU is not busy, nothing happens.

I thought it could be a CPU issue, so I increased the memory for the IDEA
compiler process, without success.

Any idea what could be going on? Am I the only one seeing this?

Re: Troubles with IDEA setup

Posted by Cédric Champeau <ce...@gmail.com>.
That's what I meant with "native import".

Le mer. 23 mai 2018 à 08:28, Daniel.Sun <su...@apache.org> a écrit :

> Hi Cédric,
>
>        Try to import as a gradle project?
>
> Cheers,
> Daniel.Sun
>
>
>
> --
> Sent from: http://groovy.329449.n5.nabble.com/Groovy-Dev-f372993.html
>

Re: Troubles with IDEA setup

Posted by "Daniel.Sun" <su...@apache.org>.
Hi Cédric,

       Try to import as a gradle project?

Cheers,
Daniel.Sun



--
Sent from: http://groovy.329449.n5.nabble.com/Groovy-Dev-f372993.html

Re: Troubles with IDEA setup

Posted by Marcin Erdmann <ma...@proxerd.pl>.
An even less constructive response - you are very wrong, IMHO. :)

I always use Gradle's idea plugin on my projects because it gives me far
better control on how the IntelliJ project looks like and what it does then
if I "natively imported" it, as Cedric calls it. I find native imports very
selective and constraining, e.g. using Gradle's idea plugin allows me to
easily specify additional source sets which are then recognised as a source
set by IntelliJ and not just a bunch of files in a directory. And I don't
share your view that it got harder over time - it's hardly changed since I
started to use it and in the end it's just a bit of xml generation, how
hard can it be.

I know it's just a build tool and the expectation is that everything should
just work no matter how much people abuse it. But I've learned that by
spending some time to dig deeper and learn Gradle a bit better one can do
themselves a favour. Especially when it comes to having consistent and
working setup of the project in IntelliJ for everybody on the team.

Marcin

On Wed, May 23, 2018 at 10:26 AM, Russel Winder <ru...@winder.org.uk>
wrote:

> On Wed, 2018-05-23 at 08:22 +0200, Cédric Champeau wrote:
> > I managed to do something using the IDE native import (instead of using
> > ./gradlew idea) and delegating all actions to Gradle. It's slower
> feedback,
> > but at least I can work.
> >
>
> Not a constructive response per se, more a data point. The Gradle IDEA
> stuff
> got so hard to get right I gave up on it long ago. IntelliJ IDEA seems to
> have
> a far better idea (!) of how to handle Gradle projects than Gradle has of
> generating IntelliJ IDEA projects.
>
> --
> Russel.
> ==========================================
> Dr Russel Winder      t: +44 20 7585 2200
> 41 Buckmaster Road    m: +44 7770 465 077
> London SW11 1EN, UK   w: www.russel.org.uk
>

Re: Troubles with IDEA setup

Posted by Russel Winder <ru...@winder.org.uk>.
On Wed, 2018-05-23 at 08:22 +0200, Cédric Champeau wrote:
> I managed to do something using the IDE native import (instead of using
> ./gradlew idea) and delegating all actions to Gradle. It's slower feedback,
> but at least I can work.
> 

Not a constructive response per se, more a data point. The Gradle IDEA stuff
got so hard to get right I gave up on it long ago. IntelliJ IDEA seems to have
a far better idea (!) of how to handle Gradle projects than Gradle has of
generating IntelliJ IDEA projects.
 
-- 
Russel.
==========================================
Dr Russel Winder      t: +44 20 7585 2200
41 Buckmaster Road    m: +44 7770 465 077
London SW11 1EN, UK   w: www.russel.org.uk

Re: Troubles with IDEA setup

Posted by Cédric Champeau <ce...@gmail.com>.
I managed to do something using the IDE native import (instead of using
./gradlew idea) and delegating all actions to Gradle. It's slower feedback,
but at least I can work.

Le mar. 22 mai 2018 à 23:37, Cédric Champeau <ce...@gmail.com> a
écrit :

> No luck, I'm still stuck :(
>
> Le mar. 22 mai 2018 à 21:23, Daniel.Sun <su...@apache.org> a écrit :
>
>> Hi Cédric,
>>
>>       It's OK on my machine.
>>
>>       Usually I run `gradlew clean bootstrapJar --no-build-cache` before
>> running tests via IDEA.
>>
>>       Good luck.
>>
>> Cheers,
>> Daniel.Sun
>>
>>
>>
>> --
>> Sent from: http://groovy.329449.n5.nabble.com/Groovy-Dev-f372993.html
>>
>

Re: Troubles with IDEA setup

Posted by Cédric Champeau <ce...@gmail.com>.
No luck, I'm still stuck :(

Le mar. 22 mai 2018 à 21:23, Daniel.Sun <su...@apache.org> a écrit :

> Hi Cédric,
>
>       It's OK on my machine.
>
>       Usually I run `gradlew clean bootstrapJar --no-build-cache` before
> running tests via IDEA.
>
>       Good luck.
>
> Cheers,
> Daniel.Sun
>
>
>
> --
> Sent from: http://groovy.329449.n5.nabble.com/Groovy-Dev-f372993.html
>

Re: Troubles with IDEA setup

Posted by "Daniel.Sun" <su...@apache.org>.
Hi Cédric,

      It's OK on my machine.

      Usually I run `gradlew clean bootstrapJar --no-build-cache` before
running tests via IDEA.

      Good luck.

Cheers,
Daniel.Sun



--
Sent from: http://groovy.329449.n5.nabble.com/Groovy-Dev-f372993.html

Re: Troubles with IDEA setup

Posted by Keegan Witt <ke...@gmail.com>.
I'm with Russel: I've seen some flakiness with Gradle Idea plugin.  On my
current client's project I actually saw Gradle Idea plugin add the wrong
version of a dependency to the project, but IntelliJ's import chose the
version that was mentioned in the Gradle file.  That did it for me -- I
permanently distrust Gradle Idea plugin now.

On Wed, May 23, 2018 at 7:33 AM, Cédric Champeau <ce...@gmail.com>
wrote:

> Thanks for checking, Marcin. For reference, stub generation takes long but
> passes. It's really the semantic analysis which gets stuck somehow.
>
> Le mer. 23 mai 2018 à 13:32, Marcin Erdmann <ma...@proxerd.pl> a
> écrit :
>
>> Cedric,
>>
>> I've just pulled master then I got rid of all idea config files and build
>> direcotries to start with a clean state:
>>
>> rm groovy.i*
>> find . -name "*.iml" -type f | xargs rm -f
>> ./gradlew clean
>>
>> Then I run the same command as you:
>> ./gradlew jar idea --rerun-tasks
>>
>> Finally I opened the project in IntelliJ and tried rebuilding it (Build >
>> Rebuild project). The fan is spinning like crazy, CPU usage is high and it
>> seems to be stuck on "Groovy stub generator: initialization [tests of
>> groovy-xml and 8 more]". After then killing the IDE and trying to
>> run DownUpStepTest I'm seeing the same symptoms as you are - stuck in
>> "Groovyc: semantic analysis [tests of groovy-xml and 8 more]" with CPU is
>> not busy.
>>
>> For reference, I'm using IntelliJ 2018.1 181.4203.550.
>>
>> On Tue, May 22, 2018 at 8:02 PM, Cédric Champeau <
>> cedric.champeau@gmail.com> wrote:
>>
>>> Hi team,
>>>
>>> I've been trying to figure out what is happening for hours now, but I
>>> cannot find any reason. I'm working on master, after removing all IDEA
>>> state (.iml, .ipr, .iws), regenerating the IDEA files using:
>>>
>>> ./gradlew jar idea --rerun-tasks
>>>
>>> And then I open the project in IDEA and try to run a unit test. But then
>>> the IDE is stuck in "Groovyc: semantic analysis [tests of groovy-xml and 8
>>> more]". CPU is not busy, nothing happens.
>>>
>>> I thought it could be a CPU issue, so I increased the memory for the
>>> IDEA compiler process, without success.
>>>
>>> Any idea what could be going on? Am I the only one seeing this?
>>>
>>>
>>

Re: Troubles with IDEA setup

Posted by Jochen Theodorou <bl...@gmx.org>.

Am 30.05.2018 um 02:03 schrieb Daniel.Sun:
> Only happens in non-windows OS?
> 
> P.S. My OS is Win10 too

maybe. I just made an experiment... jvisualvm suggested me idea is not 
getting enough memory, so I gave it 5G (for testing) and suddenly idea 
is done in about 2 minutes and without causing 100% load on all cores. 
Probably it is enough to have 1.5G, but the 750M or so, that are the 
default seem not to be enough anymore. This could be either the plugin 
requiring more memory or us.... and there either the Groovy compiler 
itself, or the stub generator.

bye Jochen

Re: Troubles with IDEA setup

Posted by "Daniel.Sun" <su...@apache.org>.
Only happens in non-windows OS?

P.S. My OS is Win10 too

Cheers,
Daniel.Sun




--
Sent from: http://groovy.329449.n5.nabble.com/Groovy-Dev-f372993.html

Re: Troubles with IDEA setup

Posted by Remko Popma <re...@gmail.com>.
I cannot reproduce this problem on my Windows 10 laptop...


On Wed, May 30, 2018 at 8:43 Jochen Theodorou <bl...@gmx.org> wrote:

>
>
> Am 23.05.2018 um 13:33 schrieb Cédric Champeau:
> > Thanks for checking, Marcin. For reference, stub generation takes long
> > but passes. It's really the semantic analysis which gets stuck somehow.
>
> I assume nobody did try to really find the reason for this yet? It is
> really a major annoyance, and this is new (compare to April). At least
> on my machine
>
> bye Jochen
>

Re: Troubles with IDEA setup

Posted by Jochen Theodorou <bl...@gmx.org>.

Am 23.05.2018 um 13:33 schrieb Cédric Champeau:
> Thanks for checking, Marcin. For reference, stub generation takes long 
> but passes. It's really the semantic analysis which gets stuck somehow.

I assume nobody did try to really find the reason for this yet? It is 
really a major annoyance, and this is new (compare to April). At least 
on my machine

bye Jochen

Re: Troubles with IDEA setup

Posted by Cédric Champeau <ce...@gmail.com>.
Thanks for checking, Marcin. For reference, stub generation takes long but
passes. It's really the semantic analysis which gets stuck somehow.

Le mer. 23 mai 2018 à 13:32, Marcin Erdmann <ma...@proxerd.pl> a
écrit :

> Cedric,
>
> I've just pulled master then I got rid of all idea config files and build
> direcotries to start with a clean state:
>
> rm groovy.i*
> find . -name "*.iml" -type f | xargs rm -f
> ./gradlew clean
>
> Then I run the same command as you:
> ./gradlew jar idea --rerun-tasks
>
> Finally I opened the project in IntelliJ and tried rebuilding it (Build >
> Rebuild project). The fan is spinning like crazy, CPU usage is high and it
> seems to be stuck on "Groovy stub generator: initialization [tests of
> groovy-xml and 8 more]". After then killing the IDE and trying to
> run DownUpStepTest I'm seeing the same symptoms as you are - stuck in
> "Groovyc: semantic analysis [tests of groovy-xml and 8 more]" with CPU is
> not busy.
>
> For reference, I'm using IntelliJ 2018.1 181.4203.550.
>
> On Tue, May 22, 2018 at 8:02 PM, Cédric Champeau <
> cedric.champeau@gmail.com> wrote:
>
>> Hi team,
>>
>> I've been trying to figure out what is happening for hours now, but I
>> cannot find any reason. I'm working on master, after removing all IDEA
>> state (.iml, .ipr, .iws), regenerating the IDEA files using:
>>
>> ./gradlew jar idea --rerun-tasks
>>
>> And then I open the project in IDEA and try to run a unit test. But then
>> the IDE is stuck in "Groovyc: semantic analysis [tests of groovy-xml and 8
>> more]". CPU is not busy, nothing happens.
>>
>> I thought it could be a CPU issue, so I increased the memory for the IDEA
>> compiler process, without success.
>>
>> Any idea what could be going on? Am I the only one seeing this?
>>
>>
>

Re: Troubles with IDEA setup

Posted by Marcin Erdmann <ma...@proxerd.pl>.
Cedric,

I've just pulled master then I got rid of all idea config files and build
direcotries to start with a clean state:

rm groovy.i*
find . -name "*.iml" -type f | xargs rm -f
./gradlew clean

Then I run the same command as you:
./gradlew jar idea --rerun-tasks

Finally I opened the project in IntelliJ and tried rebuilding it (Build >
Rebuild project). The fan is spinning like crazy, CPU usage is high and it
seems to be stuck on "Groovy stub generator: initialization [tests of
groovy-xml and 8 more]". After then killing the IDE and trying to
run DownUpStepTest I'm seeing the same symptoms as you are - stuck in
"Groovyc: semantic analysis [tests of groovy-xml and 8 more]" with CPU is
not busy.

For reference, I'm using IntelliJ 2018.1 181.4203.550.

On Tue, May 22, 2018 at 8:02 PM, Cédric Champeau <ce...@gmail.com>
wrote:

> Hi team,
>
> I've been trying to figure out what is happening for hours now, but I
> cannot find any reason. I'm working on master, after removing all IDEA
> state (.iml, .ipr, .iws), regenerating the IDEA files using:
>
> ./gradlew jar idea --rerun-tasks
>
> And then I open the project in IDEA and try to run a unit test. But then
> the IDE is stuck in "Groovyc: semantic analysis [tests of groovy-xml and 8
> more]". CPU is not busy, nothing happens.
>
> I thought it could be a CPU issue, so I increased the memory for the IDEA
> compiler process, without success.
>
> Any idea what could be going on? Am I the only one seeing this?
>
>