-
Notifications
You must be signed in to change notification settings - Fork 984
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
[perf] network module #8392
[perf] network module #8392
Conversation
Pull Request Checklist
|
Jenkins BuildsClick to see older builds (21)
|
9f933de
to
b994d2a
Compare
✔️ status-react/prs/ios/PR-8392#3 🔹 ~15 min 🔹 b994d2a 🔹 📦 ios package |
@@ -0,0 +1,20 @@ | |||
(ns status-im.accounts.model |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
i believe usually we use core name
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
not really, the code from db
ns was moved there in order to solve circular dependency. It is "must contain getter and setter functions used by fx producing functions and subscriptions" from https://github.com/status-im/status-react/blob/develop/doc/codebase-structure-and-guidelines.md , which has no real reason to be in the same ns with specs. I can rename it differently if you have some ideas.
[re-frame.core :as re-frame] | ||
[status-im.utils.utils :as utils])) | ||
|
||
(handlers/register-handler-fx |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
with new fx/defn we don't need to separate events anymore, just use {:events []} in fx/defn and you can move all these handlers to core
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The whole objective was rather to rearrange code so that it can be compiled as a module, not to rewrite it. I know about this but it can be rewritten later if necessary.
;; Preloaded handlers, subs, functions | ||
|
||
(re-frame/reg-sub | ||
:get-network-id |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
why this sub is here not in subs?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
because this sub is needed outside of module right after logging in, when the rest of module's namespaces can still wait to be loaded. It could be put into a separate ns, but wouldn't make too much difference.
66% of end-end tests have passed
Failed tests (16)Click to expand
Passed tests (31)Click to expand
|
@rasom would you mind to rebase please? We have new sign txn screen in develop, this is the reason for autotests to fail. Thank you! |
@asemiankevich it was rebased before your comment |
68% of end-end tests have passed
Failed tests (15)Click to expand
Passed tests (32)Click to expand
|
98% of end-end tests have passed
Failed tests (1)Click to expand
Passed tests (46)Click to expand |
100% of end-end tests have passed
Passed tests (1) |
please review only the last commit
status-im.screens.ui.network.*
was moved tostatus-im.network.ui.*
accounts
module was a bit rearranged in order to fix cyclic depss.utils.handlers -> s.accounts.db -> s.newtork.module -> s.network.events -> s.utils.handlers
status: ready