mirror of
https://github.com/Foundry376/Mailspring.git
synced 2025-01-11 02:30:21 +08:00
8633058488
Summary: Previously, we would initialize an `AccountPool` with an account instance and reference the account as an instance variable. Then, every time we created a connection, we used the account we had a reference to obtain the credentials. However, if the credentials on the account changed, e.g. when we refresh the access token for gmail accounts, the connection pool would never realize that the account had new credentials and always try to create the connection with the old credentials, causing the sync worker to enter an error loop of `Invalid credentials` errors To fix this, we could reload the account every time we try to create a connection, but it seems that the fresh credentials should just be passed every time we create connections without the pool having to be aware of potential changes under the rug. This commit makes it so the pool no longer holds a reference to the account, but rather it is passed in every time we check out a connection Test Plan: manual. how did this even work before? :( Reviewers: evan, halla, spang, mark Reviewed By: mark Differential Revision: https://phab.nylas.com/D4370 |
||
---|---|---|
.. | ||
client-app | ||
client-sync | ||
isomorphic-core | ||
README.md |
Monorepo Packages
Each folder here is designed to act as its own repository. For development convenience, they are all included here in one monorepo. This allows us to grep across multiple codebases, not use submodules, and keep a unified commit history.
We use Lerna to manage the monorepo and tie
them all together with the main nylas-mail-all/scripts/postinstall.es6
script,
which in turn, calls lerna bootstrap