Summary:
When we've optimistically created a category and haven't seen
it come back through the remote yet, `.object` does not
exist. Just look up the sync state for the entire account in
this case.
Fixes T7556
Test Plan: tested manually
Reviewers: spang, evan, juan
Reviewed By: juan
Maniphest Tasks: T7556
Differential Revision: https://phab.nylas.com/D3711
Summary:
We query based on these fields which would cause us to scan the entire
table if we don't have these indexes.
Test Plan: Run locally
Reviewers: evan, juan
Reviewed By: juan
Differential Revision: https://phab.nylas.com/D3710
Because of MacOS Gatekeeper path randomization issues
(https://github.com/Squirrel/Squirrel.Mac/issues/182) we need the user
to move the app themselves. Changed the dialog to ask them to do this
politely.
Summary:
This diff adds a new SearchIndexer class that each of the concrete
indexer implementations register with. This new class uses the
`isSearchIndexed` field in searchable classes to split indexing work
into chunks. It then times how long it takes to index each chunk and
schedules more work based on a target CPU percent. For example, if it
takes 150 ms to index the last chunk of work and the target CPU fraction
is 0.05 (i.e. 5% CPU use) then it will schedule the next increment of
indexing 3 seconds in the future.
Test Plan: Run locally, verify that indexing occurs in increments
Reviewers: juan, evan
Reviewed By: evan
Differential Revision: https://phab.nylas.com/D3707
Summary:
Also fix a related rendering issue and remove unused code.
Fixes T7538
Test Plan: tested locally
Reviewers: evan, spang, juan
Reviewed By: spang, juan
Maniphest Tasks: T7538
Differential Revision: https://phab.nylas.com/D3704
It turns out that Squirrel checks for update at program launch. In some
cases, it would put Pro users on the "nylas-mail" channel because that's
the default channel if you don't pass a preferredChannel.
Summary:
This will make send for a single recipient faster, and open/link
tracking will continue to work as expected
Test Plan: manual
Reviewers: evan, halla
Reviewed By: halla
Differential Revision: https://phab.nylas.com/D3702
Summary:
The isModelIndexed function was extremely slow because it was scanning
the unindexed 'content_id' field in the search index table. This diff
adds a field to the searchable models (currently Thread, Contact, and
Event) that stores whether that particular model has been indexed or
not, allowing us to avoid doing the O(n) scan of the search index table.
Test Plan: Run locally, verify that isModelIndexed is no longer a bottleneck
Reviewers: juan, evan
Reviewed By: evan
Differential Revision: https://phab.nylas.com/D3695
Summary:
Lots of components were rendering when they didn't have to on the very
frequent account sidebar updates
Test Plan: manual
Reviewers: mark, juan
Reviewed By: juan
Differential Revision: https://phab.nylas.com/D3691
We've got a plethora of "unique" ids for the same account and ot looks
like a recent regression is preventing us from fetching an API token for
an account from the keychain. This diff changes the AccountStore to be
able to fetch data using an account's email address. Will figure how to
do things better after launch.
Test plan: Checked that it worked for a broken account.
Summary:
Fixes T7520
Gets rid of the Gmail auth error too
Test Plan: manual
Reviewers: juan
Reviewed By: juan
Maniphest Tasks: T7520
Differential Revision: https://phab.nylas.com/D3688
Summary:
Removes references to the N1 ID expring.
Luckily, local-sync Nylas Mail Basic doesn't need the nylas ID to do
pretty much anything, which means we don't need to worry about the "trial"
status of the Nylas ID. The existing trial infrastructure will only kick
into place when someone connects an email account with the Nylas Cloud
Sync servers for the first time.
The one place we do check for the Nylas ID is in the
cloud-api/src/authentication route. Here we hit
https://billing.nylas.com/n1/user and simply expect to get back a Nylas
ID. As long as we return the existence of a Nylas ID (which should ignore
whether or not the old subscription system is "valid"), the API calls will
succeed.
This makes the "Upgrade Now" button go to
billing.nylas.com/dashboard?upgrade_to_pro=true with the auto-sign in
features enabled. This will automatically log the user into the Nylas
billing site with the upgrade_to_pro=true flag set.
There is also a new "Learn More" button which goes to
https://nylas.com/nylas-pro.
@mike, will these urls work?
Test Plan: manual
Reviewers: khamidou, mike, juan
Reviewed By: juan
Subscribers: mike
Differential Revision: https://phab.nylas.com/D3680
Summary:
Also fixes an issue where we would show all any accounts
that aren't gmail or office365 as a generic imap account.
Depends on D3686
Test Plan: manual
Reviewers: juan, evan
Reviewed By: evan
Differential Revision: https://phab.nylas.com/D3687
Summary:
This is a very expensive operation and there seemed to be few downsides
to including quoted portions in the index. We can revisit this to
improve how we index when we have a proper scheduler.
Test Plan: Run locally
Reviewers: juan, evan
Reviewed By: evan
Differential Revision: https://phab.nylas.com/D3682