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

Refactor Network Settings Actions #358

Open
9 tasks done
alexruzenhack opened this issue Oct 20, 2023 · 0 comments
Open
9 tasks done

Refactor Network Settings Actions #358

alexruzenhack opened this issue Oct 20, 2023 · 0 comments
Assignees

Comments

@alexruzenhack
Copy link
Contributor

alexruzenhack commented Oct 20, 2023

The NETWORKSETTINGS_* actions are not conveying the best meaning, as stated in this commit 095510f and this comment on PR(10)#350. Here is a proposal to change it:

Actions

  • NETWORKSETTINGS_UPDATE_REQUEST: an action triggered by user to update the network settings submitted through the form
  • NETWORKSETTINGS_PERSIST_STORE: an action triggered by an update effect demanding that the network settings produced by it be persisted in the app storage
  • NETWORKSETTINGS_UPDATE_STATE: an action triggered by init effect to update the Redux state with the custom network settings stored
  • NETWORKSETTINGS_UPDATE_WAITING: an action triggered by persist effect to indicate that the persistence is complete and the wallet needs to be reloaded
  • NETWORKSETTINGS_UPDATE_SUCCESS: an action triggered after wallet reload and the current network settings status is WAITING.
  • NETWORKSETTINGS_UPDATE_INVALID: an action triggered by update request effect to mark the request as invalid
  • NETWORKSETTINGS_UPDATE_FAILURE: an action triggered by either the update effect or the persist effect, controlled by the network settings saga, to indicate that the update has failed
    - [ ] NETWORKSETTINGS_UPDATE_STATUS: action triggered to change network settings status either for READY or LOADING

Statuses

  • READY: default status
  • LOADING: once the update request is made
  • WAITING: once the network settings are persisted
  • SUCCESSFUL: once the update succeeds
  • FAILED: once the update fails
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

No branches or pull requests

1 participant