Triage Flaky test nothingAppearsInAppBarIfAllAppBarButtonsAreDisabled
Flaky test - seen it three times now, always windows runner. I think it needs a little triage (maybe there is something there? windows runners are for instance sometimes slower so it may be exposing a timing issue?) but then should be marked flaky as it impedes velocity
ReviewerTest > [SchedV1] > nothingAppearsInAppBarIfAllAppBarButtonsAreDisabled[SchedV1] FAILED
net.ankiweb.rsdroid.exceptions.BackendInvalidInputException$BackendCollectionAlreadyOpenException: CollectionAlreadyOpen
at net.ankiweb.rsdroid.exceptions.BackendInvalidInputException$Companion.fromInvalidInputError(BackendInvalidInputException.kt:34)
at net.ankiweb.rsdroid.BackendException$Companion.fromError(BackendException.kt:114)
at net.ankiweb.rsdroid.BackendKt.unpackResult(Backend.kt:323)
at net.ankiweb.rsdroid.BackendKt.access$unpackResult(Backend.kt:1)
at net.ankiweb.rsdroid.Backend$runMethodRaw$1.invoke(Backend.kt:130)
at net.ankiweb.rsdroid.Backend$runMethodRaw$1.invoke(Backend.kt:129)
at net.ankiweb.rsdroid.Backend.withBackend(Backend.kt:157)
at net.ankiweb.rsdroid.Backend.runMethodRaw(Backend.kt:129)
at anki.backend.GeneratedBackend.openCollectionRaw(GeneratedBackend.kt:26)
at anki.backend.GeneratedBackend.openCollection(GeneratedBackend.kt:39)
at net.ankiweb.rsdroid.Backend.openCollection(Backend.kt:109)
at net.ankiweb.rsdroid.Backend.openCollection(Backend.kt:61)
at com.ichi2.libanki.Storage.openDB$AnkiDroid_playDebug(Storage.kt:107)
at com.ichi2.libanki.Collection.reopen(Collection.kt:452)
at com.ichi2.libanki.Collection.reopen$default(Collection.kt:449)
at com.ichi2.libanki.Collection.<init>(Collection.kt:[195](https://github.com/ankidroid/Anki-Android/actions/runs/5985079816/job/16236820765?pr=14306#step:10:196))
at com.ichi2.libanki.Storage.collection(Storage.kt:89)
at com.ichi2.anki.CollectionManager.ensureOpenInner(CollectionManager.kt:229)
at com.ichi2.anki.CollectionManager.access$ensureOpenInner(CollectionManager.kt:40)
at com.ichi2.anki.CollectionManager$getColUnsafe$1$1.invoke(CollectionManager.kt:281)
at com.ichi2.anki.CollectionManager$getColUnsafe$1$1.invoke(CollectionManager.kt:280)
at com.ichi2.anki.CollectionManager.blockForQueue(CollectionManager.kt:260)
at com.ichi2.anki.CollectionManager.access$blockForQueue(CollectionManager.kt:40)
at com.ichi2.anki.CollectionManager$getColUnsafe$1.invoke(CollectionManager.kt:280)
at com.ichi2.anki.CollectionManager$getColUnsafe$1.invoke(CollectionManager.kt:279)
at com.ichi2.anki.CollectionManager.logUIHangs(CollectionManager.kt:296)
at com.ichi2.anki.CollectionManager.getColUnsafe(CollectionManager.kt:279)
at com.ichi2.anki.CollectionHelper.getCol(CollectionHelper.kt:78)
at com.ichi2.anki.RobolectricTest.getCol(RobolectricTest.kt:357)
at com.ichi2.anki.ReviewerTest.setUp(ReviewerTest.kt:59)
Originally posted by @mikehardy in https://github.com/ankidroid/Anki-Android/issues/14306#issuecomment-1694348647
Hello 👋, this issue has been opened for more than 3 months with no activity on it. If the issue is still here, please keep in mind that we need community support and help to fix it! Just comment something like still searching for solutions and if you found one, please open a pull request! You have 7 days until this gets closed automatically
Hello, I am interested in solving this issue.
Step 1: Determine if the test is still flaky
- Fork AnkiDroid
- Clone
- Make a new Branch
- Remove the 'Flaky' annotation from the test
-
Recommended: modify
tests_unit.ymlso only the flaky test is executed -
Optional: use
runTest(times)so the test is executed more than once per run
-
Recommended: modify
- Push the branch
- Go to GitHub actions on your fork (Actions tab, should look like):
- https://github.com/ankidroid/Anki-Android/actions/
- Pick "Unit Tests" in the sidebar
- "Run Workflow" on your branch until you get a failure of the test
- If you can't reproduce it after a reasonable number of runs, let us know
Screenshot: GitHub Actions - Unit Tests - Run Workflow
reference: runTest(times)
https://github.com/ankidroid/Anki-Android/blob/65c9f9197ef31e223e5ced4950c366883c94205b/AnkiDroid/src/test/java/com/ichi2/testutils/TestClass.kt#L201-L206
is someone working on this?
The bug can still be reproduced [summary of Discord thread], don't know if @Venkatesh2507 is still working on it
There was a conversation on Discord: https://discord.com/channels/368267295601983490/1199718488512663652
@GautamCoder4019k If you don't get a reply within 24 hours, ping me and feel free to work on it. I'm a little snowed under, but I'll aim to assign you. Feel free to work on it without being assigned
@Venkatesh2507 are u still working on this issue?
Yes I am working on this
Hello 👋, this issue has been opened for more than 3 months with no activity on it. If the issue is still here, please keep in mind that we need community support and help to fix it! Just comment something like still searching for solutions and if you found one, please open a pull request! You have 7 days until this gets closed automatically