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

Allow mainchain to switch to different service url #5391

Conversation

oskarleonard
Copy link
Contributor

@oskarleonard oskarleonard commented Oct 16, 2023

What was the problem?

This PR resolves #5357

How was it solved?

  • Check if provided custom network URL has valid ServiceURLs before letting the user save the new network
  • When switching to a new network, check if serviceURL is OK, might be serviceURL nr 2, in that case choose URL nr 2
  • When opening the app, check if serviceURL is OK, might be serviceURL nr 2, in that case choose URL nr 2

How was it tested?

Prerequisite

You need to modify the endpoint returning serviceURLs, this we can do by modifying the response in docker, replace serviceURLs with:

[
  {
    "http": "http://localcrash:8080",
    "ws": "ws://localcrash:9901",
  },
  {
    "http": "http://127.0.0.1:9901",
    "ws": "ws://127.0.0.1:9901",
  }
]

The first item in that array should have a http that crashes.

Please refer to the below video.

Screen.Recording.2023-10-27.at.11.41.39.mov

Test the scenarios in "How was it solved?"

@oskarleonard oskarleonard self-assigned this Oct 16, 2023
@oskarleonard oskarleonard marked this pull request as draft October 16, 2023 11:13
@oskarleonard oskarleonard marked this pull request as ready for review October 27, 2023 10:31
ikem-legend
ikem-legend previously approved these changes Oct 30, 2023
ikem-legend
ikem-legend previously approved these changes Oct 31, 2023
@eniolam1000752 eniolam1000752 merged commit 4acfc91 into release/3.0.0 Oct 31, 2023
6 checks passed
@eniolam1000752 eniolam1000752 deleted the 5357-allow-mainchain-to-switch-to-different-service-url branch October 31, 2023 16:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants