Summary:
Previously, when adding an account, we waited for it to be completely loaded (which meant having fetched the folder list) before focusing it on the sidebar. This could take several seconds, so it made the app feel unresponsive or slow when adding an account.
Then, we changed the logic to wait an arbitrary amount of time to focus the newly added account in the sidebar, with the hope that it would be enough time to focus it correctly but that it wouldn't seem too long. This still caused the unwanted effect of focusing it before it had been fully loaded.
This commit changes the auth flow so that the onboarding shows a Success page until the newly added account is fully loaded, and only /then/ closes itself, focuses the main window, and allows the account to be correctly focused in the sidebar.
Test Plan: manual
Reviewers: halla, evan
Reviewed By: evan
Differential Revision: https://phab.nylas.com/D3751
Summary:
This diff modifies the SearchIndexer class to handle limiting the search
index size. It does this by periodically re-evaluating the window of
the n most recent items in a particular index where n is the max size of
the index. It then unindexes the items which are marked as indexed but
are no longer in the window and indexes the things that are in the window
but aren't marked as indexed.
Test Plan:
Run locally with a reduced thread index size, verify that the index
includes the most recent items and that it is the correct size. Also verify that
the queries used properly use fast sqlite indices.
Reviewers: evan, juan
Reviewed By: evan
Differential Revision: https://phab.nylas.com/D3741
Summary:
When the search index got very big the queries we were running during
after keypress would cause jank in the UI which was very noticeable on
subsequent keypresses. This diff backgrounds these queries and adds a
LIMIT to the fts MATCH clauses to avoid having to send too much stuff
across the IPC bridge.
Test Plan: Run locally, make sure that typing is smooth while searching
Reviewers: juan, evan
Reviewed By: juan, evan
Differential Revision: https://phab.nylas.com/D3757
Summary: See title
Test Plan: tested locally
Reviewers: juan, mark, evan
Reviewed By: juan, mark
Subscribers: juan
Differential Revision: https://phab.nylas.com/D3744
Summary:
- Add a new button to the sync error notification to "Debug" sync. This will open the activity window and dev tools in that window. Depends on D3736
- Update the "Contact Support" link in error notifications to prepopulate the support ticket with the sync error in the account
- Make the "Check Again" button react when clicking it
Test Plan: manual
Reviewers: evan, khamidou
Reviewed By: evan, khamidou
Differential Revision: https://phab.nylas.com/D3737
Summary:
- Make the try again button react when clicked
- Don't mark as offline until after we've tried again at least 3 times
Test Plan: manual
Reviewers: evan
Reviewed By: evan
Differential Revision: https://phab.nylas.com/D3738
Summary:
- Refactor Gmail auth functions
- Add Analytics in
- Show error states
Depends on D3735
Test Plan: manual
Reviewers: khamidou, juan
Reviewed By: khamidou, juan
Differential Revision: https://phab.nylas.com/D3732
Summary:
We changed the index format (splitting participants into to and from) so
we need to update the index version so that it gets rebuilt.
Test Plan: Run locally, make sure index gets rebuilt
Reviewers: evan, juan
Reviewed By: juan
Differential Revision: https://phab.nylas.com/D3728
Summary:
Previously we indexed all participants together for a single thread.
This lead to confusing search results when people would search for
'from' and get back lots of results that were only 'to'. This diff
splits the participants index into separate to and from indices and
updates the query generator appropriately.
Fixes T7580
Test Plan: Run locally, verify from doesn't return to and vice versa.
Reviewers: evan, juan
Reviewed By: juan
Maniphest Tasks: T7580
Differential Revision: https://phab.nylas.com/D3724
Summary:
If we don't have IMAP settings for a particular email domain,
try to choose based on which provider was selected instead.
Fixes#3168
Test Plan: tested locally
Reviewers: spang, evan
Reviewed By: evan
Differential Revision: https://phab.nylas.com/D3721
Summary:
Some strange scenario is causing us to attempt to redefine the object property `_delta` on our `delta.attributes` object inside `DeltaProcessor._decorateDeltas`, which throws an error, and consequently throws the app into an error loop. I haven't been able to track down how to reproduce this, but when it happens it completely takes the app down.
From testing with tomasz's copy of N1, this seemed to have originated from the lack of Account tokens, which was hard to discover because the `_deltas` object completely floods the console with errors.
From what I gather, `_decorateDeltas` is only called from a single place, `DeltaProcessor.process`, which is also only called from a single place, and its unclear how it would be called multiple times with the same delta object references.
In order to prevent this error from completely destroying the app, I've added the `configurable` option when defining the property, so that redifining it doesn't throw an error. It should be safe to redefine this property with the latest delta reference, and will also allow us to discover other errors more easily in the console like the lack of account tokens which might be the original cause of this problem.
Test Plan: manual
Reviewers: mark, spang, evan, halla
Reviewed By: evan, halla
Differential Revision: https://phab.nylas.com/D3717
Summary:
Makes these messages update even if the user doesn't force a
re-render by switching perspectives.
Test Plan: tested manually
Reviewers: evan, juan
Reviewed By: juan
Differential Revision: https://phab.nylas.com/D3715
Summary:
We had to add the id to the index as well (along with is_search_indexed)
so that the query worked correctly since it sorts by id. Also added a
default value of 0 for boolean attributes so that we don't have to query
for two different values (0 and null), which was causing sqlite to have to
do a final b-tree sort which is slow.
Test Plan: Run locally, verify query plan with EXPLAIN QUERY PLAN
Reviewers: evan, juan
Reviewed By: juan
Differential Revision: https://phab.nylas.com/D3712
Use staging autoupdater for staging.
fixed failing test
Fix autoupdater – we were using the wrong command.
Revert "Bump version to 1.5.0"
Temporarily reverting this because I need to test the upgrade path from
0.4.2 => 1.5.0
Revert "Revert "Bump version to 1.5.0""
Had to do this to test the autoupdater.
[fix] [channel drop-down list] Show the stable channel in all cases.
Conflicts:
internal_packages/preferences/lib/tabs/update-channel-section.jsx
Fix broken autoupdater, for reals.
[master] Replace "Nylas N1" by "Nylas Mail" in build scripts
Summary: As discussed --- we need to make those changes to make the autoupdater work across versions.
Test Plan: Will run a build.
Reviewers: evan
Reviewed By: evan
Differential Revision: https://phab.nylas.com/D3701
Revert "Revert "Revert "Bump version to 1.5.0"""
Need to set the version to 0.4.402 for testing purposes.
Set preferredChannel in the autoupdater instead of in the ChannelStore
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.
Conflicts:
src/flux/stores/update-channel-store.es6
Set the autoupdater preferredChannel to stable.
Don't try to move the app file to the Application folder ourselves
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.
Conflicts:
internal_packages/verify-install-location/lib/main.es6
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
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
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
The css class was accidentally renamed in another commit. Bring it back and
remove the hard-coded ellipses, since the ellipsis is now part of a css
psuedo element.
Summary:
This diff takes out the progress bars, since they can appear to
not move for very large mailboxes. Instead, just show an icon that
indicates whether the sync is complete or in progress, and add a
tooltip that displays how far back the folder has been synced to.
Submodule commit is D3662
Test Plan: tested locally
Reviewers: evan, juan
Reviewed By: evan, juan
Differential Revision: https://phab.nylas.com/D3663