@comapeo/core 4.1.3 → 4.1.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json
CHANGED
|
@@ -5,7 +5,7 @@ import ensureError from 'ensure-error'
|
|
|
5
5
|
import { TimeoutError } from '../errors.js'
|
|
6
6
|
|
|
7
7
|
const RECEIVE_PROJECT_DETAILS_TIMEOUT_MS = 45_000
|
|
8
|
-
const ADD_PROJECT_TIMEOUT_MS =
|
|
8
|
+
const ADD_PROJECT_TIMEOUT_MS = 300_000
|
|
9
9
|
|
|
10
10
|
/** @import { StringToTaggedUnion } from '../types.js' */
|
|
11
11
|
/** @import { ProjectJoinDetails } from '../generated/rpc.js' */
|
package/src/mapeo-manager.js
CHANGED
|
@@ -708,14 +708,14 @@ export class MapeoManager extends TypedEmitter {
|
|
|
708
708
|
*
|
|
709
709
|
* @param {MapeoProject} project
|
|
710
710
|
* @param {object} [opts]
|
|
711
|
-
* @param {number} [opts.timeoutMs=
|
|
711
|
+
* @param {number} [opts.timeoutMs=45_000] Timeout in milliseconds for max time
|
|
712
712
|
* to wait between sync status updates before giving up. As long as syncing is
|
|
713
713
|
* happening, this will never timeout, but if more than timeoutMs passes
|
|
714
714
|
* without any sync activity, then this will resolve `false` e.g. data has not
|
|
715
715
|
* synced
|
|
716
716
|
* @returns {Promise<boolean>}
|
|
717
717
|
*/
|
|
718
|
-
async #waitForInitialSync(project, { timeoutMs =
|
|
718
|
+
async #waitForInitialSync(project, { timeoutMs = 45_000 } = {}) {
|
|
719
719
|
const [ownRole, isProjectSettingsSynced] = await Promise.all([
|
|
720
720
|
project.$getOwnRole(),
|
|
721
721
|
project.$hasSyncedProjectSettings(),
|