UnitTestBot / UnitTestBot/usvm

JcMachine failed with IllegalStateException: Unexpected type

Open
#120 1 comment 0 reactions 1 assignee View on GitHub

@Damtev is already working on this.

Since Nov 22, 2023.

bug
Dominant language
Kotlin
Stars
33
Forks
27
Avg merge
4d 3h
Merged PRs (30d)
15

Description

Consider the following tests generation scenario:

timeLimit = 120
methodFilter = "com.google.common.net.MediaType.*"
projectFilter = listOf("guava")

The following exception can be found in logs

JcMachine failed
java.lang.IllegalStateException: Unexpected type: org.jacodb.impl.types.JcTypeVariableImpl@5a0c610b
	at org.usvm.util.JcMethodUtilsKt.findMethod(JcMethodUtils.kt:30) ~[usvm-jvm-comp-231118-1620.jar:?]
	at org.usvm.machine.interpreter.JcVirtualInvokeResolverKt$makeConcreteCallsForPossibleTypes$1$block$1.invoke(JcVirtualInvokeResolver.kt:281) ~[usvm-jvm-comp-231118-1620.jar:?]
	at org.usvm.machine.interpreter.JcVirtualInvokeResolverKt$makeConcreteCallsForPossibleTypes$1$block$1.invoke(JcVirtualInvokeResolver.kt:280) ~[usvm-jvm-comp-231118-1620.jar:?]
	at org.usvm.StepScope.forkMulti(StepScope.kt:117) ~[usvm-core-comp-231118-1620.jar:?]
	at org.usvm.machine.interpreter.JcVirtualInvokeResolverKt.resolveVirtualInvokeWithModel(JcVirtualInvokeResolver.kt:110) ~[usvm-jvm-comp-231118-1620.jar:?]
	at org.usvm.machine.interpreter.JcVirtualInvokeResolverKt.resolveVirtualInvoke(JcVirtualInvokeResolver.kt:53) ~[usvm-jvm-comp-231118-1620.jar:?]
	at org.usvm.machine.interpreter.JcInterpreter.resolveVirtualInvoke(JcInterpreter.kt:581) ~[usvm-jvm-comp-231118-1620.jar:?]
	at org.usvm.machine.interpreter.JcInterpreter.visitMethodCall(JcInterpreter.kt:269) ~[usvm-jvm-comp-231118-1620.jar:?]
	at org.usvm.machine.interpreter.JcInterpreter.step(JcInterpreter.kt:158) ~[usvm-jvm-comp-231118-1620.jar:?]
	at org.usvm.machine.interpreter.JcInterpreter.step(JcInterpreter.kt:82) ~[usvm-jvm-comp-231118-1620.jar:?]
	at org.usvm.UMachine.run(Machine.kt:40) ~[usvm-core-comp-231118-1620.jar:?]
	at org.usvm.machine.JcMachine.analyze(JcMachine.kt:148) ~[usvm-jvm-comp-231118-1620.jar:?]
	at org.usvm.machine.JcMachine.analyze$default(JcMachine.kt:53) ~[usvm-jvm-comp-231118-1620.jar:?]
	at org.utbot.contest.usvm.ContestUsvmKt$runUsvmGeneration$1$9$8$states$2$1.invoke(ContestUsvm.kt:184) ~[main/:?]
	at org.utbot.common.ThreadBasedExecutor$invokeWithTimeout$1.invoke(ThreadUtil.kt:70) ~[utbot-core-2023.11-SNAPSHOT.jar:?]
	at org.utbot.common.ThreadBasedExecutor$ensureThreadIsAlive$1.invoke(ThreadUtil.kt:124) ~[utbot-core-2023.11-SNAPSHOT.jar:?]
	at org.utbot.common.ThreadBasedExecutor$ensureThreadIsAlive$1.invoke(ThreadUtil.kt:120) ~[utbot-core-2023.11-SNAPSHOT.jar:?]
	at kotlin.concurrent.ThreadsKt$thread$thread$1.run(Thread.kt:30) ~[kotlin-stdlib-1.8.22.jar:1.8.22-release-407(1.8.22)]

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.