bunnyquery 1.10.4 → 1.10.6

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/bunnyquery.js CHANGED
@@ -3499,6 +3499,7 @@ Index the REMAINING windows - one record per row/item, looking at any page image
3499
3499
  var LIVE_INDEX_SNAPSHOT_MAX_AGE_MS = 5e3;
3500
3500
  var INDEX_DISPATCH_CLAIM_MS = 2 * 60 * 1e3;
3501
3501
  var WORKER_PASS_ADOPT_ATTEMPTS = [0, 2e3, 6e3];
3502
+ var RECENT_INDEX_PASS_EVIDENCE_MS = 10 * 60 * 1e3;
3502
3503
  var EARLY_PROBE_SCHEDULE_MS = [400, 900, 1700];
3503
3504
  var INDEXING_DRAIN_BUSY_POLL_MS = 8e3;
3504
3505
  var INDEXING_DRAIN_CONFIRM_POLL_MS = 3e3;
@@ -6691,7 +6692,16 @@ Index the REMAINING windows - one record per row/item, looking at any page image
6691
6692
  this.historyItemPolls.forEach(function(h) {
6692
6693
  if (h && h.kind === "bg") found = true;
6693
6694
  });
6694
- return found;
6695
+ if (found) return true;
6696
+ var cutoff = Date.now() - RECENT_INDEX_PASS_EVIDENCE_MS;
6697
+ var msgs = this.state.messages;
6698
+ for (var mi = msgs.length - 1; mi >= 0; mi--) {
6699
+ var m = msgs[mi];
6700
+ if (!m || !m._indexFile) continue;
6701
+ if (typeof m._ts !== "number") continue;
6702
+ if (m._ts >= cutoff) return true;
6703
+ }
6704
+ return false;
6695
6705
  }
6696
6706
  /** Any of these ids still queued or still polled, i.e. surviving work. */
6697
6707
  _isTrackingAny(ids) {
@@ -8253,7 +8263,7 @@ Index the REMAINING windows - one record per row/item, looking at any page image
8253
8263
  (function() {
8254
8264
  var MCP_PROD = "https://mcp.broadwayinc.computer";
8255
8265
  var MCP_DEV = "https://mcp-dev.broadwayinc.computer";
8256
- var BQ_VERSION = "1.10.4" ;
8266
+ var BQ_VERSION = "1.10.6" ;
8257
8267
  var ATTACHMENT_URL_EXPIRES_SECONDS = 600;
8258
8268
  var GOOGLE_AUTH_URL = "https://accounts.google.com/o/oauth2/v2/auth";
8259
8269
  var GOOGLE_TOKEN_URL = "https://oauth2.googleapis.com/token";
package/dist/engine.cjs CHANGED
@@ -3643,6 +3643,7 @@ var WORKER_PASS_ADOPT_LIMIT = 20;
3643
3643
  var LIVE_INDEX_SNAPSHOT_MAX_AGE_MS = 5e3;
3644
3644
  var INDEX_DISPATCH_CLAIM_MS = 2 * 60 * 1e3;
3645
3645
  var WORKER_PASS_ADOPT_ATTEMPTS = [0, 2e3, 6e3];
3646
+ var RECENT_INDEX_PASS_EVIDENCE_MS = 10 * 60 * 1e3;
3646
3647
  var EARLY_PROBE_SCHEDULE_MS = [400, 900, 1700];
3647
3648
  var INDEXING_DRAIN_BUSY_POLL_MS = 8e3;
3648
3649
  var INDEXING_DRAIN_CONFIRM_POLL_MS = 3e3;
@@ -6835,7 +6836,16 @@ var ChatSession = class {
6835
6836
  this.historyItemPolls.forEach(function(h) {
6836
6837
  if (h && h.kind === "bg") found = true;
6837
6838
  });
6838
- return found;
6839
+ if (found) return true;
6840
+ var cutoff = Date.now() - RECENT_INDEX_PASS_EVIDENCE_MS;
6841
+ var msgs = this.state.messages;
6842
+ for (var mi = msgs.length - 1; mi >= 0; mi--) {
6843
+ var m = msgs[mi];
6844
+ if (!m || !m._indexFile) continue;
6845
+ if (typeof m._ts !== "number") continue;
6846
+ if (m._ts >= cutoff) return true;
6847
+ }
6848
+ return false;
6839
6849
  }
6840
6850
  /** Any of these ids still queued or still polled, i.e. surviving work. */
6841
6851
  _isTrackingAny(ids) {