Skip to content

IDEA hangs during test generation #1207

Description

@tyuldashev

Description

I've faced the problem that IDEA becomes not responsible during several test generations with the latest RC builds. While it's most probably caused by insufficient memory allocated to IDEA, UTBot test generation should not cause hang of IDEA without ability to cancel test generation process.

To Reproduce

Most of the times I've faced that problem after the following steps:

  1. Open UTBot project
  2. Generate tests for org.utbot.examples.algorithms.Sort

Expected behavior

Tests are generated

Actual behavior

Test generation started but in a about a minute IDEA stops to respond to user interaction. Once it finished generation in about 17min, but latter hanged again. Other times I killed IDEA after waiting for several minutes.

Visual proofs (screenshots, logs, images)

Thread dumps

Environment
IDEA 2022.1.4, with default -Xmx2022m in VM settings
UTBot - utbot-intellij-2022.10.459 - build from unittestbot/rc10192022

Additional information
Increasing IDEA memory to 4Gb seems resolves the problem. But I believe UTBot still should not cause hangs in IDEA and still be cancelable.

Activity

  1. alisevych commented on Oct 21, 2022

    @alisevych
    Member

    Additional details

    Same happened to me once - on other version - newest IDEA 2022.2.3 - and with build from next release candidate branch.
    UTBot - utbot-intellij-2022.10.464 - build from unittestbot/rc10202022
    IDE hanged after test generation had already finished - and some imports and build project were being made.
    It hanged for about 16 hours and only kill process helped.

  2. tyuldashev commented on Oct 24, 2022

    @tyuldashev
    CollaboratorAuthor

    That seems caused by #1225. If we try to open such file in IDEA it would warn that this file is too big and would skip formatting and analyzing it. We may implement similar or the same check, to prevent such problem.

  3. tyuldashev commented on Oct 27, 2022

    @tyuldashev
    CollaboratorAuthor

    Tested with build from main branch #483
    IDEA 2022.1.4 & 2022.2.3

  4. Repository owner moved this from Todo to Done in UTBot Javaon Oct 27, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions