@primitive.ai/prim 0.1.0-alpha.75 → 0.1.0-alpha.76

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.
@@ -32175,6 +32175,7 @@ var MODE = "install_intent_v1";
32175
32175
  var START_PATH = "/api/cli/github/install-intents";
32176
32176
  var POLL_REQUEST_TIMEOUT_MS2 = 1e4;
32177
32177
  var MAX_INTENT_LIFETIME_MS = 15 * 6e4;
32178
+ var MAX_SERVER_CLOCK_AHEAD_MS = 3e4;
32178
32179
  var REPOSITORY_IDENTITY_MIGRATION_REQUIRED = "repository_identity_migration_required";
32179
32180
  function isRepositoryIdentityMigrationRequiredStatus(value) {
32180
32181
  if (typeof value !== "object" || value === null || Array.isArray(value)) {
@@ -32190,7 +32191,7 @@ function isRepositoryIdentityMigrationRequiredStatus(value) {
32190
32191
  });
32191
32192
  }
32192
32193
  function parseGitHubInstallIntentStart(value, now = Date.now()) {
32193
- if (!isGitHubInstallIntentStartResponse(value) || value.expiresAt <= now || value.expiresAt - now > MAX_INTENT_LIFETIME_MS) {
32194
+ if (!isGitHubInstallIntentStartResponse(value) || value.expiresAt <= now || value.expiresAt - now > MAX_INTENT_LIFETIME_MS + MAX_SERVER_CLOCK_AHEAD_MS) {
32194
32195
  return null;
32195
32196
  }
32196
32197
  return value;
package/dist/index.js CHANGED
@@ -9904,6 +9904,7 @@ var MODE = "install_intent_v1";
9904
9904
  var START_PATH = "/api/cli/github/install-intents";
9905
9905
  var POLL_REQUEST_TIMEOUT_MS = 1e4;
9906
9906
  var MAX_INTENT_LIFETIME_MS = 15 * 6e4;
9907
+ var MAX_SERVER_CLOCK_AHEAD_MS = 3e4;
9907
9908
  var REPOSITORY_IDENTITY_MIGRATION_REQUIRED = "repository_identity_migration_required";
9908
9909
  function isRepositoryIdentityMigrationRequiredStatus(value) {
9909
9910
  if (typeof value !== "object" || value === null || Array.isArray(value)) {
@@ -9919,7 +9920,7 @@ function isRepositoryIdentityMigrationRequiredStatus(value) {
9919
9920
  });
9920
9921
  }
9921
9922
  function parseGitHubInstallIntentStart(value, now = Date.now()) {
9922
- if (!isGitHubInstallIntentStartResponse(value) || value.expiresAt <= now || value.expiresAt - now > MAX_INTENT_LIFETIME_MS) {
9923
+ if (!isGitHubInstallIntentStartResponse(value) || value.expiresAt <= now || value.expiresAt - now > MAX_INTENT_LIFETIME_MS + MAX_SERVER_CLOCK_AHEAD_MS) {
9923
9924
  return null;
9924
9925
  }
9925
9926
  return value;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@primitive.ai/prim",
3
- "version": "0.1.0-alpha.75",
3
+ "version": "0.1.0-alpha.76",
4
4
  "description": "CLI for Primitive's decision graph — passive decision capture, conflict gate, and team presence",
5
5
  "type": "module",
6
6
  "license": "MIT",