deltachat / deltachat-core-rust

Delta Chat Rust Core library, used by Android/iOS/desktop apps, bindings and bots 📧
https://delta.chat/en/contribute
Other
657 stars 83 forks source link

Test `test_qr_verified_group_and_chatting` is flaky #4227

Open link2xt opened 1 year ago

link2xt commented 1 year ago

Run: https://github.com/deltachat/deltachat-core-rust/actions/runs/4513199072/jobs/7947708420?pr=4226

link2xt commented 1 year ago

Saved the log: actionlog.txt

ac1 creates a QR code, ac3 scans it. ac1 sends vc-auth-required and goes to IDLE. ac3 sends vc-request-with-auth, but ac1 never receives it and is stuck forever in IDLE.

link2xt commented 1 year ago

More failures: https://github.com/deltachat/deltachat-core-rust/actions/runs/4518739718/jobs/7958802553 (checked, exactly same problem as above) https://github.com/deltachat/deltachat-core-rust/actions/runs/4518739718/jobs/7958802627 (checked, exactly the same bug) https://github.com/deltachat/deltachat-core-rust/actions/runs/4518739718/jobs/7958802670 (here another problem, ac2 went into IDLE and never received message about ac1 adding ac3 to the group; in addition to that, test_multidevice_sync_seen failed, there ac3 (clone of ac1) went into IDLE and never received a message from ac2, while ac1 received it)

iequidoo commented 1 year ago

Btw, all failures where ac1 doesn't awake from IDLE happen when the test is running slowly, vs-request-with-auth is sent at ~130 s:

130.88 [events-ac3] INFO src/mimefactory.rs:1027: sending secure-join message 'vc-request-with-auth' >>>>>>>>>>>>>>>>>>>>>>>>>
iequidoo commented 1 year ago

Here we can see that even after restarting IO (after 5 seconds of waiting in IDLE) there is

43.97 [events-ac1] INFO src/imap.rs:719: No new emails in folder INBOX

and then

49.75 [events-ac1] INFO src/imap/idle.rs:74: INBOX: Idle has NewData ResponseData { raw: 4096, response: MailboxData(Exists(4)) }

so i think the problem isn't in IDLE. Looks like messages are delivered not fast enough