Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Chat view performance improvements #10711

Merged
merged 2 commits into from
Jun 1, 2020

Conversation

cammellos
Copy link
Contributor

@cammellos cammellos commented May 25, 2020

Improve chat loading performance

This commit does a few things:

Move collections top level

Move messages,message-lists,pagination-info from nested in
chats to top level at the db.
The reason for this change is that if any of the messages fields
change, any sub that relies on chat will be recomputed, which is
unnecessary.

Move chat-name to events

chat-name was computed dynamically, while it is now only calculated
when loading chat the first time around.

Remove enrich-chats

Enrich chats was doing a lot of work, and many subscriptions were
relying on it.
Not all the computations were necessary, for example it would always
calculate the name of who invited the user to a group chat, regardless
of whether it was actually used in the view.
This commit changes that behavior so that we use smaller subscriptions
to calculate such fields.
In general we should move computations to events, if that's not
desirable (there are some cases where we might not want to do that), we
should have "bottom/leaf heavy" subscriptions as opposed to "top heavy",
especially if they are to be shared, so only when (and if) we load that
particular view, the subscription is triggered, while others can be
re-used.

I have compared performance with current release, and there's a
noticeable difference. Opening a chat is faster (messages are loaded
faster), and clicking on the home view on a chat is more responsing
(the animation on-press is much quicker).

Sorry for the big PR but changing one thing lead to another. I can split it off for easier reviewing if necessary.

I have left subscriptions names as they are, using raw for those that do not do any calculation or don't fallback on defaults, probably it would be good to revisit to have a consistent naming, I would also separate subs.cljs in multiple files (under a single directory), subs/chats.cljs subs/contacts.cljs etc , as sometimes is difficult to find what can be re-used (or any other scheme is good), but that's for a separate PR pending discussion.

Testing

No functional changes, just performance improvement. Performance can be tested if necessary, I have included a video that shows the difference, mind as well that current develop parses markdown so it does a bit more, but pr seems to be faster despite of that.
Areas that are impacted is main chat view, chat view mostly.
Receiving messages is also faster it looks (significantly), although haven't looked much into it as wasn't optimizing that particular part.

release
pr

status: ready

@cammellos cammellos requested a review from a team as a code owner May 25, 2020 14:50
@status-im-auto
Copy link
Member

status-im-auto commented May 25, 2020

Jenkins Builds

Click to see older builds (52)
Commit #️⃣ Finished (UTC) Duration Platform Result
17febbf #1 2020-05-25 14:52:09 ~1 min ios 📄log
9b3d210 #2 2020-05-25 15:09:29 ~11 min android 📄log
9b3d210 #2 2020-05-25 15:09:37 ~12 min android-e2e 📄log
9b3d210 #2 2020-05-25 15:11:22 ~13 min ios 📄log
6e65a59 #3 2020-05-25 15:30:37 ~14 min ios 📄log
6e65a59 #3 2020-05-25 15:30:55 ~14 min android-e2e 📄log
6e65a59 #3 2020-05-25 15:31:11 ~14 min android 📄log
✔️ 5e2d40c #4 2020-05-25 15:51:08 ~10 min android-e2e 📦apk 📲
✔️ 5e2d40c #4 2020-05-25 15:54:54 ~14 min ios 📦ipa 📲
✔️ 5e2d40c #4 2020-05-25 15:56:57 ~16 min android 📦apk 📲
3026a9c #5 2020-05-26 12:46:30 ~13 min android-e2e 📄log
3026a9c #5 2020-05-26 12:46:40 ~13 min android 📄log
3026a9c #5 2020-05-26 12:46:55 ~13 min ios 📄log
a17acde #6 2020-05-26 13:43:09 ~13 min android-e2e 📄log
a17acde #6 2020-05-26 13:43:10 ~13 min android 📄log
a17acde #6 2020-05-26 13:43:22 ~14 min ios 📄log
7112a6e #7 2020-05-26 13:54:06 ~1 min ios 📄log
✔️ f4d13c2 #8 2020-05-26 14:13:57 ~10 min android-e2e 📦apk 📲
✔️ f4d13c2 #8 2020-05-26 14:15:08 ~11 min android 📦apk 📲
✔️ f4d13c2 #8 2020-05-26 14:17:27 ~14 min ios 📦ipa 📲
✔️ 008f526 #9 2020-05-26 16:35:25 ~14 min ios 📦ipa 📲
✔️ 008f526 #9 2020-05-26 16:36:48 ~15 min android-e2e 📦apk 📲
✔️ 008f526 #9 2020-05-26 16:37:00 ~15 min android 📦apk 📲
✔️ b980fe3 #10 2020-05-27 07:15:31 ~10 min android-e2e 📦apk 📲
✔️ b980fe3 #10 2020-05-27 07:17:43 ~12 min android 📦apk 📲
✔️ b980fe3 #10 2020-05-27 07:19:33 ~14 min ios 📦ipa 📲
ff4a8d7 #11 2020-05-27 10:21:56 ~14 min ios 📄log
ff4a8d7 #11 2020-05-27 10:22:31 ~14 min android-e2e 📄log
ff4a8d7 #11 2020-05-27 10:22:33 ~14 min android 📄log
✔️ 18df765 #12 2020-05-27 10:46:47 ~14 min ios 📦ipa 📲
✔️ 18df765 #12 2020-05-27 10:47:30 ~15 min android-e2e 📦apk 📲
✔️ 18df765 #12 2020-05-27 10:47:43 ~15 min android 📦apk 📲
8ed1fc2 #13 2020-05-27 11:06:15 ~2 min ios 📄log
✔️ 3b6e719 #15 2020-05-27 11:26:02 ~14 min ios 📦ipa 📲
✔️ 3b6e719 #15 2020-05-27 11:28:43 ~17 min android-e2e 📦apk 📲
✔️ 3b6e719 #15 2020-05-27 11:28:58 ~17 min android 📦apk 📲
✔️ 3deff23 #16 2020-05-27 12:58:23 ~11 min android 📦apk 📲
✔️ 3deff23 #16 2020-05-27 12:59:24 ~12 min android-e2e 📦apk 📲
✔️ 3deff23 #16 2020-05-27 13:01:17 ~14 min ios 📦ipa 📲
✔️ 8a8b885 #17 2020-05-27 14:54:41 ~15 min ios 📦ipa 📲
✔️ 8a8b885 #17 2020-05-27 14:54:48 ~15 min android-e2e 📦apk 📲
✔️ 8a8b885 #17 2020-05-27 14:55:21 ~16 min android 📦apk 📲
b2e54c6 #18 2020-05-28 07:40:22 ~2 min ios 📄log
b2e54c6 #18 2020-05-28 07:53:22 ~15 min android-e2e 📄log
b2e54c6 #18 2020-05-28 07:53:29 ~15 min android 📄log
36630da #19 2020-05-28 09:08:55 ~2 min ios 📄log
443066f #20 2020-05-28 09:20:18 ~11 min android-e2e 📄log
443066f #20 2020-05-28 09:21:57 ~12 min android 📄log
443066f #20 2020-05-28 09:24:19 ~15 min ios 📄log
✔️ 8d6942b #21 2020-05-29 07:34:58 ~10 min android-e2e 📦apk 📲
✔️ 8d6942b #21 2020-05-29 07:38:02 ~13 min android 📦apk 📲
✔️ 8d6942b #21 2020-05-29 07:39:20 ~14 min ios 📦ipa 📲
Commit #️⃣ Finished (UTC) Duration Platform Result
e3971fa #22 2020-06-01 10:07:29 ~16 min android-e2e 📄log
e3971fa #22 2020-06-01 10:07:31 ~16 min android 📄log
e3971fa #22 2020-06-01 10:09:16 ~17 min ios 📄log
✔️ 9ee526f #23 2020-06-01 10:24:13 ~14 min android-e2e 📦apk 📲
✔️ 9ee526f #23 2020-06-01 10:24:17 ~14 min android 📦apk 📲
✔️ 9ee526f #23 2020-06-01 10:24:31 ~14 min ios 📦ipa 📲

@cammellos cammellos force-pushed the chore/move-messages-on-own-collection branch from 17febbf to 9b3d210 Compare May 25, 2020 14:57
@status-im-auto
Copy link
Member

64% of end-end tests have passed

Total executed tests: 76
Failed tests: 27
Passed tests: 49

Failed tests (27)

Click to expand
1. test_decline_transactions_in_1_1_chat
No host specified.; also Unexpected Alert is shown: 'Your phone appears to be ROOTED, by pressing CONTINUE you understand and accept the risks in using this software.'

2. test_delete_chats_via_delete_button

Device 1: Looking for an element by text part: 'YouTube'
Device 1: Wait for OkButton

E http.client.RemoteDisconnected: Remote end closed connection without response

During handling of the above exception, another exception occurred:
('Connection aborted.', RemoteDisconnected('Remote end closed connection without response',)); also Une


Device sessions

3. test_install_pack_and_send_sticker
No host specified.

4. test_login_with_new_account

Device 1: Wait for PrivacyAndSecurityButton
Device 1: DefaultUserNameText is Earnest Revolving Annelida

E http.client.RemoteDisconnected: Remote end closed connection without response

During handling of the above exception, another exception occurred:
('Connection aborted.', RemoteDisconnected('Remote end closed connection without response',))


Device sessions

5. test_timestamp_in_chats

Device 1: Looking for a message by text: 'test text'
Device 1: Wait for MemberPhoto

Timestamp is not displayed in 1-1 chat for the recipient

Device sessions

6. test_need_help_section

Device 1: Wait for WebViewBrowserButton
Device 1: Wait for AlwaysButton

E http.client.RemoteDisconnected: Remote end closed connection without response

During handling of the above exception, another exception occurred:
('Connection aborted.', RemoteDisconnected('Remote end closed connection without response',))


Device sessions

7. test_send_and_open_links
No host specified.

8. test_create_new_group_chat
No host specified.

9. test_add_to_contacts
No host specified.

10. test_can_add_existing_ens

Device 1: check that after adding username is shown in "ENS usernames" and profile
Device 1: Looking for an element by text: 'statuse2e'

Device 1: 'BackButton' is not found on the screen; also Unexpected Alert is shown: 'Cannot convert undefined value to object'

Device sessions

11. test_public_chat_messaging
No host specified.

12. test_text_message_1_1_chat

Device 2: Wait for ChatMessageInput
Device 2: Looking for a message by text: 'hello'

Device 2: 'ChatElementByText' is not found on the screen

Device sessions

13. test_offline_add_new_group_chat_member
No host specified.

14. test_pair_devices_sync_one_to_one_contacts_public_chat
No host specified.

15. test_send_non_english_message_to_newly_added_contact

Device 1: Type '® æ ç ♥' to ChatMessageInput
Device 1: Tap on SendMessageButton

Device 2: 'ChatElement' is not found on the screen

Device sessions

16. test_switch_users_and_add_new_account

Device 1: Type 'qwerty' to ConfirmYourPasswordInput
Device 1: Tap on NextButton

Device 1: 'LetsGoButton' is not found on the screen

Device sessions

17. test_copy_contact_code_and_wallet_address

Device 1: Looking for ChatElement
Device 1: Wait for ConnectionStatusText

E http.client.RemoteDisconnected: Remote end closed connection without response

During handling of the above exception, another exception occurred:
('Connection aborted.', RemoteDisconnected('Remote end closed connection without response',))


Device sessions

18. test_message_marked_as_sent_in_1_1_chat
No host specified.

19. test_add_new_keycard_account_and_login

Device 1: Tap on OnePinKeyboardButton
Device 1: Tap on TwoPinKeyboardButton

E http.client.RemoteDisconnected: Remote end closed connection without response

During handling of the above exception, another exception occurred:
('Connection aborted.', RemoteDisconnected('Remote end closed connection without response',))


Device sessions

20. test_dapps_permissions

Device 1: Type 'qwerty' to ConfirmYourPasswordInput
Device 1: Tap on NextButton

E http.client.RemoteDisconnected: Remote end closed connection without response

During handling of the above exception, another exception occurred:
('Connection aborted.', RemoteDisconnected('Remote end closed connection without response',))


Device sessions

21. test_log_level_and_fleet

Device 1: Looking for an element by text part: 'Messages'
Device 1: Looking for an element by text part: 'YouTube'

E http.client.RemoteDisconnected: Remote end closed connection without response

During handling of the above exception, another exception occurred:
('Connection aborted.', RemoteDisconnected('Remote end closed connection without response',)); also Une


Device sessions

22. test_send_eth_in_1_1_chat
No host specified.

23. test_ens_in_public_and_1_1_chats
No host specified.; also Unexpected Alert is shown: 'Your phone appears to be ROOTED, by pressing CONTINUE you understand and accept the risks in using this software.'

24. test_block_user_from_public_chat
No host specified.

25. test_offline_messaging_1_1_chat
No host specified.

26. test_request_and_receive_stt_in_1_1_chat_offline

Device 2: Wait for OkButton
Device 2: Wait for ContinueButton

Device 1: 'ChatElement' is not found on the screen

Device sessions

27. test_messaging_in_different_networks
Sauce could not start your job. For more information on what happened, please visit https://app.saucelabs.com/tests/e048c2776b5d45339ed1ea2ab1e511c6

Passed tests (49)

Click to expand
1. test_can_see_all_transactions_in_history
Device sessions

2. test_logcat_recovering_account
Device sessions

3. test_public_chat_clear_history
Device sessions

4. test_mobile_data_usage_popup_stop_syncing
Device sessions

5. test_mobile_data_usage_settings
Device sessions

6. test_sign_typed_message (TestRail link is not found)
Device sessions

7. test_user_can_switch_network
Device sessions

8. test_mobile_data_usage_popup_continue_syncing
Device sessions

9. test_home_view
Device sessions

10. test_open_google_com_via_open_dapp
Device sessions

11. test_share_contact_code_and_wallet_address
Device sessions

12. test_refresh_button_browsing_app_webview
Device sessions

13. test_keycard_send_two_transactions_one_after_another_in_dapp
Device sessions

14. test_transaction_wrong_password_wallet
Device sessions

15. test_unread_messages_counter_public_chat
Device sessions

16. test_keycard_send_eth_from_wallet_to_address
Device sessions

17. test_keycard_fetching_balance_after_offline
Device sessions

18. test_keycard_send_transaction_from_daap
Device sessions

19. test_open_transaction_on_etherscan
Device sessions

20. test_onboarding_screen_when_requesting_tokens_for_recovered_account
Device sessions

21. test_contact_profile_view
Device sessions

22. test_logcat_backup_recovery_phrase
Device sessions

23. test_add_and_remove_contact_from_public_chat
Device sessions

24. test_add_account_to_multiaccount_instance_seed_phrase
Device sessions

25. test_keycard_sign_message_from_daap
Device sessions

26. test_ens_username_recipient
Device sessions

27. test_token_with_more_than_allowed_decimals
Device sessions

28. test_open_public_chat_using_deep_link
Device sessions

29. test_add_account_to_multiaccount_instance_generate_new
Device sessions

30. test_send_transaction_from_daap
Device sessions

31. test_send_two_transactions_one_after_another_in_dapp
Device sessions

32. test_back_forward_buttons_browsing_website
Device sessions

33. test_password_in_logcat_creating_account
Device sessions

34. test_sign_message_from_daap
Device sessions

35. test_request_public_key_status_test_daap
Device sessions

36. test_recover_account_from_new_user_seedphrase (TestRail link is not found)
Device sessions

37. test_send_transaction_with_custom_token
Device sessions

38. test_send_two_transactions_in_batch_in_dapp
Device sessions

39. test_fetching_balance_after_offline
Device sessions

40. test_account_recovery_with_uppercase_recovery_phrase
Device sessions

41. test_send_token_with_7_decimals
Device sessions

42. test_keycard_can_see_all_transactions_in_history
Device sessions

43. test_keycard_send_two_transactions_in_batch_in_dapp
Device sessions

44. test_send_emoji
Device sessions

45. test_filters_from_daap
Device sessions

46. test_restore_account_from_mnemonic_to_keycard
Device sessions

47. test_send_eth_to_ens_in_chat
Device sessions

48. test_send_eth_from_wallet_to_address
Device sessions

49. test_insufficient_funds_wallet_positive_balance
Device sessions

@cammellos cammellos force-pushed the chore/move-messages-on-own-collection branch from f4d13c2 to 008f526 Compare May 26, 2020 16:21
@status-im-auto
Copy link
Member

51% of end-end tests have passed

Total executed tests: 70
Failed tests: 34
Passed tests: 36

Failed tests (34)

Click to expand
1. test_decline_transactions_in_1_1_chat
No host specified.; also Unexpected Alert is shown: 'Your phone appears to be ROOTED, by pressing CONTINUE you understand and accept the risks in using this software.'

2. test_delete_chats_via_delete_button

Device 1: =========================================================================
Device 1: Sending message to Royal Defensive Solenodon chat

Device 1: 'ChatMessageInput' is not found on the screen

Device sessions

3. test_can_see_all_transactions_in_history

Device 1: DetailsTextElement is 0xc039f82eceda458b63a0f327b7b0c20def5903d7
Device 1: Tap on BackButton

E http.client.RemoteDisconnected: Remote end closed connection without response

During handling of the above exception, another exception occurred:
('Connection aborted.', RemoteDisconnected('Remote end closed connection without response',))


Device sessions

4. test_install_pack_and_send_sticker
Sauce could not start your job. For more information on what happened, please visit https://app.saucelabs.com/tests/6c808a1441914380904b034fb379de8a; also Unexpected Alert is shown: 'Your phone appears to be ROOTED, by pressing CONTINUE you understand an

5. test_timestamp_in_chats
No host specified.

6. test_public_chat_clear_history
No host specified.

7. test_send_and_open_links
No host specified.

8. test_mobile_data_usage_popup_stop_syncing

Device 1: Looking for an element by text part: 'YouTube'
Device 1: Wait for OkButton

E http.client.RemoteDisconnected: Remote end closed connection without response

During handling of the above exception, another exception occurred:
('Connection aborted.', RemoteDisconnected('Remote end closed connection without response',)); also Une


Device sessions

9. test_mobile_data_usage_settings

Device 1: Tap on GetStartedButton
Device 1: Tap on GenerateKeyButton

E http.client.RemoteDisconnected: Remote end closed connection without response

During handling of the above exception, another exception occurred:
('Connection aborted.', RemoteDisconnected('Remote end closed connection without response',))


Device sessions

10. test_create_new_group_chat
No host specified.

11. test_sign_typed_message (TestRail link is not found)

Device 1: Type 'qwerty' to ConfirmYourPasswordInput
Device 1: Wait for LetsGoButton

E http.client.RemoteDisconnected: Remote end closed connection without response

During handling of the above exception, another exception occurred:
('Connection aborted.', RemoteDisconnected('Remote end closed connection without response',))


Device sessions

12. test_share_contact_code_and_wallet_address

Device 1: Tap on ContinueButton
Device 1: Wait for OkButton

E http.client.RemoteDisconnected: Remote end closed connection without response

During handling of the above exception, another exception occurred:
('Connection aborted.', RemoteDisconnected('Remote end closed connection without response',))


Device sessions

13. test_add_to_contacts

Device 2: Tap on HomeButton
Device 2: Wait for PlusButton

E http.client.RemoteDisconnected: Remote end closed connection without response

During handling of the above exception, another exception occurred:
('Connection aborted.', RemoteDisconnected('Remote end closed connection without response',))


Device sessions

14. test_can_add_existing_ens

Device 1: Tap on MultiAccountOnLoginButton
Device 1: Type 'qwerty' to PasswordInput

E http.client.RemoteDisconnected: Remote end closed connection without response

During handling of the above exception, another exception occurred:
('Connection aborted.', RemoteDisconnected('Remote end closed connection without response',))


Device sessions

15. test_public_chat_messaging
No host specified.; also Unexpected Alert is shown: 'Your phone appears to be ROOTED, by pressing CONTINUE you understand and accept the risks in using this software.'

16. test_unread_messages_counter_public_chat
No host specified.

17. test_text_message_1_1_chat
No host specified.

18. test_offline_add_new_group_chat_member
No host specified.

19. test_add_and_remove_contact_from_public_chat
No host specified.

20. test_open_chat_by_pasting_public_key

Device 1: Wait for PlusButton
Device 1: Wait for ChatElement

Device 1: No chat open in home view

Device sessions

21. test_pair_devices_sync_one_to_one_contacts_public_chat
No host specified.

22. test_send_non_english_message_to_newly_added_contact
HTTPConnectionPool(host='66.85.49.22', port=80): Max retries exceeded with url: http://anton-status:0a8c5013-d483-4872-a894-9b62d6391892@66.85.49.22:80/wd/hub/session/3e68e219a7a940c88d1ccf7472974007?ref=2c0e937046be4a5b902e656d3a6c293c (Caused by Respon

23. test_add_account_to_multiaccount_instance_generate_new

Device 1: Type 'qwerty' to ConfirmYourPasswordInput
Device 1: Tap on NextButton

E http.client.RemoteDisconnected: Remote end closed connection without response

During handling of the above exception, another exception occurred:
('Connection aborted.', RemoteDisconnected('Remote end closed connection without response',))


Device sessions

24. test_long_press_to_delete_chat

Device 1: Wait for ConnectionStatusText
Device 1: Wait for ConnectionStatusText

E http.client.RemoteDisconnected: Remote end closed connection without response

During handling of the above exception, another exception occurred:
('Connection aborted.', RemoteDisconnected('Remote end closed connection without response',))


Device sessions

25. test_log_level_and_fleet

Device 1: Wait for LetsGoButton
Device 1: Wait for PrivacyAndSecurityButton

E http.client.RemoteDisconnected: Remote end closed connection without response

During handling of the above exception, another exception occurred:
('Connection aborted.', RemoteDisconnected('Remote end closed connection without response',))


Device sessions

26. test_recover_account_from_new_user_seedphrase (TestRail link is not found)

Device 1: Wait for OkButton
Device 1: Wait for ContinueButton

E http.client.RemoteDisconnected: Remote end closed connection without response

During handling of the above exception, another exception occurred:
('Connection aborted.', RemoteDisconnected('Remote end closed connection without response',))


Device sessions

27. test_send_eth_in_1_1_chat
No host specified.

28. test_ens_in_public_and_1_1_chats
No host specified.

29. test_block_user_from_public_chat
No host specified.

30. test_offline_messaging_1_1_chat

Device 1: Tap on AirplaneModeButton
Device 1: Looking for an element by text part: 'MmsService'

Device 1: 'ChatElement' is not found on the screen

Device sessions

31. test_user_can_see_all_own_assets_after_account_recovering

Device 1: Wait for OkButton
Device 1: Wait for ContinueButton

E http.client.RemoteDisconnected: Remote end closed connection without response

During handling of the above exception, another exception occurred:
('Connection aborted.', RemoteDisconnected('Remote end closed connection without response',))


Device sessions

32. test_keycard_can_see_all_transactions_in_history

Device 1: Tap on NextButton
Device 1: Tap on BeginSetupButton

E http.client.RemoteDisconnected: Remote end closed connection without response

During handling of the above exception, another exception occurred:
('Connection aborted.', RemoteDisconnected('Remote end closed connection without response',))


Device sessions

33. test_request_and_receive_stt_in_1_1_chat_offline

Device 2: Wait for OkButton
Device 2: Wait for ContinueButton

Device 1: 'ChatElement' is not found on the screen

Device sessions

34. test_messaging_in_different_networks
No host specified.

Passed tests (36)

Click to expand
1. test_logcat_recovering_account
Device sessions

2. test_need_help_section
Device sessions

3. test_user_can_switch_network
Device sessions

4. test_mobile_data_usage_popup_continue_syncing
Device sessions

5. test_home_view
Device sessions

6. test_open_google_com_via_open_dapp
Device sessions

7. test_connection_is_secure
Device sessions

8. test_refresh_button_browsing_app_webview
Device sessions

9. test_transaction_wrong_password_wallet
Device sessions

10. test_keycard_send_transaction_from_daap
Device sessions

11. test_can_use_purchased_stickers_on_recovered_account
Device sessions

12. test_open_transaction_on_etherscan
Device sessions

13. test_onboarding_screen_when_requesting_tokens_for_recovered_account
Device sessions

14. test_contact_profile_view
Device sessions

15. test_logcat_backup_recovery_phrase
Device sessions

16. test_add_account_to_multiaccount_instance_seed_phrase
Device sessions

17. test_keycard_sign_message_from_daap
Device sessions

18. test_ens_username_recipient
Device sessions

19. test_token_with_more_than_allowed_decimals
Device sessions

20. test_fetch_more_history_in_empty_chat
Device sessions

21. test_switch_users_and_add_new_account
Device sessions

22. test_message_marked_as_sent_in_1_1_chat
Device sessions

23. test_add_new_keycard_account_and_login
Device sessions

24. test_long_press_delete_clear_all_dapps
Device sessions

25. test_copy_and_paste_messages
Device sessions

26. test_password_in_logcat_creating_account
Device sessions

27. test_sign_message_from_daap
Device sessions

28. test_dapps_permissions
Device sessions

29. test_send_transaction_with_custom_token
Device sessions

30. test_wallet_set_up
Device sessions

31. test_manage_assets
Device sessions

32. test_account_recovery_with_uppercase_recovery_phrase
Device sessions

33. test_keycard_send_two_transactions_in_batch_in_dapp
Device sessions

34. test_send_eth_to_ens_in_chat
Device sessions

35. test_collectible_from_wallet_opens_in_browser_view
Device sessions

36. test_insufficient_funds_wallet_positive_balance
Device sessions

@status-im-auto
Copy link
Member

79% of end-end tests have passed

Total executed tests: 95
Failed tests: 20
Passed tests: 75

Failed tests (20)

Click to expand
1. test_decline_transactions_in_1_1_chat

Device 2: Wait for ChatMessageInput
Device 2: Looking for a message by text: '↓ Incoming transaction'

Device 2: 'DeclineTransaction' is not found on the screen

Device sessions

2. test_delete_chats_via_delete_button

Device 1: =========================================================================
Device 1: Sending message to Royal Defensive Solenodon chat

Device 1: 'ChatMessageInput' is not found on the screen

Device sessions

3. test_install_pack_and_send_sticker

Device 2: Looking for an element by text part: 'Status Cat'
Device 2: Looking for an element by text part: 'Free'

Device 2: 'BaseButton' is not found on the screen

Device sessions

4. test_timestamp_in_chats

Device 1: Looking for a message by text: 'test text'
Device 1: Wait for MemberPhoto

Timestamp is not displayed in 1-1 chat for the recipient

Device sessions

5. test_send_and_open_links

Device 2: Wait for ChatMessageInput
Device 2: Looking for full text: 'http://status.im'

Device 2: 'BaseButton' is not found on the screen

Device sessions

6. test_add_to_contacts

Device 1: Type 'hello' to ChatMessageInput
Device 1: Tap on SendMessageButton

Device 2: 'ChatElement' is not found on the screen

Device sessions

7. test_can_add_existing_ens

Device 1: check that after adding username is shown in "ENS usernames" and profile
Device 1: Looking for an element by text: 'statuse2e'

Device 1: 'BackButton' is not found on the screen; also Unexpected Alert is shown: 'Cannot convert undefined value to object'

Device sessions

8. test_text_message_1_1_chat

Device 2: Wait for ChatMessageInput
Device 2: Looking for a message by text: 'hello'

Device 2: 'ChatElementByText' is not found on the screen

Device sessions

9. test_offline_add_new_group_chat_member

Device 3: Looking for an element by text part: 'MmsService'
Device 1: Tap on ChatMenuButton

Device 1: 'GroupInfoButton' is not found on the screen; also Unexpected Alert is shown: 'No protocol method IDeref.-deref defined for type undefined: '

Device sessions

10. test_open_chat_by_pasting_public_key

Device 1: Wait for PlusButton
Device 1: Wait for ChatElement

Device 1: No chat open in home view

Device sessions

11. test_pair_devices_sync_one_to_one_contacts_public_chat

Device 1: Wait for ConnectionStatusText
Device 1: Wait for ChatMessageInput

Device 1: 'ChatMessageInput' is not found on the screen

Device sessions

12. test_keycard_sign_message_from_daap

Device 1: =========================================================================
Device 1: Check logcat for sensitive data

Device 1: ['Password in logcat!!!']

Device sessions

13. test_send_non_english_message_to_newly_added_contact

Device 1: Type '® æ ç ♥' to ChatMessageInput
Device 1: Tap on SendMessageButton

Device 2: 'ChatElement' is not found on the screen

Device sessions

14. test_copy_contact_code_and_wallet_address

Device 1: Wait for ConnectionStatusText
Device 1: Wait for ChatMessageInput

Device 1: 'ChatMessageInput' is not found on the screen

Device sessions

15. test_long_press_to_delete_chat

Device 1: =========================================================================
Device 1: Sending message to Royal Defensive Solenodon chat

Device 1: 'ChatMessageInput' is not found on the screen

Device sessions

16. test_send_eth_in_1_1_chat
E http.client.RemoteDisconnected: Remote end closed connection without response

During handling of the above exception, another exception occurred:
('Connection aborted.', RemoteDisconnected('Remote end closed connection without response',))


17. test_ens_in_public_and_1_1_chats

Device 1: check ENS name wallet address and public key
Device 1: Looking for an element by text: 'statuse2e'

Device 1: 'BaseButton' is not found on the screen; also Unexpected Alert is shown: 'Cannot convert undefined value to object'

Device sessions

18. test_offline_messaging_1_1_chat

Device 1: Tap on AirplaneModeButton
Device 1: Looking for an element by text part: 'MmsService'

Device 1: 'ChatElement' is not found on the screen

Device sessions

19. test_request_and_receive_stt_in_1_1_chat_offline

Device 2: Wait for OkButton
Device 2: Wait for ContinueButton

Device 1: 'ChatElement' is not found on the screen

Device sessions

20. test_messaging_in_different_networks

Device 2: Wait for ChatMessageInput
Device 2: Looking for a message by text: 'test message'

Device 2: 'ChatElementByText' is not found on the screen

Device sessions

Passed tests (75)

Click to expand
1. test_can_see_all_transactions_in_history
Device sessions

2. test_login_with_new_account
Device sessions

3. test_password_in_logcat_sign_in
Device sessions

4. test_logcat_recovering_account
Device sessions

5. test_public_chat_clear_history
Device sessions

6. test_need_help_section
Device sessions

7. test_mobile_data_usage_popup_stop_syncing
Device sessions

8. test_mobile_data_usage_settings
Device sessions

9. test_create_new_group_chat
Device sessions

10. test_sign_typed_message (TestRail link is not found)
Device sessions

11. test_user_can_switch_network
Device sessions

12. test_mobile_data_usage_popup_continue_syncing
Device sessions

13. test_home_view
Device sessions

14. test_open_google_com_via_open_dapp
Device sessions

15. test_share_contact_code_and_wallet_address
Device sessions

16. test_connection_is_secure
Device sessions

17. test_add_account_to_multiaccount_instance_private_key
Device sessions

18. test_refresh_button_browsing_app_webview
Device sessions

19. test_keycard_send_two_transactions_one_after_another_in_dapp
Device sessions

20. test_transaction_wrong_password_wallet
Device sessions

21. test_public_chat_messaging
Device sessions

22. test_unread_messages_counter_public_chat
Device sessions

23. test_keycard_send_eth_from_wallet_to_address
Device sessions

24. test_keycard_fetching_balance_after_offline
Device sessions

25. test_keycard_send_transaction_from_daap
Device sessions

26. test_can_use_purchased_stickers_on_recovered_account
Device sessions

27. test_open_transaction_on_etherscan
Device sessions

28. test_onboarding_screen_when_requesting_tokens_for_recovered_account
Device sessions

29. test_contact_profile_view
Device sessions

30. test_logcat_backup_recovery_phrase
Device sessions

31. test_start_chat_with_ens
Device sessions

32. test_add_and_remove_contact_from_public_chat
Device sessions

33. test_add_account_to_multiaccount_instance_seed_phrase
Device sessions

34. test_open_blocked_site
Device sessions

35. test_ens_username_recipient
Device sessions

36. test_token_with_more_than_allowed_decimals
Device sessions

37. test_fetch_more_history_in_empty_chat
Device sessions

38. test_open_public_chat_using_deep_link
Device sessions

39. test_switch_users_and_add_new_account
Device sessions

40. test_add_account_to_multiaccount_instance_generate_new
Device sessions

41. test_send_transaction_from_daap
Device sessions

42. test_send_two_transactions_one_after_another_in_dapp
Device sessions

43. test_message_marked_as_sent_in_1_1_chat
Device sessions

44. test_add_new_keycard_account_and_login
Device sessions

45. test_long_press_delete_clear_all_dapps
Device sessions

46. test_copy_and_paste_messages
Device sessions

47. test_back_forward_buttons_browsing_website
Device sessions

48. test_password_in_logcat_creating_account
Device sessions

49. test_sign_message_from_daap
Device sessions

50. test_dapps_permissions
Device sessions

51. test_request_public_key_status_test_daap
Device sessions

52. test_log_level_and_fleet
Device sessions

53. test_add_and_delete_watch_only_account_to_multiaccount_instance
Device sessions

54. test_recover_account_from_new_user_seedphrase (TestRail link is not found)
Device sessions

55. test_send_transaction_with_custom_token
Device sessions

56. test_send_two_transactions_in_batch_in_dapp
Device sessions

57. test_block_user_from_public_chat
Device sessions

58. test_fetching_balance_after_offline
Device sessions

59. test_offline_status
Device sessions

60. test_wallet_set_up
Device sessions

61. test_manage_assets
Device sessions

62. test_account_recovery_with_uppercase_recovery_phrase
Device sessions

63. test_send_token_with_7_decimals
Device sessions

64. test_user_can_see_all_own_assets_after_account_recovering
Device sessions

65. test_pass_phrase_validation
Device sessions

66. test_keycard_can_see_all_transactions_in_history
Device sessions

67. test_keycard_send_two_transactions_in_batch_in_dapp
Device sessions

68. test_send_emoji
Device sessions

69. test_filters_from_daap
Device sessions

70. test_redirect_to_public_chat_tapping_tag_message
Device sessions

71. test_restore_account_from_mnemonic_to_keycard
Device sessions

72. test_send_eth_to_ens_in_chat
Device sessions

73. test_send_eth_from_wallet_to_address
Device sessions

74. test_collectible_from_wallet_opens_in_browser_view
Device sessions

75. test_insufficient_funds_wallet_positive_balance
Device sessions

@status-im-auto
Copy link
Member

93% of end-end tests have passed

Total executed tests: 94
Failed tests: 7
Passed tests: 87

Failed tests (7)

Click to expand
1. test_delete_chats_via_delete_button

Device 1: Deleting group chat
Device 1: Tap on ChatMenuButton

Device 1: 'LeaveChatButton' is not found on the screen; also Unexpected Alert is shown: 'No protocol method IDeref.-deref defined for type undefined: '

Device sessions

2. test_open_google_com_via_open_dapp

Device 1: Looking for an element by text part: 'Messages'

E http.client.RemoteDisconnected: Remote end closed connection without response

During handling of the above exception, another exception occurred:
('Connection aborted.', RemoteDisconnected('Remote end closed connection without response',)); also Une


Device sessions

3. test_can_add_existing_ens

Device 1: check that after adding username is shown in "ENS usernames" and profile
Device 1: Looking for an element by text: 'statuse2e'

Device 1: 'BackButton' is not found on the screen; also Unexpected Alert is shown: 'Cannot convert undefined value to object'

Device sessions

4. test_offline_add_new_group_chat_member

Device 3: Looking for an element by text part: 'MmsService'
Device 1: Tap on ChatMenuButton

Device 1: 'GroupInfoButton' is not found on the screen; also Unexpected Alert is shown: 'No protocol method IDeref.-deref defined for type undefined: '

Device sessions

5. test_long_press_to_delete_chat

Device 1: Looking for ChatElement
Device 1: Long press ChatElement

Device 1: 'LeaveChatButton' is not found on the screen; also Unexpected Alert is shown: 'No protocol method IDeref.-deref defined for type undefined: '

Device sessions

6. test_ens_in_public_and_1_1_chats

Device 1: check ENS name wallet address and public key
Device 1: Looking for an element by text: 'statuse2e'

Device 1: 'BaseButton' is not found on the screen; also Unexpected Alert is shown: 'Cannot convert undefined value to object'

Device sessions

7. test_request_and_receive_stt_in_1_1_chat_offline
E http.client.RemoteDisconnected: Remote end closed connection without response

During handling of the above exception, another exception occurred:
('Connection aborted.', RemoteDisconnected('Remote end closed connection without response',))


Passed tests (87)

Click to expand
1. test_decline_transactions_in_1_1_chat
Device sessions

2. test_can_see_all_transactions_in_history
Device sessions

3. test_install_pack_and_send_sticker
Device sessions

4. test_login_with_new_account
Device sessions

5. test_timestamp_in_chats
Device sessions

6. test_password_in_logcat_sign_in
Device sessions

7. test_logcat_recovering_account
Device sessions

8. test_public_chat_clear_history
Device sessions

9. test_need_help_section
Device sessions

10. test_send_and_open_links
Device sessions

11. test_mobile_data_usage_popup_stop_syncing
Device sessions

12. test_mobile_data_usage_settings
Device sessions

13. test_create_new_group_chat
Device sessions

14. test_sign_typed_message (TestRail link is not found)
Device sessions

15. test_user_can_switch_network
Device sessions

16. test_mobile_data_usage_popup_continue_syncing
Device sessions

17. test_home_view
Device sessions

18. test_share_contact_code_and_wallet_address
Device sessions

19. test_connection_is_secure
Device sessions

20. test_add_to_contacts
Device sessions

21. test_add_account_to_multiaccount_instance_private_key
Device sessions

22. test_refresh_button_browsing_app_webview
Device sessions

23. test_keycard_send_two_transactions_one_after_another_in_dapp
Device sessions

24. test_transaction_wrong_password_wallet
Device sessions

25. test_public_chat_messaging
Device sessions

26. test_unread_messages_counter_public_chat
Device sessions

27. test_keycard_send_eth_from_wallet_to_address
Device sessions

28. test_keycard_fetching_balance_after_offline
Device sessions

29. test_keycard_send_transaction_from_daap
Device sessions

30. test_text_message_1_1_chat
Device sessions

31. test_can_use_purchased_stickers_on_recovered_account
Device sessions

32. test_open_transaction_on_etherscan
Device sessions

33. test_onboarding_screen_when_requesting_tokens_for_recovered_account
Device sessions

34. test_contact_profile_view
Device sessions

35. test_logcat_backup_recovery_phrase
Device sessions

36. test_start_chat_with_ens
Device sessions

37. test_add_and_remove_contact_from_public_chat
Device sessions

38. test_add_account_to_multiaccount_instance_seed_phrase
Device sessions

39. test_open_blocked_site
Device sessions

40. test_open_chat_by_pasting_public_key
Device sessions

41. test_pair_devices_sync_one_to_one_contacts_public_chat
Device sessions

42. test_keycard_sign_message_from_daap
Device sessions

43. test_send_non_english_message_to_newly_added_contact
Device sessions

44. test_ens_username_recipient
Device sessions

45. test_token_with_more_than_allowed_decimals
Device sessions

46. test_fetch_more_history_in_empty_chat
Device sessions

47. test_open_public_chat_using_deep_link
Device sessions

48. test_switch_users_and_add_new_account
Device sessions

49. test_add_account_to_multiaccount_instance_generate_new
Device sessions

50. test_copy_contact_code_and_wallet_address
Device sessions

51. test_send_transaction_from_daap
Device sessions

52. test_send_two_transactions_one_after_another_in_dapp
Device sessions

53. test_message_marked_as_sent_in_1_1_chat
Device sessions

54. test_add_new_keycard_account_and_login
Device sessions

55. test_long_press_delete_clear_all_dapps
Device sessions

56. test_copy_and_paste_messages
Device sessions

57. test_back_forward_buttons_browsing_website
Device sessions

58. test_password_in_logcat_creating_account
Device sessions

59. test_sign_message_from_daap
Device sessions

60. test_request_public_key_status_test_daap
Device sessions

61. test_log_level_and_fleet
Device sessions

62. test_add_and_delete_watch_only_account_to_multiaccount_instance
Device sessions

63. test_recover_account_from_new_user_seedphrase (TestRail link is not found)
Device sessions

64. test_send_transaction_with_custom_token
Device sessions

65. test_send_eth_in_1_1_chat
Device sessions

66. test_send_two_transactions_in_batch_in_dapp
Device sessions

67. test_block_user_from_public_chat
Device sessions

68. test_fetching_balance_after_offline
Device sessions

69. test_offline_status
Device sessions

70. test_wallet_set_up
Device sessions

71. test_manage_assets
Device sessions

72. test_offline_messaging_1_1_chat
Device sessions

73. test_account_recovery_with_uppercase_recovery_phrase
Device sessions

74. test_send_token_with_7_decimals
Device sessions

75. test_user_can_see_all_own_assets_after_account_recovering
Device sessions

76. test_pass_phrase_validation
Device sessions

77. test_keycard_can_see_all_transactions_in_history
Device sessions

78. test_keycard_send_two_transactions_in_batch_in_dapp
Device sessions

79. test_send_emoji
Device sessions

80. test_filters_from_daap
Device sessions

81. test_redirect_to_public_chat_tapping_tag_message
Device sessions

82. test_restore_account_from_mnemonic_to_keycard
Device sessions

83. test_send_eth_to_ens_in_chat
Device sessions

84. test_send_eth_from_wallet_to_address
Device sessions

85. test_messaging_in_different_networks
Device sessions

86. test_collectible_from_wallet_opens_in_browser_view
Device sessions

87. test_insufficient_funds_wallet_positive_balance
Device sessions

@status-im-auto
Copy link
Member

89% of end-end tests have passed

Total executed tests: 84
Failed tests: 9
Passed tests: 75

Failed tests (9)

Click to expand
1. test_decline_transactions_in_1_1_chat

Device 2: TransactionStatus is Transaction declined
Device 1: TransactionStatus is Transaction declined

Wrong state is shown: "Transaction declined" is expected, in fact Address requested

Device sessions

2. test_create_new_group_chat
No host specified.; also Unexpected Alert is shown: 'Your phone appears to be ROOTED, by pressing CONTINUE you understand and accept the risks in using this software.'

3. test_unread_messages_counter_public_chat
No host specified.; also Unexpected Alert is shown: 'Your phone appears to be ROOTED, by pressing CONTINUE you understand and accept the risks in using this software.'

4. test_send_transaction_with_custom_token

Device 1: Scrolling down to LogoutButton
Device 1: Scrolling down to LogoutButton

Device 1: 'LogoutButton' is not found on the screen

Device sessions

5. test_send_eth_in_1_1_chat
No host specified.

6. test_block_user_from_public_chat
No host specified.

7. test_offline_messaging_1_1_chat
No host specified.

8. test_request_and_receive_stt_in_1_1_chat_offline
No host specified.; also Unexpected Alert is shown: 'Your phone appears to be ROOTED, by pressing CONTINUE you understand and accept the risks in using this software.'

9. test_messaging_in_different_networks
No host specified.; also Unexpected Alert is shown: 'Your phone appears to be ROOTED, by pressing CONTINUE you understand and accept the risks in using this software.'

Passed tests (75)

Click to expand
1. test_delete_chats_via_delete_button
Device sessions

2. test_install_pack_and_send_sticker
Device sessions

3. test_login_with_new_account
Device sessions

4. test_timestamp_in_chats
Device sessions

5. test_password_in_logcat_sign_in
Device sessions

6. test_logcat_recovering_account
Device sessions

7. test_public_chat_clear_history
Device sessions

8. test_need_help_section
Device sessions

9. test_send_and_open_links
Device sessions

10. test_mobile_data_usage_popup_stop_syncing
Device sessions

11. test_mobile_data_usage_settings
Device sessions

12. test_sign_typed_message (TestRail link is not found)
Device sessions

13. test_user_can_switch_network
Device sessions

14. test_mobile_data_usage_popup_continue_syncing
Device sessions

15. test_home_view
Device sessions

16. test_open_google_com_via_open_dapp
Device sessions

17. test_share_contact_code_and_wallet_address
Device sessions

18. test_add_to_contacts
Device sessions

19. test_refresh_button_browsing_app_webview
Device sessions

20. test_keycard_send_two_transactions_one_after_another_in_dapp
Device sessions

21. test_can_add_existing_ens
Device sessions

22. test_transaction_wrong_password_wallet
Device sessions

23. test_public_chat_messaging
Device sessions

24. test_keycard_send_eth_from_wallet_to_address
Device sessions

25. test_keycard_fetching_balance_after_offline
Device sessions

26. test_text_message_1_1_chat
Device sessions

27. test_can_use_purchased_stickers_on_recovered_account
Device sessions

28. test_open_transaction_on_etherscan
Device sessions

29. test_onboarding_screen_when_requesting_tokens_for_recovered_account
Device sessions

30. test_contact_profile_view
Device sessions

31. test_offline_add_new_group_chat_member
Device sessions

32. test_logcat_backup_recovery_phrase
Device sessions

33. test_start_chat_with_ens
Device sessions

34. test_add_and_remove_contact_from_public_chat
Device sessions

35. test_add_account_to_multiaccount_instance_seed_phrase
Device sessions

36. test_open_chat_by_pasting_public_key
Device sessions

37. test_pair_devices_sync_one_to_one_contacts_public_chat
Device sessions

38. test_keycard_sign_message_from_daap
Device sessions

39. test_send_non_english_message_to_newly_added_contact
Device sessions

40. test_ens_username_recipient
Device sessions

41. test_token_with_more_than_allowed_decimals
Device sessions

42. test_open_public_chat_using_deep_link
Device sessions

43. test_switch_users_and_add_new_account
Device sessions

44. test_add_account_to_multiaccount_instance_generate_new
Device sessions

45. test_copy_contact_code_and_wallet_address
Device sessions

46. test_send_transaction_from_daap
Device sessions

47. test_send_two_transactions_one_after_another_in_dapp
Device sessions

48. test_message_marked_as_sent_in_1_1_chat
Device sessions

49. test_add_new_keycard_account_and_login
Device sessions

50. test_copy_and_paste_messages
Device sessions

51. test_back_forward_buttons_browsing_website
Device sessions

52. test_password_in_logcat_creating_account
Device sessions

53. test_sign_message_from_daap
Device sessions

54. test_dapps_permissions
Device sessions

55. test_request_public_key_status_test_daap
Device sessions

56. test_long_press_to_delete_chat
Device sessions

57. test_log_level_and_fleet
Device sessions

58. test_add_and_delete_watch_only_account_to_multiaccount_instance
Device sessions

59. test_recover_account_from_new_user_seedphrase (TestRail link is not found)
Device sessions

60. test_send_two_transactions_in_batch_in_dapp
Device sessions

61. test_ens_in_public_and_1_1_chats
Device sessions

62. test_fetching_balance_after_offline
Device sessions

63. test_wallet_set_up
Device sessions

64. test_manage_assets
Device sessions

65. test_send_token_with_7_decimals
Device sessions

66. test_user_can_see_all_own_assets_after_account_recovering
Device sessions

67. test_keycard_can_see_all_transactions_in_history
Device sessions

68. test_keycard_send_two_transactions_in_batch_in_dapp
Device sessions

69. test_send_emoji
Device sessions

70. test_filters_from_daap
Device sessions

71. test_restore_account_from_mnemonic_to_keycard
Device sessions

72. test_send_eth_to_ens_in_chat
Device sessions

73. test_send_eth_from_wallet_to_address
Device sessions

74. test_collectible_from_wallet_opens_in_browser_view
Device sessions

75. test_insufficient_funds_wallet_positive_balance
Device sessions

@cammellos cammellos force-pushed the chore/move-messages-on-own-collection branch from 3deff23 to 8a8b885 Compare May 27, 2020 14:38
@cammellos cammellos changed the title [wip] Chore/move messages on own collection Chat view performance improvements May 27, 2020
@cammellos cammellos self-assigned this May 27, 2020
@status-im-auto
Copy link
Member

51% of end-end tests have passed

Total executed tests: 49
Failed tests: 24
Passed tests: 25

Failed tests (24)

Click to expand
1. test_decline_transactions_in_1_1_chat
No host specified.

2. test_install_pack_and_send_sticker
No host specified.

3. test_timestamp_in_chats
No host specified.

4. test_public_chat_clear_history
No host specified.

5. test_send_and_open_links
No host specified.

6. test_create_new_group_chat
No host specified.

7. test_user_can_switch_network

Device 1: Wait for OkButton
Device 1: Wait for ContinueButton

E http.client.RemoteDisconnected: Remote end closed connection without response

During handling of the above exception, another exception occurred:
('Connection aborted.', RemoteDisconnected('Remote end closed connection without response',)); also Une


Device sessions

8. test_home_view

Device 1: Looking for an element by text part: 'YouTube'
Device 1: Wait for OkButton

E http.client.RemoteDisconnected: Remote end closed connection without response

During handling of the above exception, another exception occurred:
('Connection aborted.', RemoteDisconnected('Remote end closed connection without response',))


Device sessions

9. test_add_to_contacts
No host specified.

10. test_public_chat_messaging
No host specified.

11. test_unread_messages_counter_public_chat
No host specified.

12. test_text_message_1_1_chat
No host specified.

13. test_contact_profile_view

Device 1: Looking for an element by text part: 'Messages'

E http.client.RemoteDisconnected: Remote end closed connection without response

During handling of the above exception, another exception occurred:
('Connection aborted.', RemoteDisconnected('Remote end closed connection without response',))


Device sessions

14. test_offline_add_new_group_chat_member
No host specified.

15. test_add_and_remove_contact_from_public_chat
No host specified.

16. test_open_chat_by_pasting_public_key

Device 1: Looking for an element by text part: 'Messages'

E http.client.RemoteDisconnected: Remote end closed connection without response

During handling of the above exception, another exception occurred:
('Connection aborted.', RemoteDisconnected('Remote end closed connection without response',)); also Une


Device sessions

17. test_pair_devices_sync_one_to_one_contacts_public_chat
No host specified.

18. test_send_non_english_message_to_newly_added_contact
No host specified.

19. test_message_marked_as_sent_in_1_1_chat
No host specified.

20. test_add_new_keycard_account_and_login

Device 1: StatusAccountTotalValueText is 0
Device 1: Wait for PrivacyAndSecurityButton

E http.client.RemoteDisconnected: Remote end closed connection without response

During handling of the above exception, another exception occurred:
('Connection aborted.', RemoteDisconnected('Remote end closed connection without response',))


Device sessions

21. test_recover_account_from_new_user_seedphrase (TestRail link is not found)

Device 1: Wait for ContinueButton
Device 1: Looking for an element by text part: 'Messages'

E http.client.RemoteDisconnected: Remote end closed connection without response

During handling of the above exception, another exception occurred:
('Connection aborted.', RemoteDisconnected('Remote end closed connection without response',)); also Une


Device sessions

22. test_block_user_from_public_chat
No host specified.

23. test_offline_messaging_1_1_chat
No host specified.

24. test_messaging_in_different_networks
No host specified.

Passed tests (25)

Click to expand
1. test_can_see_all_transactions_in_history
Device sessions

2. test_logcat_recovering_account
Device sessions

3. test_need_help_section
Device sessions

4. test_mobile_data_usage_popup_stop_syncing
Device sessions

5. test_mobile_data_usage_settings
Device sessions

6. test_mobile_data_usage_popup_continue_syncing
Device sessions

7. test_share_contact_code_and_wallet_address
Device sessions

8. test_can_add_existing_ens
Device sessions

9. test_keycard_send_eth_from_wallet_to_address
Device sessions

10. test_keycard_send_transaction_from_daap
Device sessions

11. test_open_transaction_on_etherscan
Device sessions

12. test_logcat_backup_recovery_phrase
Device sessions

13. test_switch_users_and_add_new_account
Device sessions

14. test_add_account_to_multiaccount_instance_generate_new
Device sessions

15. test_copy_contact_code_and_wallet_address
Device sessions

16. test_password_in_logcat_creating_account
Device sessions

17. test_dapps_permissions
Device sessions

18. test_log_level_and_fleet
Device sessions

19. test_send_transaction_with_custom_token
Device sessions

20. test_send_eth_in_1_1_chat
Device sessions

21. test_ens_in_public_and_1_1_chats
Device sessions

22. test_fetching_balance_after_offline
Device sessions

23. test_keycard_send_two_transactions_in_batch_in_dapp
Device sessions

24. test_restore_account_from_mnemonic_to_keycard
Device sessions

25. test_request_and_receive_stt_in_1_1_chat_offline
Device sessions

@status-im-auto
Copy link
Member

100% of end-end tests have passed

Total executed tests: 95
Failed tests: 0
Passed tests: 95

Passed tests (95)

Click to expand
1. test_request_public_key_status_test_daap
Device sessions

2. test_open_public_chat_using_deep_link
Device sessions

3. test_ens_username_recipient
Device sessions

4. test_keycard_can_see_all_transactions_in_history
Device sessions

5. test_offline_status
Device sessions

6. test_open_transaction_on_etherscan
Device sessions

7. test_open_chat_by_pasting_public_key
Device sessions

8. test_back_forward_buttons_browsing_website
Device sessions

9. test_password_in_logcat_creating_account
Device sessions

10. test_can_use_purchased_stickers_on_recovered_account
Device sessions

11. test_insufficient_funds_wallet_positive_balance
Device sessions

12. test_mobile_data_usage_settings
Device sessions

13. test_open_google_com_via_open_dapp
Device sessions

14. test_logcat_backup_recovery_phrase
Device sessions

15. test_unread_messages_counter_public_chat
Device sessions

16. test_send_two_transactions_one_after_another_in_dapp
Device sessions

17. test_message_marked_as_sent_in_1_1_chat
Device sessions

18. test_user_can_switch_network
Device sessions

19. test_public_chat_clear_history
Device sessions

20. test_wallet_set_up
Device sessions

21. test_timestamp_in_chats
Device sessions

22. test_delete_chats_via_delete_button
Device sessions

23. test_add_account_to_multiaccount_instance_seed_phrase
Device sessions

24. test_fetch_more_history_in_empty_chat
Device sessions

25. test_mobile_data_usage_popup_continue_syncing
Device sessions

26. test_keycard_fetching_balance_after_offline
Device sessions

27. test_add_to_contacts
Device sessions

28. test_dapps_permissions
Device sessions

29. test_long_press_delete_clear_all_dapps
Device sessions

30. test_need_help_section
Device sessions

31. test_transaction_wrong_password_wallet
Device sessions

32. test_offline_messaging_1_1_chat
Device sessions

33. test_token_with_more_than_allowed_decimals
Device sessions

34. test_add_account_to_multiaccount_instance_private_key
Device sessions

35. test_text_message_1_1_chat
Device sessions

36. test_install_pack_and_send_sticker
Device sessions

37. test_send_eth_in_1_1_chat
Device sessions

38. test_pair_devices_sync_one_to_one_contacts_public_chat
Device sessions

39. test_send_emoji
Device sessions

40. test_copy_and_paste_messages
Device sessions

41. test_restore_account_from_mnemonic_to_keycard
Device sessions

42. test_add_account_to_multiaccount_instance_generate_new
Device sessions

43. test_send_eth_from_wallet_to_address
Device sessions

44. test_messaging_in_different_networks
Device sessions

45. test_start_chat_with_ens
Device sessions

46. test_logcat_recovering_account
Device sessions

47. test_offline_add_new_group_chat_member
Device sessions

48. test_connection_is_secure
Device sessions

49. test_keycard_send_transaction_from_daap
Device sessions

50. test_user_can_see_all_own_assets_after_account_recovering
Device sessions

51. test_send_eth_to_ens_in_chat
Device sessions

52. test_keycard_sign_message_from_daap
Device sessions

53. test_long_press_to_delete_chat
Device sessions

54. test_add_and_remove_contact_from_public_chat
Device sessions

55. test_send_transaction_from_daap
Device sessions

56. test_onboarding_screen_when_requesting_tokens_for_recovered_account
Device sessions

57. test_keycard_send_eth_from_wallet_to_address
Device sessions

58. test_keycard_send_two_transactions_one_after_another_in_dapp
Device sessions

59. test_add_and_delete_watch_only_account_to_multiaccount_instance
Device sessions

60. test_open_blocked_site
Device sessions

61. test_refresh_button_browsing_app_webview
Device sessions

62. test_public_chat_messaging
Device sessions

63. test_pass_phrase_validation
Device sessions

64. test_send_token_with_7_decimals
Device sessions

65. test_sign_message_from_daap
Device sessions

66. test_recover_account_from_new_user_seedphrase (TestRail link is not found)
Device sessions

67. test_add_new_keycard_account_and_login
Device sessions

68. test_decline_transactions_in_1_1_chat
Device sessions

69. test_send_and_open_links
Device sessions

70. test_manage_assets
Device sessions

71. test_share_contact_code_and_wallet_address
Device sessions

72. test_send_transaction_with_custom_token
Device sessions

73. test_request_and_receive_stt_in_1_1_chat_offline
Device sessions

74. test_redirect_to_public_chat_tapping_tag_message
Device sessions

75. test_block_user_from_public_chat
Device sessions

76. test_ens_in_public_and_1_1_chats
Device sessions

77. test_sign_typed_message (TestRail link is not found)
Device sessions

78. test_create_new_group_chat
Device sessions

79. test_password_in_logcat_sign_in
Device sessions

80. test_account_recovery_with_uppercase_recovery_phrase
Device sessions

81. test_mobile_data_usage_popup_stop_syncing
Device sessions

82. test_send_non_english_message_to_newly_added_contact
Device sessions

83. test_collectible_from_wallet_opens_in_browser_view
Device sessions

84. test_contact_profile_view
Device sessions

85. test_keycard_send_two_transactions_in_batch_in_dapp
Device sessions

86. test_switch_users_and_add_new_account
Device sessions

87. test_send_two_transactions_in_batch_in_dapp
Device sessions

88. test_filters_from_daap
Device sessions

89. test_login_with_new_account
Device sessions

90. test_home_view
Device sessions

91. test_log_level_and_fleet
Device sessions

92. test_can_add_existing_ens
Device sessions

93. test_copy_contact_code_and_wallet_address
Device sessions

94. test_fetching_balance_after_offline
Device sessions

95. test_can_see_all_transactions_in_history
Device sessions

@@ -8,8 +8,6 @@
[status-im.ui.screens.chat.photos :as photos]
[status-im.utils.platform :as platform]))

;;TODO REWORK THIS NAMESPACE
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this still need to rework it :)

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

oh sorry, that was removed by mistake, generally all caps comment are the things I leave before commiting :)

@@ -38,13 +38,12 @@

(defview quoted-message
[_ {:keys [from text]} outgoing current-public-key]
(letsubs [{:keys [ens-name alias]} [:contacts/contact-name-by-identity from]]
(letsubs [contact-name [:contacts/contact-name-by-identity from]]
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

probably not in this PR but we should add this data to the message itself in the event, because of #10380

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would say it's even better to do not update the name when you on the chat view, and update it only next time you open chat, because 1- its rare case when this happens, 2 - we have 30s delay for verifications, so from performance and from ux it will be better to show it next time you open chat

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Most of the times though it does happen when you are in the chat view, think of the simplest case:

  1. Open #status
  2. Receive messages, no names, status-go verifies them
  3. Names are received

In such case I'd want to see a name as soon as it's available, not on reloading the chat?

We can though look at performance, my guess is that this is not the bottleneck, more likely is the actually building up the list (datemarks,timestamps etc)

:on-press #(hide-sheet-and-dispatch [:chat.ui/remove-chat-pressed chat-id])}]])
(defn one-to-one-chat-actions [{:keys [chat-id]}]
(let [photo @(re-frame/subscribe [:chats/photo-path chat-id])
contact-name @(re-frame/subscribe [:contacts/contact-name-by-identity chat-id])]
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

we know for sure these fields shouldn't change during this view is opened, so instead of creating and disposing of subscriptions we could use direct access to app-db probably in such cases , yeah i think we should consider this idea in general because in that case we will have less "noise" subscriptions, i mean such subscriptions which are run each time we change something but we know for sure result will be the same

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

some stuff is actually already denormalized, for example chat now has the photo (which never changes), I haven't yet used the denormalized version yet as I am not 100% sure it always has it, but I can change that in a separate PR (we can subscribe only if it's nil for example).

:title truncated-chat-name
:title (if group-chat
(utils/truncate-str chat-name 30)
@(re-frame/subscribe [:contacts/contact-name-by-identity chat-id]))
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

image

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

:D , this is tricky, I know it looks a bit funny, but I don't want to run the subscribe if it's not a one-to-one. If I pass a component it will be not applying the header style, so I am not sure what's another option.

@cammellos cammellos force-pushed the chore/move-messages-on-own-collection branch 2 times, most recently from 36630da to 443066f Compare May 28, 2020 09:08
@cammellos cammellos force-pushed the chore/move-messages-on-own-collection branch 2 times, most recently from 8d6942b to e3971fa Compare June 1, 2020 09:51
@cammellos cammellos force-pushed the chore/move-messages-on-own-collection branch from e3971fa to 9ee526f Compare June 1, 2020 10:09
@status-im-auto
Copy link
Member

99% of end-end tests have passed

Total executed tests: 95
Failed tests: 1
Passed tests: 94

Failed tests (1)

Click to expand
1. test_need_help_section

Device 1: Wait for AlwaysButton
Device 1: Looking for full text: 'Frequently Asked Questions'

Device 1: 'BaseElement' is not found on the screen

Device sessions

Passed tests (94)

Click to expand
1. test_decline_transactions_in_1_1_chat
Device sessions

2. test_delete_chats_via_delete_button
Device sessions

3. test_can_see_all_transactions_in_history
Device sessions

4. test_install_pack_and_send_sticker
Device sessions

5. test_login_with_new_account
Device sessions

6. test_timestamp_in_chats
Device sessions

7. test_password_in_logcat_sign_in
Device sessions

8. test_logcat_recovering_account
Device sessions

9. test_public_chat_clear_history
Device sessions

10. test_send_and_open_links
Device sessions

11. test_mobile_data_usage_popup_stop_syncing
Device sessions

12. test_mobile_data_usage_settings
Device sessions

13. test_create_new_group_chat
Device sessions

14. test_sign_typed_message (TestRail link is not found)
Device sessions

15. test_user_can_switch_network
Device sessions

16. test_mobile_data_usage_popup_continue_syncing
Device sessions

17. test_home_view
Device sessions

18. test_open_google_com_via_open_dapp
Device sessions

19. test_share_contact_code_and_wallet_address
Device sessions

20. test_connection_is_secure
Device sessions

21. test_add_to_contacts
Device sessions

22. test_add_account_to_multiaccount_instance_private_key
Device sessions

23. test_refresh_button_browsing_app_webview
Device sessions

24. test_keycard_send_two_transactions_one_after_another_in_dapp
Device sessions

25. test_can_add_existing_ens
Device sessions

26. test_transaction_wrong_password_wallet
Device sessions

27. test_public_chat_messaging
Device sessions

28. test_unread_messages_counter_public_chat
Device sessions

29. test_keycard_send_eth_from_wallet_to_address
Device sessions

30. test_keycard_fetching_balance_after_offline
Device sessions

31. test_keycard_send_transaction_from_daap
Device sessions

32. test_text_message_1_1_chat
Device sessions

33. test_can_use_purchased_stickers_on_recovered_account
Device sessions

34. test_open_transaction_on_etherscan
Device sessions

35. test_onboarding_screen_when_requesting_tokens_for_recovered_account
Device sessions

36. test_contact_profile_view
Device sessions

37. test_offline_add_new_group_chat_member
Device sessions

38. test_logcat_backup_recovery_phrase
Device sessions

39. test_start_chat_with_ens
Device sessions

40. test_add_and_remove_contact_from_public_chat
Device sessions

41. test_add_account_to_multiaccount_instance_seed_phrase
Device sessions

42. test_open_blocked_site
Device sessions

43. test_open_chat_by_pasting_public_key
Device sessions

44. test_pair_devices_sync_one_to_one_contacts_public_chat
Device sessions

45. test_keycard_sign_message_from_daap
Device sessions

46. test_send_non_english_message_to_newly_added_contact
Device sessions

47. test_ens_username_recipient
Device sessions

48. test_token_with_more_than_allowed_decimals
Device sessions

49. test_fetch_more_history_in_empty_chat
Device sessions

50. test_open_public_chat_using_deep_link
Device sessions

51. test_switch_users_and_add_new_account
Device sessions

52. test_add_account_to_multiaccount_instance_generate_new
Device sessions

53. test_copy_contact_code_and_wallet_address
Device sessions

54. test_send_transaction_from_daap
Device sessions

55. test_send_two_transactions_one_after_another_in_dapp
Device sessions

56. test_message_marked_as_sent_in_1_1_chat
Device sessions

57. test_add_new_keycard_account_and_login
Device sessions

58. test_long_press_delete_clear_all_dapps
Device sessions

59. test_copy_and_paste_messages
Device sessions

60. test_back_forward_buttons_browsing_website
Device sessions

61. test_password_in_logcat_creating_account
Device sessions

62. test_sign_message_from_daap
Device sessions

63. test_dapps_permissions
Device sessions

64. test_request_public_key_status_test_daap
Device sessions

65. test_long_press_to_delete_chat
Device sessions

66. test_log_level_and_fleet
Device sessions

67. test_add_and_delete_watch_only_account_to_multiaccount_instance
Device sessions

68. test_recover_account_from_new_user_seedphrase
Device sessions

69. test_send_transaction_with_custom_token
Device sessions

70. test_send_eth_in_1_1_chat
Device sessions

71. test_send_two_transactions_in_batch_in_dapp
Device sessions

72. test_ens_in_public_and_1_1_chats
Device sessions

73. test_block_user_from_public_chat
Device sessions

74. test_fetching_balance_after_offline
Device sessions

75. test_offline_status
Device sessions

76. test_wallet_set_up
Device sessions

77. test_manage_assets
Device sessions

78. test_offline_messaging_1_1_chat
Device sessions

79. test_account_recovery_with_uppercase_recovery_phrase
Device sessions

80. test_send_token_with_7_decimals
Device sessions

81. test_user_can_see_all_own_assets_after_account_recovering
Device sessions

82. test_pass_phrase_validation
Device sessions

83. test_keycard_can_see_all_transactions_in_history
Device sessions

84. test_keycard_send_two_transactions_in_batch_in_dapp
Device sessions

85. test_send_emoji
Device sessions

86. test_filters_from_daap
Device sessions

87. test_redirect_to_public_chat_tapping_tag_message
Device sessions

88. test_restore_account_from_mnemonic_to_keycard
Device sessions

89. test_send_eth_to_ens_in_chat
Device sessions

90. test_send_eth_from_wallet_to_address
Device sessions

91. test_request_and_receive_stt_in_1_1_chat_offline
Device sessions

92. test_messaging_in_different_networks
Device sessions

93. test_collectible_from_wallet_opens_in_browser_view
Device sessions

94. test_insufficient_funds_wallet_positive_balance
Device sessions

@churik
Copy link
Member

churik commented Jun 1, 2020

Tested on different types of chats: 1-1, public, group chats - big messages with markdown, links, emoji, stickers, Arabic / Chinese text
Rendering messages in public chats is working faster (5 sec vs 2.5 for history 01/06/20 in Status chat).
LOOKS AWESOME!

This commit does a few things:

Move collections top level

Move `messages`,`message-lists`,`pagination-info` from nested in
`chats` to top level at the db.
The reason for this change is that if any of the `messages` fields
change, any `sub` that relies on `chat` will be recomputed, which is
unnecessary.

Move chat-name to events

`chat-name` was computed dynamically, while it is now only calculated
when loading chat the first time around.

Remove `enrich-chats`

Enrich chats was doing a lot of work, and many subscriptions were
relying on it.
Not all the computations were necessary, for example it would always
calculate the name of who invited the user to a group chat, regardless
of whether it was actually used in the view.
This commit changes that behavior so that we use smaller subscriptions
to calculate such fields.
In general we should move computations to events, if that's not
desirable (there are some cases where we might not want to do that), we
should have "bottom/leaf heavy" subscriptions as opposed to "top heavy",
especially if they are to be shared, so only when (and if) we load that
particular view, the subscription is triggered, while others can be
re-used.

I have compared performance with current release, and there's a
noticeable difference. Opening a chat is faster (messages are loaded
faster), and clicking on the home view on a chat is more responsing
(the animation on-press is much quicker).
@cammellos cammellos force-pushed the chore/move-messages-on-own-collection branch from 9ee526f to 9d76913 Compare June 1, 2020 11:50
Signed-off-by: Andrea Maria Piana <andrea.maria.piana@gmail.com>
@cammellos cammellos merged commit 9d76913 into develop Jun 1, 2020
@cammellos cammellos deleted the chore/move-messages-on-own-collection branch June 1, 2020 11:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
No open projects
Archived in project
Development

Successfully merging this pull request may close these issues.

4 participants