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

chore: add needed packages for WalletConnect implementation #19758

Merged
merged 1 commit into from May 8, 2024

Conversation

briansztamfater
Copy link
Member

@briansztamfater briansztamfater commented Apr 22, 2024

This PR adds WalletConnect Web3Wallet library and required additional libraries as their documentation describes. Also defines WALLET_CONNECT_PROJECT_ID key for env var and a basic utils file to creating a Web3Wallet instance. Manual QA can be skipped, no new features nor bug fixes are included in this PR, we just need to make sure new packages don't make the app to crash.

Also not sure if I am making correct use of promesa so feedback is appreciated.

status: ready

@status-im-auto
Copy link
Member

status-im-auto commented Apr 22, 2024

Jenkins Builds

Click to see older builds (32)
Commit #️⃣ Finished (UTC) Duration Platform Result
c3d6dfe #4 2024-04-22 16:58:35 ~3 min tests 📄log
✔️ 0c8ad7a #5 2024-04-22 17:07:40 ~5 min tests 📄log
✔️ 0c8ad7a #5 2024-04-22 17:08:36 ~5 min android-e2e 🤖apk 📲
✔️ 0c8ad7a #5 2024-04-22 17:10:20 ~7 min android 🤖apk 📲
✔️ 0c8ad7a #5 2024-04-22 17:13:43 ~11 min ios 📱ipa 📲
✔️ e223a4f #6 2024-04-29 20:29:52 ~4 min tests 📄log
✔️ e223a4f #6 2024-04-29 20:31:46 ~5 min android-e2e 🤖apk 📲
✔️ e223a4f #6 2024-04-29 20:32:39 ~6 min android 🤖apk 📲
✔️ e223a4f #6 2024-04-29 20:35:31 ~9 min ios 📱ipa 📲
✔️ 05f8ffd #7 2024-04-29 20:41:53 ~3 min tests 📄log
✔️ 05f8ffd #7 2024-04-29 20:43:34 ~5 min android-e2e 🤖apk 📲
✔️ 05f8ffd #7 2024-04-29 20:44:49 ~6 min android 🤖apk 📲
✔️ 2d95457 #8 2024-04-29 20:52:03 ~6 min tests 📄log
✔️ 2d95457 #8 2024-04-29 20:52:24 ~6 min android 🤖apk 📲
✔️ 2d95457 #8 2024-04-29 20:52:59 ~7 min android-e2e 🤖apk 📲
✔️ 2d95457 #8 2024-04-29 20:57:41 ~12 min ios 📱ipa 📲
✔️ a9a21f3 #9 2024-05-01 14:03:17 ~3 min tests 📄log
✔️ a9a21f3 #9 2024-05-01 14:05:10 ~5 min android 🤖apk 📲
✔️ a9a21f3 #9 2024-05-01 14:06:11 ~6 min android-e2e 🤖apk 📲
✔️ a9a21f3 #9 2024-05-01 14:08:54 ~9 min ios 📱ipa 📲
✔️ 0a2d615 #10 2024-05-02 06:47:56 ~4 min tests 📄log
✔️ 0a2d615 #10 2024-05-02 06:50:53 ~6 min android 🤖apk 📲
✔️ 0a2d615 #10 2024-05-02 06:50:58 ~7 min android-e2e 🤖apk 📲
✔️ 0a2d615 #10 2024-05-02 06:57:25 ~13 min ios 📱ipa 📲
✔️ 614745c #11 2024-05-02 08:31:26 ~3 min tests 📄log
✔️ 614745c #11 2024-05-02 08:34:20 ~6 min android-e2e 🤖apk 📲
✔️ 614745c #11 2024-05-02 08:34:21 ~6 min android 🤖apk 📲
✔️ 614745c #11 2024-05-02 08:37:10 ~9 min ios 📱ipa 📲
✔️ 7f2a1c4 #13 2024-05-06 10:21:38 ~4 min tests 📄log
✔️ 7f2a1c4 #13 2024-05-06 10:25:14 ~8 min android-e2e 🤖apk 📲
✔️ 7f2a1c4 #13 2024-05-06 10:25:18 ~8 min android 🤖apk 📲
✔️ 7f2a1c4 #13 2024-05-06 10:28:25 ~11 min ios 📱ipa 📲
Commit #️⃣ Finished (UTC) Duration Platform Result
✔️ c96818c #14 2024-05-07 11:33:23 ~5 min android 🤖apk 📲
✔️ c96818c #14 2024-05-07 11:33:46 ~6 min tests 📄log
✔️ c96818c #14 2024-05-07 11:36:56 ~9 min android-e2e 🤖apk 📲
✔️ c96818c #14 2024-05-07 11:37:13 ~9 min ios 📱ipa 📲
✔️ 6d7e7f9 #15 2024-05-08 08:47:14 ~5 min tests 📄log
✔️ 6d7e7f9 #15 2024-05-08 08:48:58 ~6 min android-e2e 🤖apk 📲
✔️ 6d7e7f9 #15 2024-05-08 08:49:06 ~7 min android 🤖apk 📲
✔️ 6d7e7f9 #15 2024-05-08 08:51:32 ~9 min ios 📱ipa 📲

@briansztamfater briansztamfater force-pushed the chore/add-wallet-connect-package branch from c3d6dfe to 0c8ad7a Compare April 22, 2024 17:02
[]
(let [core (wallet-connect-core)
metadata (clj->js config/default-wallet-connect-metadata)]
(promesa/create
Copy link
Member

Choose a reason for hiding this comment

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

@clauxx - looks good here?

Copy link
Member

Choose a reason for hiding this comment

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

looks weird. If Web3Wallet.init already returns a promise, there's no need to create another promise with promesa/create. Just return the promise and it would be handled in the effect it's called from.

Copy link
Member Author

Choose a reason for hiding this comment

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

@clauxx makes sense, I'll modify it 👍

Copy link
Contributor

Choose a reason for hiding this comment

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

Metadata can be moved to a (defonce metadata #js {...}).

It never changes so clj->js is redundant.

@briansztamfater briansztamfater changed the title chore: add wallet connect library chore: add needed packages for WalletConnect implementation Apr 22, 2024
"Status is a secure messaging app, crypto wallet, and Web3 browser built with state of the art technology."
:url "https://status.app"
:icons
["https://res.cloudinary.com/dhgck7ebz/image/upload/f_auto,c_limit,w_1080,q_auto/Brand/Logo%20Section/Mark/Mark_01"]})
Copy link
Member

Choose a reason for hiding this comment

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

the formatting looks weird

Copy link
Member Author

Choose a reason for hiding this comment

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

I extracted it from our website just to provide some values, but we can update it later on

Copy link
Contributor

Choose a reason for hiding this comment

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

Do we need to care about translations here ? Should we wrap description in (i18n) ?

Copy link
Contributor

Choose a reason for hiding this comment

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

Not a change, but is it possible to pass icon from disk rather than a link?
What if the infra team stops using Cloudinary tomorrow ?

Copy link
Member Author

Choose a reason for hiding this comment

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

Not a change, but is it possible to pass icon from disk rather than a link? What if the infra team stops using Cloudinary tomorrow ?

From all examples I've seen, only urls are passed for icons. I think we could do some research and update this part in a follow up in case it is needed. Also copies should be temporal, we should get better ones from the marketing or design team ultimately.

@@ -0,0 +1,21 @@
(ns status-im.contexts.wallet.common.utils.wallet-connect
Copy link
Member

Choose a reason for hiding this comment

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

What about having the wallet-connect stuff in its own namespace e.g. status-im.contexts.wallet.wallet-connect?

Copy link
Member

Choose a reason for hiding this comment

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

I agree. 👍

Copy link
Member Author

Choose a reason for hiding this comment

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

I will move it

Copy link
Member Author

Choose a reason for hiding this comment

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

Moved it 👍

[]
(let [core (wallet-connect-core)
metadata (clj->js config/default-wallet-connect-metadata)]
(promesa/create
Copy link
Member

Choose a reason for hiding this comment

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

looks weird. If Web3Wallet.init already returns a promise, there's no need to create another promise with promesa/create. Just return the promise and it would be handled in the effect it's called from.


(defn- wallet-connect-core
[]
(Core. (clj->js {:project-id config/wallet-connect-project-id})))
Copy link
Member

Choose a reason for hiding this comment

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

are we going to have a different project-id for testnet mode?

Copy link
Member Author

Choose a reason for hiding this comment

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

Should be the same project id, we should just connect to different chains

Copy link
Contributor

Choose a reason for hiding this comment

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

We can move the {:project-id ...} to a defonce with #js. clj->js is redundant because project id is static.

Copy link
Member Author

Choose a reason for hiding this comment

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

Updated

Comment on lines 139 to 145
(def default-wallet-connect-metadata
{:name "Status"
:description
"Status is a secure messaging app, crypto wallet, and Web3 browser built with state of the art technology."
:url "https://status.app"
:icons
["https://res.cloudinary.com/dhgck7ebz/image/upload/f_auto,c_limit,w_1080,q_auto/Brand/Logo%20Section/Mark/Mark_01"]})
Copy link
Member

Choose a reason for hiding this comment

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

not sure if makes sense to keep it in the config. Doesn't look like something that will be used outside the initialisation from status-im.contexts.wallet.common.utils.wallet-connect and might be easier to just keep them together.

@@ -36,6 +37,7 @@
(def goerli-chain-explorer-link "https://goerli.etherscan.io/address/")
(def optimism-goerli-chain-explorer-link "https://goerli-optimistic.etherscan.io/address/")
(def opensea-api-key OPENSEA_API_KEY)
(def wallet-connect-project-id WALLET_CONNECT_PROJECT_ID)
Copy link
Member

Choose a reason for hiding this comment

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

Not sure why we do this but we can use the WALLET_CONNECT_PROJECT_ID directly in other places.

@@ -0,0 +1,21 @@
(ns status-im.contexts.wallet.common.utils.wallet-connect
Copy link
Member

Choose a reason for hiding this comment

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

I agree. 👍

(promesa/create
(fn [p-resolve p-reject]
(-> (Web3Wallet.init
(clj->js {:core core
Copy link
Contributor

Choose a reason for hiding this comment

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

@briansztamfater, a few suggestions for this namespace:

  1. The code (clj->js {:project-id config/wallet-connect-project-id}) can be changed to #js {:project-id config/WALLET_CONNECT_PROJECT_ID}. I tend to prefer the #js literal for small, non-nested maps because it's significantly faster than clj->js. The init function will be called once, so it won't be a problem, but sharing as a reminder that we should be mindful of clj->js.
  2. I would make default-wallet-connect-metadata a private var in this namespace and remove it from status-im.config because the map doesn't depend on any value coming from an external env.

Copy link
Member Author

Choose a reason for hiding this comment

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

Updated 👍


(defn- wallet-connect-core
[]
(Core. (clj->js {:project-id config/wallet-connect-project-id})))
Copy link
Contributor

Choose a reason for hiding this comment

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

Are we sure the option is in kebab-case? Here https://github.com/WalletConnect/walletconnect-monorepo/blob/v2.0/packages/core/src/core.ts#L67 I see there it should be projectId.

Copy link
Member Author

Choose a reason for hiding this comment

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

Updated

"Status is a secure messaging app, crypto wallet, and Web3 browser built with state of the art technology."
:url "https://status.app"
:icons
["https://res.cloudinary.com/dhgck7ebz/image/upload/f_auto,c_limit,w_1080,q_auto/Brand/Logo%20Section/Mark/Mark_01"]})
Copy link
Contributor

Choose a reason for hiding this comment

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

Do we need to care about translations here ? Should we wrap description in (i18n) ?

"Status is a secure messaging app, crypto wallet, and Web3 browser built with state of the art technology."
:url "https://status.app"
:icons
["https://res.cloudinary.com/dhgck7ebz/image/upload/f_auto,c_limit,w_1080,q_auto/Brand/Logo%20Section/Mark/Mark_01"]})
Copy link
Contributor

Choose a reason for hiding this comment

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

Not a change, but is it possible to pass icon from disk rather than a link?
What if the infra team stops using Cloudinary tomorrow ?


(defn- wallet-connect-core
[]
(Core. (clj->js {:project-id config/wallet-connect-project-id})))
Copy link
Contributor

Choose a reason for hiding this comment

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

We can move the {:project-id ...} to a defonce with #js. clj->js is redundant because project id is static.

[]
(let [core (wallet-connect-core)
metadata (clj->js config/default-wallet-connect-metadata)]
(promesa/create
Copy link
Contributor

Choose a reason for hiding this comment

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

Metadata can be moved to a (defonce metadata #js {...}).

It never changes so clj->js is redundant.

@briansztamfater briansztamfater force-pushed the chore/add-wallet-connect-package branch from 0c8ad7a to e223a4f Compare April 29, 2024 20:25
@briansztamfater briansztamfater force-pushed the chore/add-wallet-connect-package branch 2 times, most recently from 05f8ffd to 2d95457 Compare April 29, 2024 20:45
Copy link
Member

@clauxx clauxx left a comment

Choose a reason for hiding this comment

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

Thanks @briansztamfater! Looks good!

@siddarthkay is everything good dependency-wise here?

@siddarthkay
Copy link
Contributor

is everything good dependency-wise

It was the last time I had looked at it.
I'm checking now to see if gradle deps are changed or not..

@siddarthkay
Copy link
Contributor

Hmm Indeed entries are missing from nix/deps/gradle/proj.list

Screenshot 2024-04-30 at 1 45 21 PM

@briansztamfater : please could you run make nix-update-gradle and push the changed files.

@briansztamfater
Copy link
Member Author

@siddarthkay @jakubgs pushed changes from make nix-update-gradle

Also @shivekkhurana can you re-review?

@siddarthkay siddarthkay force-pushed the chore/add-wallet-connect-package branch from a9a21f3 to 0a2d615 Compare May 2, 2024 06:43
@shivekkhurana
Copy link
Contributor

I'm okay with this PR except for this comment:
#19758 (comment)

["@walletconnect/web3wallet" :refer [Web3Wallet]]
[status-im.config :as config]))

(defonce ^:private wallet-connect-metadata
Copy link
Contributor

Choose a reason for hiding this comment

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

@briansztamfater @shivekkhurana defonce shouldn't be used in a case like this. As far as I've seen, defonce is basically a tool to help devs take control in the REPL of when side-effects should happen. A common example in the wild is to initialize global atoms, as in (defonce foo (atom :bar)).

There's no side-effect to evaluate wallet-connect-metadata (ignoring memory allocation could fail in a parallel universe), hence just def is sufficient. In fact, when I see defonce, I instantly search for the line of code with side-effects to understand why it's being used.

Copy link
Member Author

Choose a reason for hiding this comment

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

Thanks for the feedback, I added translated strings, so probably defn is a better choice than def because language could change while the app is active 🤔 wdyt?

Copy link
Contributor

Choose a reason for hiding this comment

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

Good question @briansztamfater. I have the impression our app doesn't react to system language changes and thus, requires a full restart. This means it's okay to use def and not worry about reactiveness. Not saying this is the best approach, but it's how I see our app behaving now.

Note: on emulated Android, when the whole system language changes, even after a full app restart it doesn't pick up the correct language and English is still seen everywhere. Maybe this is a problem deserving investigation in the near future.

@clauxx clauxx added E:Mobile MVP Wallet Connect integration Focusing on integrating the WC functionality and UX flows based on descoped designs and removed E:Mobile MVP Wallet Connect integration Focusing on integrating the WC functionality and UX flows based on descoped designs labels May 5, 2024
@briansztamfater briansztamfater force-pushed the chore/add-wallet-connect-package branch from 8cb0e38 to 7f2a1c4 Compare May 6, 2024 10:16
Copy link
Member

@clauxx clauxx left a comment

Choose a reason for hiding this comment

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

Looks good to me. Can be merged I guess as it doesn't affect any existing functionality 👍

@shivekkhurana can you give it a re-review when you have the chance?

Copy link
Member

@jakubgs jakubgs left a comment

Choose a reason for hiding this comment

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

As far as I know WalletConnect project ID is not a secret.

@clauxx
Copy link
Member

clauxx commented May 6, 2024

As far as I know WalletConnect project ID is not a secret.

@jakubgs according to this, we should "(...) avoid committing projects keys to the repo. Use env variables instead". We already have it in the repo over here though.

@jakubgs
Copy link
Member

jakubgs commented May 6, 2024

@clauxx if Project ID was a key it would be called a Project Key.

@clauxx
Copy link
Member

clauxx commented May 6, 2024

@clauxx if Project ID was a key it would be called a Project Key.

@jakubgs can't say about their naming consistency, but they advise hiding the "project keys" on the same page they introduce the Project ID, while "project keys" are not mentioned anywhere else in their documentation. Didn't look too much into it, but I'd rather be on the safer side and hide it.

@clauxx clauxx moved this from REVIEW to E2E Tests in Pipeline for QA May 7, 2024
@status-im-auto
Copy link
Member

75% of end-end tests have passed

Total executed tests: 52
Failed tests: 11
Expected to fail tests: 2
Passed tests: 39
IDs of failed tests: 727230,702782,704613,702851,727231,704615,727229,702947,702807,727232,702775 
IDs of expected to fail tests: 703495,703503 

Failed tests (11)

Click to expand
  • Rerun failed tests

  • Class TestDeepLinksOneDevice:

    1. test_links_open_universal_links_from_chat, id: 704613

    Device 1: Find `Button` by `xpath`: `//*[@text="open community"]`
    Device 1: Tap on found: Button

    critical/test_deep_and_universal_links.py:70: in test_links_open_universal_links_from_chat
        self.errors.verify_no_errors()
    base_test_case.py:190: in verify_no_errors
        pytest.fail('\n '.join([self.errors.pop(0) for _ in range(len(self.errors))]))
     Community 'Open community for e2e' was not requested to join by the url https://status.app/c/G1AAAGR0G-IRb2YJD4lRXwLusAFnGrDHGNl6Wt55MIARwVYvarnO873011-fdVSz1kHSan-qq0G96vOaMqyTRhJnQV74KCUr#zQ3shb9irJR66rhG1E8sQZX8pDU3dpGm4daYSmPVDd2e73ewE
    



    Device sessions

    2. test_links_deep_links, id: 702775

    Device 1: Waiting 35s for dapp to load
    Device 1: Find Text by accessibility id: contact-name

    critical/test_deep_and_universal_links.py:87: in test_links_deep_links
        shown_name_text = self.profile_view.contact_name_text.text
    ../views/base_element.py:416: in text
        text = self.find_element().text
    ../views/base_element.py:79: in find_element
        raise NoSuchElementException(
     Device 1: Text by accessibility id: `contact-name` is not found on the screen; For documentation on this error, please visit: https://www.selenium.dev/documentation/webdriver/troubleshooting/errors#no-such-element-exception
    



    Device sessions

    Class TestWalletMultipleDevice:

    1. test_wallet_send_asset_from_drawer, id: 727230

    # STEP: Getting ETH amount in the wallet of the sender before transaction
    Device 1: Find WalletTab by accessibility id: wallet-stack-tab

    critical/test_wallet.py:117: in test_wallet_send_asset_from_drawer
        sender_balance, receiver_balance, eth_amount_sender, eth_amount_receiver = self._get_balances_before_tx()
    critical/test_wallet.py:39: in _get_balances_before_tx
        self.wallet_1.wallet_tab.click()
    ../views/base_element.py:90: in click
        element = self.find_element()
    ../views/base_element.py:79: in find_element
        raise NoSuchElementException(
     Device 1: WalletTab by accessibility id: `wallet-stack-tab` is not found on the screen; For documentation on this error, please visit: https://www.selenium.dev/documentation/webdriver/troubleshooting/errors#no-such-element-exception
    



    2. test_wallet_send_eth, id: 727229

    Device 1: Swiping right on element SlideButton
    Device 1: Find SlideButton by xpath: //*[@resource-id='slide-button-track']

    critical/test_wallet.py:109: in test_wallet_send_eth
        self.wallet_1.send_asset(address=self.receiver['address'], asset_name='Ether', amount=amount_to_send)
    ../views/wallet_view.py:99: in send_asset
        self.confirm_transaction()
    ../views/wallet_view.py:86: in confirm_transaction
        self.slide_and_confirm_with_password()
    ../views/wallet_view.py:80: in slide_and_confirm_with_password
        self.slide_button_track.slide()
    ../views/base_view.py:257: in slide
        self.swipe_right_on_element(width_percentage=1.3, start_x=100)
    ../views/base_element.py:308: in swipe_right_on_element
        location, size = self.get_element_coordinates()
    ../views/base_element.py:294: in get_element_coordinates
        element = self.find_element()
    ../views/base_element.py:79: in find_element
        raise NoSuchElementException(
     Device 1: SlideButton by xpath: `//*[@resource-id='slide-button-track']` is not found on the screen; For documentation on this error, please visit: https://www.selenium.dev/documentation/webdriver/troubleshooting/errors#no-such-element-exception
    



    Class TestOneToOneChatMultipleSharedDevicesNewUi:

    1. test_1_1_chat_emoji_send_reply_and_open_link, id: 702782

    Device 1: Find BaseElement by xpath: //*[@content-desc=':chat-floating-screen']//*[starts-with(@text,'🌧')]
    Device 1: Long press on BaseElement until expected element is shown

    critical/chats/test_1_1_public_chats.py:117: in test_1_1_chat_emoji_send_reply_and_open_link
        self.chat_1.quote_message(emoji_unicode)
    ../views/chat_view.py:1040: in quote_message
        self.chat_view_element_starts_with_text(message).long_press_until_element_is_shown(self.reply_message_button)
    ../views/base_element.py:331: in long_press_until_element_is_shown
        action.long_press(element).release().perform()
    ../../../../status-app-prs@tmp/venv/lib/python3.10/site-packages/appium/webdriver/common/touch_action.py:174: in perform
        self._driver.execute(Command.TOUCH_ACTION, params)
    ../../../../status-app-prs@tmp/venv/lib/python3.10/site-packages/selenium/webdriver/remote/webdriver.py:345: in execute
        self.error_handler.check_response(response)
    ../../../../status-app-prs@tmp/venv/lib/python3.10/site-packages/appium/webdriver/errorhandler.py:122: in check_response
        raise exception_class(msg=message, stacktrace=format_stacktrace(stacktrace))
     The element 'By.xpath: //*[@content-desc=':chat-floating-screen']//*[starts-with(@text,'🌧')]' is not linked to the same object in DOM anymore; For documentation on this error, please visit: https://www.selenium.dev/documentation/webdriver/troubleshooting/errors#stale-element-reference-exception
    E   Stacktrace:
    E   io.appium.uiautomator2.common.exceptions.StaleElementReferenceException: The element 'By.xpath: //*[@content-desc=':chat-floating-screen']//*[starts-with(@text,'🌧')]' is not linked to the same object in DOM anymore
    E   	at io.appium.uiautomator2.model.ElementsCache.restore(ElementsCache.java:122)
    E   	at io.appium.uiautomator2.model.ElementsCache.get(ElementsCache.java:153)
    E   	at io.appium.uiautomator2.handler.Location.safeHandle(Location.java:23)
    E   	at io.appium.uiautomator2.handler.request.SafeRequestHandler.handle(SafeRequestHandler.java:59)
    E   	at io.appium.uiautomator2.server.AppiumServlet.handleRequest(AppiumServlet.java:277)
    E   	at io.appium.uiautomator2.server.AppiumServlet.handleHttpRequest(AppiumServlet.java:271)
    E   	at io.appium.uiautomator2.http.ServerHandler.channelRead(ServerHandler.java:68)
    E   	at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:366)
    E   	at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:352)
    E   	at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:345)
    E   	at io.netty.handler.codec.MessageToMessageDecoder.channelRead(MessageToMessageDecoder.java:102)
    E   	at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:366)
    E   	at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:352)
    E   	at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:345)
    E   	at io.netty.channel.CombinedChannelDuplexHandler$DelegatingChannelHandlerContext.fireChannelRead(CombinedChannelDuplexHandler.java:435)
    E   	at io.netty.handler.codec.ByteToMessageDecoder.fireChannelRead(ByteToMessageDecoder.java:293)
    E   	at io.netty.handler.codec.ByteToMessageDecoder.channelRead(ByteToMessageDecoder.java:267)
    E   	at io.netty.channel.CombinedChannelDuplexHandler.channelRead(CombinedChannelDuplexHandler.java:250)
    E   	at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:366)
    E   	at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:352)
    E   	at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:345)
    E   	at io.netty.handler.timeout.IdleStateHandler.channelRead(IdleStateHandler.java:266)
    E   	at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:366)
    E   	at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:352)
    E   	at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:345)
    E   	at io.netty.channel.DefaultChannelPipeline$HeadContext.channelRead(DefaultChannelPipeline.java:1294)
    E   	at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:366)
    E   	at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:352)
    E   	at io.netty.channel.DefaultChannelPipeline.fireChannelRead(DefaultChannelPipeline.java:911)
    E   	at io.netty.channel.nio.AbstractNioByteChannel$NioByteUnsafe.read(AbstractNioByteChannel.java:131)
    E   	at io.netty.channel.nio.NioEventLoop.processSelectedKey(NioEventLoop.java:611)
    E   	at io.netty.channel.nio.NioEventLoop.processSelectedKeysOptimized(NioEventLoop.java:552)
    E   	at io.netty.channel.nio.NioEventLoop.processSelectedKeys(NioEventLoop.java:466)
    E   	at io.netty.channel.nio.NioEventLoop.run(NioEventLoop.java:438)
    E   	at io.netty.util.concurrent.SingleThreadEventExecutor$2.run(SingleThreadEventExecutor.java:140)
    E   	at io.netty.util.concurrent.DefaultThreadFactory$DefaultRunnableDecorator.run(DefaultThreadFactory.java:144)
    E   	at java.lang.Thread.run(Thread.java:1012)
    



    Device sessions

    Class TestWalletOneDevice:

    1. test_wallet_add_remove_regular_account, id: 727231

    Device 1: Find Button by accessibility id: account-emoji
    Device 1: Find Button by accessibility id: share-account

    critical/test_wallet.py:152: in test_wallet_add_remove_regular_account
        self.wallet_view.share_address_button.click()
    ../views/base_element.py:90: in click
        element = self.find_element()
    ../views/base_element.py:79: in find_element
        raise NoSuchElementException(
     Device 1: Button by accessibility id: `share-account` is not found on the screen; For documentation on this error, please visit: https://www.selenium.dev/documentation/webdriver/troubleshooting/errors#no-such-element-exception
    



    Device sessions

    2. test_wallet_add_remove_watch_only_account, id: 727232

    # STEP: Adding new watch only account
    Device 1: Find Button by accessibility id: add-account

    critical/test_wallet.py:190: 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:117: in add_watch_only_account
        self.add_account_button.click()
    ../views/base_element.py:90: in click
        element = self.find_element()
    ../views/base_element.py:79: in find_element
        raise NoSuchElementException(
     Device 1: Button by accessibility id: `add-account` is not found on the screen; For documentation on this error, please visit: https://www.selenium.dev/documentation/webdriver/troubleshooting/errors#no-such-element-exception
    



    Device sessions

    Class TestActivityCenterContactRequestMultipleDevicePR:

    1. test_activity_center_contact_request_accept_swipe_mark_all_as_read, id: 702851

    Device 1: Tap on found: Button
    # STEP: Device1 check that contact appeared in contact list mutually

    ../../../../status-app-prs@tmp/venv/lib/python3.10/site-packages/urllib3/connectionpool.py:703: in urlopen
        httplib_response = self._make_request(
    ../../../../status-app-prs@tmp/venv/lib/python3.10/site-packages/urllib3/connectionpool.py:449: in _make_request
        six.raise_from(e, None)
    <string>:3: in raise_from
        ???
    ../../../../status-app-prs@tmp/venv/lib/python3.10/site-packages/urllib3/connectionpool.py:444: in _make_request
        httplib_response = conn.getresponse()
    /usr/lib/python3.10/http/client.py:1375: in getresponse
        response.begin()
    /usr/lib/python3.10/http/client.py:318: in begin
        version, status, reason = self._read_status()
    /usr/lib/python3.10/http/client.py:287: in _read_status
        raise RemoteDisconnected("Remote end closed connection without"
    E   http.client.RemoteDisconnected: Remote end closed connection without response
    
    During handling of the above exception, another exception occurred:
    activity_center/test_activity_center.py:141: in test_activity_center_contact_request_accept_swipe_mark_all_as_read
        self.device_2.just_fyi('Device1 check that contact appeared in contact list mutually')
    ../views/base_view.py:410: in just_fyi
        self.driver.execute_script("sauce:context=STEP: %s" % some_str)
    ../../../../status-app-prs@tmp/venv/lib/python3.10/site-packages/selenium/webdriver/remote/webdriver.py:405: in execute_script
        return self.execute(command, {"script": script, "args": converted_args})["value"]
    ../../../../status-app-prs@tmp/venv/lib/python3.10/site-packages/selenium/webdriver/remote/webdriver.py:343: in execute
        response = self.command_executor.execute(driver_command, params)
    ../../../../status-app-prs@tmp/venv/lib/python3.10/site-packages/selenium/webdriver/remote/remote_connection.py:291: in execute
        return self._request(command_info[0], url, body=data)
    ../../../../status-app-prs@tmp/venv/lib/python3.10/site-packages/selenium/webdriver/remote/remote_connection.py:312: in _request
        response = self._conn.request(method, url, body=body, headers=headers)
    ../../../../status-app-prs@tmp/venv/lib/python3.10/site-packages/urllib3/request.py:78: in request
        return self.request_encode_body(
    ../../../../status-app-prs@tmp/venv/lib/python3.10/site-packages/urllib3/request.py:170: in request_encode_body
        return self.urlopen(method, url, **extra_kw)
    ../../../../status-app-prs@tmp/venv/lib/python3.10/site-packages/urllib3/poolmanager.py:376: in urlopen
        response = conn.urlopen(method, u.request_uri, **kw)
    ../../../../status-app-prs@tmp/venv/lib/python3.10/site-packages/urllib3/connectionpool.py:787: in urlopen
        retries = retries.increment(
    ../../../../status-app-prs@tmp/venv/lib/python3.10/site-packages/urllib3/util/retry.py:550: in increment
        raise six.reraise(type(error), error, _stacktrace)
    ../../../../status-app-prs@tmp/venv/lib/python3.10/site-packages/urllib3/packages/six.py:769: in reraise
        raise value.with_traceback(tb)
    ../../../../status-app-prs@tmp/venv/lib/python3.10/site-packages/urllib3/connectionpool.py:703: in urlopen
        httplib_response = self._make_request(
    ../../../../status-app-prs@tmp/venv/lib/python3.10/site-packages/urllib3/connectionpool.py:449: in _make_request
        six.raise_from(e, None)
    <string>:3: in raise_from
        ???
    ../../../../status-app-prs@tmp/venv/lib/python3.10/site-packages/urllib3/connectionpool.py:444: in _make_request
        httplib_response = conn.getresponse()
    /usr/lib/python3.10/http/client.py:1375: in getresponse
        response.begin()
    /usr/lib/python3.10/http/client.py:318: in begin
        version, status, reason = self._read_status()
    /usr/lib/python3.10/http/client.py:287: in _read_status
        raise RemoteDisconnected("Remote end closed connection without"
     ('Connection aborted.', RemoteDisconnected('Remote end closed connection without response'))
    



    Device sessions

    Class TestGroupChatMultipleDeviceMergedNewUI:

    1. test_group_chat_join_send_text_messages_push, id: 702807

    Device 2: Find Text by xpath: //*[starts-with(@text,'Hey, admin!')]/ancestor::android.view.ViewGroup[@content-desc='chat-item']//*[@content-desc='message-status']/android.widget.TextView
    Device 2: Text is Sent

    critical/chats/test_group_chat.py:95: in test_group_chat_join_send_text_messages_push
        self.chats[1].chat_element_by_text(message_to_admin).wait_for_status_to_be('Delivered', timeout=120)
    ../views/chat_view.py:225: in wait_for_status_to_be
        raise TimeoutException("Message status was not changed to %s, it's %s" % (expected_status, current_status))
     Message status was not changed to Delivered, it's Sent
    



    Device sessions

    Class TestCommunityMultipleDeviceMerged:

    1. test_community_edit_delete_message_when_offline, id: 704615

    Device 1: Looking for a message by text: text after edit
    Device 1: Looking for a message by text: message to delete

    critical/chats/test_public_chat_browsing.py:798: in test_community_edit_delete_message_when_offline
        self.errors.verify_no_errors()
    base_test_case.py:190: in verify_no_errors
        pytest.fail('\n '.join([self.errors.pop(0) for _ in range(len(self.errors))]))
     Updated message 'text after edit' is not delivered to the receiver
    



    Device sessions

    Class TestActivityMultipleDevicePR:

    1. test_activity_center_reply_read_unread_delete_filter_swipe, id: 702947

    Device 1: Tap on found: Button
    Device 1: Swiping left on element ActivityCenterElement

    activity_center/test_activity_center.py:379: in test_activity_center_reply_read_unread_delete_filter_swipe
        reply_element.swipe_left_on_element()
    ../views/base_element.py:301: in swipe_left_on_element
        location, size = self.get_element_coordinates()
    ../views/base_element.py:294: in get_element_coordinates
        element = self.find_element()
    ../views/base_element.py:444: in find_element
        raise NoSuchElementException(
     Device 1: `ActivityCenterElement` by `xpath`:`//*[contains(@text, 'this is a reply')]/ancestor::*[@content-desc='activity']` not found on the screen; For documentation on this error, please visit: https://www.selenium.dev/documentation/webdriver/troubleshooting/errors#no-such-element-exception
    



    Device sessions

    Expected to fail tests (2)

    Click to expand

    Class TestGroupChatMultipleDeviceMergedNewUI:

    1. test_group_chat_mute_chat, id: 703495

    # STEP: Change device time so chat will be unmuted by timer
    Device 2: Long press on ChatElement

    critical/chats/test_group_chat.py:464: in test_group_chat_mute_chat
        self.errors.verify_no_errors()
    base_test_case.py:190: in verify_no_errors
        pytest.fail('\n '.join([self.errors.pop(0) for _ in range(len(self.errors))]))
     Chat is still muted after timeout 
    

    [[Chat is not unmuted after expected time: https://github.com//issues/19627]]

    Device sessions

    Class TestCommunityOneDeviceMerged:

    1. test_community_discovery, id: 703503

    Test is not run, e2e blocker  
    

    [[reason: [NOTRUN] Curated communities not loading, https://github.com//issues/17852]]

    Passed tests (39)

    Click to expand

    Class TestCommunityMultipleDeviceMergedTwo:

    1. test_community_markdown_support, id: 702809
    Device sessions

    2. test_community_hashtag_links_to_community_channels, id: 702948
    Device sessions

    3. test_community_mentions_push_notification, id: 702786
    Device sessions

    4. test_community_leave, id: 702845
    Device sessions

    5. test_community_join_when_node_owner_offline, id: 703629
    Device sessions

    Class TestActivityMultipleDevicePR:

    1. test_navigation_jump_to, id: 702936
    Device sessions

    Class TestOneToOneChatMultipleSharedDevicesNewUi:

    1. test_1_1_chat_text_message_delete_push_disappear, id: 702733
    Device sessions

    2. test_1_1_chat_push_emoji, id: 702813
    Device sessions

    3. test_1_1_chat_non_latin_messages_stack_update_profile_photo, id: 702745
    Device sessions

    4. test_1_1_chat_edit_message, id: 702855
    Device sessions

    5. test_1_1_chat_send_image_save_and_share, id: 703391
    Device sessions

    6. test_1_1_chat_pin_messages, id: 702731
    Device sessions

    7. test_1_1_chat_message_reaction, id: 702730
    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

    3. test_community_undo_delete_message, id: 702869
    Device sessions

    4. test_community_navigate_to_channel_when_relaunch, id: 702846
    Device sessions

    5. test_community_mute_community_and_channel, id: 703382
    Device sessions

    Class TestActivityCenterContactRequestMultipleDevicePR:

    1. test_add_contact_field_validation, id: 702777
    Device sessions

    2. test_activity_center_contact_request_decline, id: 702850
    Device sessions

    Class TestGroupChatMultipleDeviceMergedNewUI:

    1. test_group_chat_pin_messages, id: 702732
    Device sessions

    2. test_group_chat_send_image_save_and_share, id: 703297
    Device sessions

    3. test_group_chat_reactions, id: 703202
    Device sessions

    4. test_group_chat_offline_pn, id: 702808
    Device sessions

    Class TestCommunityMultipleDeviceMerged:

    1. test_community_several_images_send_reply, id: 703194
    Device sessions

    2. test_community_one_image_send_reply, id: 702859
    Device sessions

    3. test_community_emoji_send_copy_paste_reply, id: 702840
    Device sessions

    4. test_community_mark_all_messages_as_read, id: 703086
    Device sessions

    5. test_community_contact_block_unblock_offline, id: 702894
    Device sessions

    6. test_community_message_delete, id: 702839
    Device sessions

    7. test_community_message_send_check_timestamps_sender_username, id: 702838
    Device sessions

    8. test_community_links_with_previews_github_youtube_twitter_gif_send_enable, id: 702844
    Device sessions

    9. test_community_message_edit, id: 702843
    Device sessions

    10. test_community_unread_messages_badge, id: 702841
    Device sessions

    Class TestActivityMultipleDevicePRTwo:

    1. test_activity_center_mentions, id: 702957
    Device sessions

    2. test_activity_center_admin_notification_accept_swipe, id: 702958
    Device sessions

    Class TestOneToOneChatMultipleSharedDevicesNewUiTwo:

    1. test_1_1_chat_delete_via_long_press_relogin, id: 702784
    Device sessions

    2. test_1_1_chat_is_shown_message_sent_delivered_from_offline, id: 702783
    Device sessions

    3. test_1_1_chat_mute_chat, id: 703496
    Device sessions

    Signed-off-by: Brian Sztamfater <[email protected]>
    @briansztamfater briansztamfater force-pushed the chore/add-wallet-connect-package branch from c96818c to 6d7e7f9 Compare May 8, 2024 08:41
    @briansztamfater briansztamfater merged commit 07fb361 into develop May 8, 2024
    6 checks passed
    Pipeline for QA automation moved this from E2E Tests to DONE May 8, 2024
    @briansztamfater briansztamfater deleted the chore/add-wallet-connect-package branch May 8, 2024 08:51
    Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
    Projects
    Development

    Successfully merging this pull request may close these issues.

    None yet

    9 participants