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

fix(wallet): Fix input amount step skipped while sending a token #20852

Merged
merged 2 commits into from
Aug 2, 2024

Conversation

ulisesmac
Copy link
Contributor

fixes #20677

Summary

This PR fixes the step skipped. Demo:

Screencast.from.2024-07-22.14-24-05.mp4

Review notes

The bug was due to the transaction type. When we send regular tokens we don't stablish a new tx-type on re-frame. To fix it I'm removing the old transaction type when we pick a token.

Steps to test

Please check the video in the original issue

status: ready

@ulisesmac ulisesmac requested review from vkjr, J-Son89, OmarBasem and a team July 22, 2024 20:26
@ulisesmac ulisesmac self-assigned this Jul 22, 2024
@@ -204,15 +204,15 @@
token-networks-ids)]
(when (or token token-symbol)
{:db (cond-> db
:always (update-in [:wallet :ui :send] dissoc :collectible)
:always (update-in [:wallet :ui :send] dissoc :collectible :tx-type)
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Remove the old tx type

@status-im-auto
Copy link
Member

status-im-auto commented Jul 22, 2024

Jenkins Builds

Click to see older builds (16)
Commit #️⃣ Finished (UTC) Duration Platform Result
✔️ 20a8e01 #1 2024-07-22 20:32:13 ~4 min tests 📄log
✔️ 20a8e01 #1 2024-07-22 20:33:41 ~6 min android-e2e 🤖apk 📲
✔️ 20a8e01 #1 2024-07-22 20:35:04 ~7 min android 🤖apk 📲
✔️ 20a8e01 #1 2024-07-22 20:36:40 ~9 min ios 📱ipa 📲
✔️ f6e8584 #2 2024-07-24 00:06:10 ~6 min tests 📄log
✔️ f6e8584 #2 2024-07-24 00:06:42 ~7 min android 🤖apk 📲
✔️ f6e8584 #2 2024-07-24 00:07:40 ~8 min android-e2e 🤖apk 📲
✔️ f6e8584 #2 2024-07-24 00:08:47 ~9 min ios 📱ipa 📲
✔️ ca23215 #3 2024-07-24 22:05:27 ~5 min tests 📄log
✔️ ca23215 #3 2024-07-24 22:07:18 ~7 min android-e2e 🤖apk 📲
✔️ ca23215 #3 2024-07-24 22:07:46 ~7 min android 🤖apk 📲
✔️ ca23215 #3 2024-07-24 22:10:02 ~9 min ios 📱ipa 📲
✔️ bc650e7 #4 2024-08-02 08:26:36 ~4 min tests 📄log
✔️ bc650e7 #4 2024-08-02 08:30:29 ~8 min android-e2e 🤖apk 📲
✔️ bc650e7 #4 2024-08-02 08:30:57 ~9 min android 🤖apk 📲
✔️ bc650e7 #4 2024-08-02 08:31:05 ~9 min ios 📱ipa 📲
Commit #️⃣ Finished (UTC) Duration Platform Result
✔️ ca37871 #5 2024-08-02 15:09:07 ~3 min tests 📄log
✔️ ca37871 #5 2024-08-02 15:12:23 ~7 min android-e2e 🤖apk 📲
✔️ ca37871 #5 2024-08-02 15:12:36 ~7 min android 🤖apk 📲
✔️ ca37871 #5 2024-08-02 15:14:10 ~9 min ios 📱ipa 📲
✔️ a524892 #6 2024-08-02 15:22:11 ~4 min tests 📄log
✔️ a524892 #6 2024-08-02 15:25:15 ~7 min android-e2e 🤖apk 📲
✔️ a524892 #6 2024-08-02 15:25:39 ~7 min android 🤖apk 📲
✔️ a524892 #6 2024-08-02 15:27:03 ~9 min ios 📱ipa 📲

@status-im-auto
Copy link
Member

57% of end-end tests have passed

Total executed tests: 7
Failed tests: 2
Expected to fail tests: 1
Passed tests: 4
IDs of failed tests: 727230,727229 
IDs of expected to fail tests: 727232 

Failed tests (2)

Click to expand
  • Rerun failed tests

  • Class TestWalletMultipleDevice:

    1. test_wallet_send_asset_from_drawer, id: 727230

    Device 2: Find `Text` by `xpath`: `//android.view.ViewGroup[@content-desc='container']/android.widget.TextView[@text='Ether']/../android.widget.TextView[3]`
    Device 2: `Text` is `0.01319 ETH`

    critical/test_wallet.py:184: in test_wallet_send_asset_from_drawer
        self.errors.verify_no_errors()
    base_test_case.py:191: in verify_no_errors
        pytest.fail('\n '.join([self.errors.pop(0) for _ in range(len(self.errors))]))
     Sender balance is not updated on Etherscan, it is 0.485 but expected to be 0.4849
    E    Receiver balance is not updated on Etherscan, it is 0.0133 but expected to be 0.0134
    E    Eth amount in the senders wallet is 0.4851 but should be 0.485
    E    Eth amount in the receivers wallet is 0.0132 but should be 0.0133
    



    2. test_wallet_send_eth, id: 727229

    Device 2: Find Text by xpath: //android.view.ViewGroup[@content-desc='container']/android.widget.TextView[@text='Ether']/../android.widget.TextView[3]
    Device 2: Text is 0.01319 ETH

    critical/test_wallet.py:156: in test_wallet_send_eth
        self.errors.verify_no_errors()
    base_test_case.py:191: in verify_no_errors
        pytest.fail('\n '.join([self.errors.pop(0) for _ in range(len(self.errors))]))
     Eth amount in the senders wallet is 0.4851 but should be 0.485
    E    Eth amount in the receivers wallet is 0.0132 but should be 0.0133
    



    Expected to fail tests (1)

    Click to expand

    Class TestWalletOneDevice:

    1. test_wallet_add_remove_watch_only_account, id: 727232

    Device 1: Find EditBox by accessibility id: add-address-to-watch
    Device 1: Type 0x8d2413447ff297d30bdc475f6d5cb00254685aae to EditBox

    critical/test_wallet.py:249: in test_wallet_add_remove_watch_only_account
        self.wallet_view.add_watch_only_account(address=address_to_watch, account_name=new_account_name)
    ../views/wallet_view.py:163: in add_watch_only_account
        self.account_has_activity_label.wait_for_visibility_of_element()
    ../views/base_element.py:147: in wait_for_visibility_of_element
        raise TimeoutException(
     Device 1: Text by accessibility id:`account-has-activity` is not found on the screen after wait_for_visibility_of_element 
    

    [[Missing networks in account address, https://github.com//issues/20166]]

    Device sessions

    Passed tests (4)

    Click to expand

    Class TestWalletOneDevice:

    1. test_wallet_add_remove_regular_account, id: 727231
    Device sessions

    Class TestCommunityOneDeviceMerged:

    1. test_community_copy_and_paste_message_in_chat_input, id: 702742
    Device sessions

    2. test_restore_multiaccount_with_waku_backup_remove_switch, id: 703133
    Device sessions

    Class TestOneToOneChatMultipleSharedDevicesNewUi:

    1. test_1_1_chat_non_latin_messages_stack_update_profile_photo, id: 702745
    Device sessions

    @ulisesmac ulisesmac force-pushed the 20677-user-navigated-to-transaction-confirmation branch from 20a8e01 to f6e8584 Compare July 23, 2024 23:59
    @VolodLytvynenko VolodLytvynenko self-assigned this Jul 24, 2024
    @status-im-auto
    Copy link
    Member

    71% of end-end tests have passed

    Total executed tests: 7
    Failed tests: 1
    Expected to fail tests: 1
    Passed tests: 5
    
    IDs of failed tests: 727229 
    
    IDs of expected to fail tests: 727232 
    

    Failed tests (1)

    Click to expand
  • Rerun failed tests

  • Class TestWalletMultipleDevice:

    1. test_wallet_send_eth, id: 727229

    Device 2: Find `Text` by `xpath`: `//android.view.ViewGroup[@content-desc='container']/android.widget.TextView[@text='Ether']/../android.widget.TextView[3]`
    Device 2: `Text` is `0.01459 ETH`

    critical/test_wallet.py:156: in test_wallet_send_eth
        self.errors.verify_no_errors()
    base_test_case.py:191: in verify_no_errors
        pytest.fail('\n '.join([self.errors.pop(0) for _ in range(len(self.errors))]))
     Sender balance is not updated on Etherscan, it is 0.4833 but expected to be 0.4834
    



    Expected to fail tests (1)

    Click to expand

    Class TestWalletOneDevice:

    1. test_wallet_add_remove_watch_only_account, id: 727232

    Device 1: Find EditBox by accessibility id: add-address-to-watch
    Device 1: Type 0x8d2413447ff297d30bdc475f6d5cb00254685aae to EditBox

    critical/test_wallet.py:249: in test_wallet_add_remove_watch_only_account
        self.wallet_view.add_watch_only_account(address=address_to_watch, account_name=new_account_name)
    ../views/wallet_view.py:163: in add_watch_only_account
        self.account_has_activity_label.wait_for_visibility_of_element()
    ../views/base_element.py:147: in wait_for_visibility_of_element
        raise TimeoutException(
     Device 1: Text by accessibility id:`account-has-activity` is not found on the screen after wait_for_visibility_of_element 
    

    [[Missing networks in account address, https://github.com//issues/20166]]

    Device sessions

    Passed tests (5)

    Click to expand

    Class TestOneToOneChatMultipleSharedDevicesNewUi:

    1. test_1_1_chat_non_latin_messages_stack_update_profile_photo, id: 702745
    Device sessions

    Class TestCommunityOneDeviceMerged:

    1. test_restore_multiaccount_with_waku_backup_remove_switch, id: 703133
    Device sessions

    2. test_community_copy_and_paste_message_in_chat_input, id: 702742
    Device sessions

    Class TestWalletMultipleDevice:

    1. test_wallet_send_asset_from_drawer, id: 727230

    Class TestWalletOneDevice:

    1. test_wallet_add_remove_regular_account, id: 727231
    Device sessions

    @churik churik assigned churik and unassigned VolodLytvynenko Jul 24, 2024
    @VolodLytvynenko VolodLytvynenko force-pushed the 20677-user-navigated-to-transaction-confirmation branch from ca23215 to bc650e7 Compare August 2, 2024 08:21
    @VolodLytvynenko
    Copy link
    Contributor

    hi @ulisesmac thank you for PR. No issues from my side. PR is ready to be merged

    @churik
    Copy link
    Member

    churik commented Aug 2, 2024

    Let's merge it and include to release, very nice fix, thank you @ulisesmac !

    @ulisesmac ulisesmac force-pushed the 20677-user-navigated-to-transaction-confirmation branch from ca37871 to a524892 Compare August 2, 2024 15:17
    @ulisesmac ulisesmac merged commit ae6205c into develop Aug 2, 2024
    5 checks passed
    @ulisesmac ulisesmac deleted the 20677-user-navigated-to-transaction-confirmation branch August 2, 2024 15:30
    J-Son89 pushed a commit that referenced this pull request Aug 6, 2024
    )
    
    * fix(wallet): Fix input amount step skipped while sending a token
    
    * Add comment about ^:flush-dom metadata
    Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
    Projects
    Archived in project
    Development

    Successfully merging this pull request may close these issues.

    User is navigated to transaction confirmation page if asset is selected during collectible sending flow
    7 participants