@sourcegraph/cody-web 0.36.0 → 0.38.0

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.
@@ -46,7 +46,7 @@ function getAugmentedNamespace(n) {
46
46
  });
47
47
  return a3;
48
48
  }
49
- var define_process_default$c = { env: {} };
49
+ var define_process_default$d = { env: {} };
50
50
  var LIB;
51
51
  (() => {
52
52
  var t3 = { 470: (t22) => {
@@ -85,7 +85,7 @@ var LIB;
85
85
  var n2 = { resolve: function() {
86
86
  for (var t32, n3 = "", i2 = false, o = arguments.length - 1; o >= -1 && !i2; o--) {
87
87
  var s3;
88
- o >= 0 ? s3 = arguments[o] : (void 0 === t32 && (t32 = define_process_default$c.cwd()), s3 = t32), e22(s3), 0 !== s3.length && (n3 = s3 + "/" + n3, i2 = 47 === s3.charCodeAt(0));
88
+ o >= 0 ? s3 = arguments[o] : (void 0 === t32 && (t32 = define_process_default$d.cwd()), s3 = t32), e22(s3), 0 !== s3.length && (n3 = s3 + "/" + n3, i2 = 47 === s3.charCodeAt(0));
89
89
  }
90
90
  return n3 = r2(n3, !i2), i2 ? n3.length > 0 ? "/" + n3 : "/" : n3.length > 0 ? n3 : ".";
91
91
  }, normalize: function(t32) {
@@ -203,7 +203,7 @@ var LIB;
203
203
  var n = {};
204
204
  (() => {
205
205
  let t22;
206
- if (r.r(n), r.d(n, { URI: () => f, Utils: () => P }), "object" == typeof define_process_default$c) t22 = "win32" === define_process_default$c.platform;
206
+ if (r.r(n), r.d(n, { URI: () => f, Utils: () => P }), "object" == typeof define_process_default$d) t22 = "win32" === define_process_default$d.platform;
207
207
  else if ("object" == typeof navigator) {
208
208
  let e3 = navigator.userAgent;
209
209
  t22 = e3.indexOf("Windows") >= 0;
@@ -1358,6 +1358,9 @@ jsonDiff.castInput = function(value) {
1358
1358
  jsonDiff.equals = function(left, right) {
1359
1359
  return Diff.prototype.equals.call(jsonDiff, left.replace(/,([\r\n])/g, "$1"), right.replace(/,([\r\n])/g, "$1"));
1360
1360
  };
1361
+ function diffJson(oldObj, newObj, options) {
1362
+ return jsonDiff.diff(oldObj, newObj, options);
1363
+ }
1361
1364
  function canonicalize(obj, stack, replacementStack, replacer, key) {
1362
1365
  stack = stack || [];
1363
1366
  replacementStack = replacementStack || [];
@@ -2465,6 +2468,36 @@ function subscriptionDisposable(sub) {
2465
2468
  function disposableSubscription(disposable2) {
2466
2469
  return { unsubscribe: () => disposable2.dispose() };
2467
2470
  }
2471
+ function observableOfSequence(...values) {
2472
+ return new Observable((observer) => {
2473
+ for (const value of values) {
2474
+ observer.next(value);
2475
+ }
2476
+ observer.complete();
2477
+ });
2478
+ }
2479
+ function observableOfTimedSequence(...values) {
2480
+ return new Observable((observer) => {
2481
+ const scheduler = new AsyncSerialScheduler_1(observer);
2482
+ let unsubscribed = false;
2483
+ (async () => {
2484
+ for (const value of values) {
2485
+ if (unsubscribed) {
2486
+ break;
2487
+ }
2488
+ if (typeof value === "number") {
2489
+ await new Promise((resolve2) => setTimeout(resolve2, value));
2490
+ } else {
2491
+ scheduler.schedule(async (next) => next(value));
2492
+ }
2493
+ }
2494
+ scheduler.complete();
2495
+ })();
2496
+ return () => {
2497
+ unsubscribed = true;
2498
+ };
2499
+ });
2500
+ }
2468
2501
  async function firstValueFrom(observable, signal) {
2469
2502
  return new Promise((resolve2, reject) => {
2470
2503
  const subscription = observable.subscribe({
@@ -2489,6 +2522,9 @@ async function firstValueFrom(observable, signal) {
2489
2522
  }
2490
2523
  });
2491
2524
  }
2525
+ function toFirstValueGetter(fn) {
2526
+ return (...args) => firstValueFrom(fn(...args));
2527
+ }
2492
2528
  async function waitUntilComplete(observable) {
2493
2529
  return new Promise((resolve2, reject) => {
2494
2530
  observable.subscribe({
@@ -2497,6 +2533,63 @@ async function waitUntilComplete(observable) {
2497
2533
  });
2498
2534
  });
2499
2535
  }
2536
+ async function allValuesFrom(observable) {
2537
+ return new Promise((resolve2, reject) => {
2538
+ const values = [];
2539
+ const subscription = observable.subscribe({
2540
+ next: (value) => values.push(value),
2541
+ error: (error2) => {
2542
+ subscription.unsubscribe();
2543
+ reject(error2);
2544
+ },
2545
+ complete: () => {
2546
+ subscription.unsubscribe();
2547
+ resolve2(values);
2548
+ }
2549
+ });
2550
+ });
2551
+ }
2552
+ function promiseWithResolvers() {
2553
+ let resolve2 = () => {
2554
+ };
2555
+ let reject = () => {
2556
+ };
2557
+ const promise2 = new Promise((_resolve, _reject) => {
2558
+ resolve2 = _resolve;
2559
+ reject = _reject;
2560
+ });
2561
+ return { promise: promise2, resolve: resolve2, reject };
2562
+ }
2563
+ function readValuesFrom(observable) {
2564
+ const values = [];
2565
+ const { promise: promise2, resolve: resolve2, reject } = promiseWithResolvers();
2566
+ let status = "pending";
2567
+ const subscription = observable.subscribe({
2568
+ next: (value) => values.push(value),
2569
+ error: (err) => {
2570
+ reject(err);
2571
+ status = "error";
2572
+ },
2573
+ complete: () => {
2574
+ resolve2();
2575
+ status = "complete";
2576
+ }
2577
+ });
2578
+ const result = {
2579
+ values,
2580
+ clearValues: () => {
2581
+ values.length = 0;
2582
+ },
2583
+ done: promise2,
2584
+ unsubscribe: () => {
2585
+ subscription.unsubscribe();
2586
+ resolve2();
2587
+ status = "unsubscribed";
2588
+ },
2589
+ status: () => status
2590
+ };
2591
+ return result;
2592
+ }
2500
2593
  function promiseToObservable(promise2) {
2501
2594
  return new Observable((observer) => {
2502
2595
  promise2.then((value) => {
@@ -2695,6 +2788,23 @@ function fromVSCodeEvent(event, getInitialValue) {
2695
2788
  };
2696
2789
  });
2697
2790
  }
2791
+ function vscodeResource(create2) {
2792
+ return new Observable(() => {
2793
+ const disposable2 = create2();
2794
+ return () => {
2795
+ disposable2.dispose();
2796
+ };
2797
+ });
2798
+ }
2799
+ function disposeOnUnsubscribe(...disposables) {
2800
+ return new Observable(() => {
2801
+ return () => {
2802
+ for (const disposable2 of disposables) {
2803
+ disposable2.dispose();
2804
+ }
2805
+ };
2806
+ });
2807
+ }
2698
2808
  function createDisposables(create2) {
2699
2809
  let disposables;
2700
2810
  function disposeAll() {
@@ -2807,6 +2917,43 @@ function unsubscribeAll(subscriptions) {
2807
2917
  }
2808
2918
  }
2809
2919
  }
2920
+ function takeUntil(notifier) {
2921
+ return (source) => {
2922
+ return new Observable((observer) => {
2923
+ const sourceSubscription = source.subscribe({
2924
+ next: (value) => observer.next(value),
2925
+ error: (err) => observer.error(err),
2926
+ complete: () => observer.complete()
2927
+ });
2928
+ const notifierSubscription = notifier.subscribe({
2929
+ next: () => {
2930
+ observer.complete();
2931
+ sourceSubscription.unsubscribe();
2932
+ notifierSubscription.unsubscribe();
2933
+ },
2934
+ error: (err) => {
2935
+ observer.error(err);
2936
+ sourceSubscription.unsubscribe();
2937
+ }
2938
+ });
2939
+ return () => {
2940
+ sourceSubscription.unsubscribe();
2941
+ notifierSubscription.unsubscribe();
2942
+ };
2943
+ });
2944
+ };
2945
+ }
2946
+ function finalize(fn) {
2947
+ return (source) => {
2948
+ return new Observable((observer) => {
2949
+ const subscription = source.subscribe(observer);
2950
+ return () => {
2951
+ unsubscribe(subscription);
2952
+ fn();
2953
+ };
2954
+ });
2955
+ };
2956
+ }
2810
2957
  function distinctUntilChanged(isEqualFn = isEqual$1) {
2811
2958
  return (observable) => {
2812
2959
  return new Observable((observer) => {
@@ -2876,6 +3023,37 @@ function tapWith(tapperInput) {
2876
3023
  return () => unsubscribe(subscription);
2877
3024
  });
2878
3025
  }
3026
+ function tapLog(label, mapValue) {
3027
+ let subscriptions = 0;
3028
+ return tapWith(() => {
3029
+ const subscriptionSeq = subscriptions++;
3030
+ function log(event, ...args) {
3031
+ console.log(`█ ${label}#${subscriptionSeq}(${event}):`, ...args);
3032
+ }
3033
+ let emissions = 0;
3034
+ return {
3035
+ next: (value) => log(`next#${emissions++}`, mapValue ? mapValue(value) : value),
3036
+ error: (error2) => log("error", error2),
3037
+ complete: () => log("complete")
3038
+ };
3039
+ });
3040
+ }
3041
+ function printDiff() {
3042
+ let lastValue = NO_VALUES_YET;
3043
+ return map$1((value) => {
3044
+ if (lastValue !== NO_VALUES_YET) {
3045
+ const diff3 = diffJson(value, lastValue);
3046
+ if (diff3.length >= 2) {
3047
+ console.debug("DIFF", diff3, {
3048
+ value,
3049
+ lastValue
3050
+ });
3051
+ }
3052
+ }
3053
+ lastValue = value;
3054
+ return value;
3055
+ });
3056
+ }
2879
3057
  const NO_VALUES_YET = {};
2880
3058
  function startWith(value) {
2881
3059
  return (source) => new Observable((observer) => {
@@ -2952,6 +3130,53 @@ function skip(count) {
2952
3130
  };
2953
3131
  });
2954
3132
  }
3133
+ function mergeMap(project) {
3134
+ return (observable) => {
3135
+ return new Observable((observer) => {
3136
+ let index = 0;
3137
+ const innerSubscriptions = /* @__PURE__ */ new Set();
3138
+ let outerCompleted = false;
3139
+ const checkComplete = () => {
3140
+ if (outerCompleted && innerSubscriptions.size === 0) {
3141
+ observer.complete();
3142
+ }
3143
+ };
3144
+ const outerSubscription = observable.subscribe({
3145
+ next(value) {
3146
+ const innerObservable = project(value, index++);
3147
+ const innerSubscription = innerObservable.subscribe({
3148
+ next(innerValue) {
3149
+ observer.next(innerValue);
3150
+ },
3151
+ error(err) {
3152
+ observer.error(err);
3153
+ },
3154
+ complete() {
3155
+ innerSubscriptions.delete(innerSubscription);
3156
+ checkComplete();
3157
+ }
3158
+ });
3159
+ innerSubscriptions.add(innerSubscription);
3160
+ },
3161
+ error(err) {
3162
+ observer.error(err);
3163
+ },
3164
+ complete() {
3165
+ outerCompleted = true;
3166
+ checkComplete();
3167
+ }
3168
+ });
3169
+ return () => {
3170
+ unsubscribe(outerSubscription);
3171
+ for (const innerSubscription of innerSubscriptions) {
3172
+ if (innerSubscription) {
3173
+ unsubscribe(innerSubscription);
3174
+ }
3175
+ }
3176
+ };
3177
+ });
3178
+ };
3179
+ }
2955
3180
  function switchMap(project) {
2956
3181
  return (source) => {
2957
3182
  return new Observable((observer) => {
@@ -3072,6 +3297,67 @@ function concat(...inputs) {
3072
3297
  };
3073
3298
  });
3074
3299
  }
3300
+ function concatMap(project) {
3301
+ return (source) => new Observable((observer) => {
3302
+ let index = 0;
3303
+ let isOuterCompleted = false;
3304
+ let innerSubscription = null;
3305
+ const outerSubscription = source.subscribe({
3306
+ next(value) {
3307
+ try {
3308
+ const innerObservable = project(value, index++);
3309
+ if (innerSubscription) {
3310
+ unsubscribe(innerSubscription);
3311
+ }
3312
+ innerSubscription = innerObservable.subscribe({
3313
+ next(innerValue) {
3314
+ observer.next(innerValue);
3315
+ },
3316
+ error(err) {
3317
+ observer.error(err);
3318
+ },
3319
+ complete() {
3320
+ innerSubscription = null;
3321
+ if (isOuterCompleted && !innerSubscription) {
3322
+ observer.complete();
3323
+ }
3324
+ }
3325
+ });
3326
+ } catch (err) {
3327
+ observer.error(err);
3328
+ }
3329
+ },
3330
+ error(err) {
3331
+ observer.error(err);
3332
+ },
3333
+ complete() {
3334
+ isOuterCompleted = true;
3335
+ if (!innerSubscription) {
3336
+ observer.complete();
3337
+ }
3338
+ }
3339
+ });
3340
+ return () => {
3341
+ unsubscribe(outerSubscription);
3342
+ if (innerSubscription) {
3343
+ unsubscribe(innerSubscription);
3344
+ }
3345
+ };
3346
+ });
3347
+ }
3348
+ function lifecycle({
3349
+ onSubscribe,
3350
+ onUnsubscribe
3351
+ }) {
3352
+ return (source) => new Observable((observer) => {
3353
+ onSubscribe == null ? void 0 : onSubscribe();
3354
+ const subscription = source.subscribe(observer);
3355
+ return () => {
3356
+ unsubscribe(subscription);
3357
+ onUnsubscribe == null ? void 0 : onUnsubscribe();
3358
+ };
3359
+ });
3360
+ }
3075
3361
  function abortableOperation(operation) {
3076
3362
  return (source) => Observable.from(source).pipe(
3077
3363
  switchMap((input) => promiseFactoryToObservable((signal) => operation(input, signal)))
@@ -3114,6 +3400,41 @@ function catchError(handler) {
3114
3400
  };
3115
3401
  });
3116
3402
  }
3403
+ function withLatestFrom(other) {
3404
+ return (source) => new Observable((observer) => {
3405
+ let latest;
3406
+ let hasLatest = false;
3407
+ const otherSubscription = other.subscribe({
3408
+ next(value) {
3409
+ latest = value;
3410
+ hasLatest = true;
3411
+ },
3412
+ error(err) {
3413
+ observer.error(err);
3414
+ }
3415
+ });
3416
+ const scheduler = new AsyncSerialScheduler_1(observer);
3417
+ const sourceSubscription = source.subscribe({
3418
+ next(value) {
3419
+ scheduler.schedule(async (next) => {
3420
+ if (hasLatest) {
3421
+ next([value, latest]);
3422
+ }
3423
+ });
3424
+ },
3425
+ error(err) {
3426
+ scheduler.error(err);
3427
+ },
3428
+ complete() {
3429
+ scheduler.complete();
3430
+ }
3431
+ });
3432
+ return () => {
3433
+ unsubscribe(sourceSubscription);
3434
+ unsubscribe(otherSubscription);
3435
+ };
3436
+ });
3437
+ }
3117
3438
  function defer(observableFactory) {
3118
3439
  return new Observable((observer) => {
3119
3440
  let subscription;
@@ -3149,6 +3470,37 @@ function filter$1(predicate) {
3149
3470
  });
3150
3471
  };
3151
3472
  }
3473
+ async function testing__firstValueFromWithinTime(observable, ms, vi) {
3474
+ let result = void 0;
3475
+ let error2;
3476
+ const subscription = observable.subscribe({
3477
+ next: (value) => {
3478
+ if (value === void 0) {
3479
+ throw new Error(
3480
+ "firstValueFromWithinTime: do not use with `undefined` emissions because those can't be distinguished from this helper function's \"no emissions\" return value"
3481
+ );
3482
+ }
3483
+ result = value;
3484
+ subscription.unsubscribe();
3485
+ },
3486
+ error: (e2) => {
3487
+ error2 = e2;
3488
+ },
3489
+ complete: () => {
3490
+ error2 = new Error("firstValueFromWithinTime: promise completed without emitting any values");
3491
+ }
3492
+ });
3493
+ if (ms === "allPendingTimers") {
3494
+ await vi.runOnlyPendingTimersAsync();
3495
+ } else {
3496
+ await vi.advanceTimersByTimeAsync(ms);
3497
+ }
3498
+ subscription.unsubscribe();
3499
+ if (error2) {
3500
+ throw error2;
3501
+ }
3502
+ return result;
3503
+ }
3152
3504
  function retry(count) {
3153
3505
  return (source) => new Observable((observer) => {
3154
3506
  let retries = 0;
@@ -3187,7 +3539,7 @@ function retry(count) {
3187
3539
  return () => unsuscribeThis();
3188
3540
  });
3189
3541
  }
3190
- var define_process_default$b = { env: {} };
3542
+ var define_process_default$c = { env: {} };
3191
3543
  const cenv = defineEnvBuilder({
3192
3544
  /**
3193
3545
  * A proxy string that falls back to Node's HTTP_PROXY and HTTPS_PROXY if
@@ -3231,7 +3583,7 @@ const cenv = defineEnvBuilder({
3231
3583
  */
3232
3584
  CODY_TESTING_LIMIT_MAX_TIMERS: (envValue, _2) => bool(envValue) ?? assigned(getEnv("VITEST")) ?? false
3233
3585
  });
3234
- const _env$1 = typeof define_process_default$b !== "undefined" ? define_process_default$b.env : {};
3586
+ const _env$1 = typeof define_process_default$c !== "undefined" ? define_process_default$c.env : {};
3235
3587
  function getEnv(key) {
3236
3588
  const envValue = _env$1[key] ?? _env$1[key.toUpperCase()] ?? _env$1[key.toLowerCase()];
3237
3589
  if (envValue === void 0) {
@@ -3342,9 +3694,13 @@ function setLogger(newLogger) {
3342
3694
  function logDebug(filterLabel, text, ...args) {
3343
3695
  _logger.logDebug(filterLabel, text, ...args);
3344
3696
  }
3697
+ function logInfo(filterLabel, text, ...args) {
3698
+ _logger.logInfo(filterLabel, text, ...args);
3699
+ }
3345
3700
  function logError(filterLabel, text, ...args) {
3346
3701
  _logger.logError(filterLabel, text, ...args);
3347
3702
  }
3703
+ var define_process_default$b = { env: {} };
3348
3704
  function promise() {
3349
3705
  let resolverFn = void 0;
3350
3706
  const internalPromise = new Promise((resolve2, reject) => {
@@ -3434,6 +3790,9 @@ function createSubscriber() {
3434
3790
  notify
3435
3791
  };
3436
3792
  }
3793
+ function nextTick() {
3794
+ return new Promise((resolve2) => define_process_default$b.nextTick(resolve2));
3795
+ }
3437
3796
  var SemverString;
3438
3797
  ((SemverString2) => {
3439
3798
  const splitPrefixRegex = /^(?<prefix>.*)(?<version>\d+\.\d+\.\d+)$/;
@@ -3479,6 +3838,11 @@ const AUTH_STATUS_FIXTURE_AUTHED = {
3479
3838
  username: "alice",
3480
3839
  pendingValidation: false
3481
3840
  };
3841
+ const AUTH_STATUS_FIXTURE_UNAUTHED = {
3842
+ endpoint: "https://example.com",
3843
+ authenticated: false,
3844
+ pendingValidation: false
3845
+ };
3482
3846
  const AUTH_STATUS_FIXTURE_AUTHED_DOTCOM = {
3483
3847
  ...AUTH_STATUS_FIXTURE_AUTHED,
3484
3848
  endpoint: "https://sourcegraph.com"
@@ -5334,6 +5698,12 @@ class ExternalAuthProviderError extends AuthError {
5334
5698
  super("External Auth Provider Error", message);
5335
5699
  }
5336
5700
  }
5701
+ class OAuthProviderError extends AuthError {
5702
+ constructor(message) {
5703
+ super("OAuth Provider Error", message);
5704
+ this.showSignOut = false;
5705
+ }
5706
+ }
5337
5707
  class NeedsAuthChallengeError extends AuthError {
5338
5708
  constructor() {
5339
5709
  super(
@@ -5342,9 +5712,12 @@ class NeedsAuthChallengeError extends AuthError {
5342
5712
  );
5343
5713
  }
5344
5714
  }
5345
- function isExternalProviderAuthError(error2) {
5715
+ function isExternalAuthProviderError(error2) {
5346
5716
  return error2 instanceof ExternalAuthProviderError;
5347
5717
  }
5718
+ function isOAuthProviderError(error2) {
5719
+ return error2 instanceof OAuthProviderError;
5720
+ }
5348
5721
  function isNeedsAuthChallengeError(error2) {
5349
5722
  return error2 instanceof NeedsAuthChallengeError;
5350
5723
  }
@@ -5354,6 +5727,318 @@ function isAvailabilityError(error2) {
5354
5727
  function isInvalidAccessTokenError(error2) {
5355
5728
  return error2 instanceof InvalidAccessTokenError;
5356
5729
  }
5730
+ var CodyIDE = /* @__PURE__ */ ((CodyIDE2) => {
5731
+ CodyIDE2["VSCode"] = "VSCode";
5732
+ CodyIDE2["JetBrains"] = "JetBrains";
5733
+ CodyIDE2["Neovim"] = "Neovim";
5734
+ CodyIDE2["Emacs"] = "Emacs";
5735
+ CodyIDE2["Web"] = "Web";
5736
+ CodyIDE2["VisualStudio"] = "VisualStudio";
5737
+ CodyIDE2["Eclipse"] = "Eclipse";
5738
+ CodyIDE2["StandaloneWeb"] = "StandaloneWeb";
5739
+ return CodyIDE2;
5740
+ })(CodyIDE || {});
5741
+ var CodyAutoSuggestionMode = /* @__PURE__ */ ((CodyAutoSuggestionMode2) => {
5742
+ CodyAutoSuggestionMode2["Autocomplete"] = "autocomplete";
5743
+ CodyAutoSuggestionMode2["Autoedit"] = "auto-edit";
5744
+ CodyAutoSuggestionMode2["Off"] = "off";
5745
+ return CodyAutoSuggestionMode2;
5746
+ })(CodyAutoSuggestionMode || {});
5747
+ const AUTOCOMPLETE_PROVIDER_ID = {
5748
+ /**
5749
+ * Default identifier that maps to the recommended autocomplete provider on DotCom.
5750
+ */
5751
+ default: "default",
5752
+ /**
5753
+ * Cody talking to Fireworks official API.
5754
+ * https://docs.fireworks.ai/api-reference/introduction
5755
+ */
5756
+ fireworks: "fireworks",
5757
+ /**
5758
+ * Cody talking to openai compatible API.
5759
+ * We plan to use this provider instead of all the existing openai-related providers.
5760
+ */
5761
+ openaicompatible: "openaicompatible",
5762
+ /**
5763
+ * Cody talking to OpenAI's official public API.
5764
+ * https://platform.openai.com/docs/api-reference/introduction
5765
+ */
5766
+ openai: "openai",
5767
+ /**
5768
+ * Cody talking to OpenAI's official public API.
5769
+ * https://platform.openai.com/docs/api-reference/introduction
5770
+ *
5771
+ * @deprecated use `openai` instead
5772
+ */
5773
+ "unstable-openai": "unstable-openai",
5774
+ /**
5775
+ * Cody talking to OpenAI through Microsoft Azure's API (they re-sell the OpenAI API, but slightly modified).
5776
+ *
5777
+ * @deprecated use `openai` instead
5778
+ */
5779
+ "azure-openai": "azure-openai",
5780
+ /**
5781
+ * This refers to either Anthropic models re-sold by AWS,
5782
+ * or to other models hosted by AWS' Bedrock inference API service
5783
+ */
5784
+ "aws-bedrock": "aws-bedrock",
5785
+ /**
5786
+ * Cody talking to Anthropic's official public API.
5787
+ * https://docs.anthropic.com/en/api/getting-started
5788
+ */
5789
+ anthropic: "anthropic",
5790
+ /**
5791
+ * Cody talking to Google's APIs for models created by Google, which include:
5792
+ * - their public Gemini API
5793
+ * - their GCP Gemini API
5794
+ * - GCP Vertex API
5795
+ * - Anthropic-reselling APIs
5796
+ */
5797
+ google: "google",
5798
+ /**
5799
+ * Cody talking to Google's APIs for models created by Google, which include:
5800
+ * - their public Gemini API
5801
+ * - their GCP Gemini API
5802
+ * - GCP Vertex API
5803
+ */
5804
+ gemini: "gemini",
5805
+ /**
5806
+ * Cody talking to Google's APIs for models created by Google, which include:
5807
+ * - their public Gemini API
5808
+ * - their GCP Gemini API
5809
+ * - GCP Vertex API
5810
+ *
5811
+ * @deprecated use `gemini` instead.
5812
+ */
5813
+ "unstable-gemini": "unstable-gemini",
5814
+ /**
5815
+ * Cody talking to Ollama's official public API.
5816
+ * https://ollama.ai/docs/api
5817
+ */
5818
+ "experimental-ollama": "experimental-ollama",
5819
+ /**
5820
+ * Cody talking to Ollama's official public API.
5821
+ * https://ollama.ai/docs/api
5822
+ *
5823
+ * @deprecated use `experimental-ollama` instead.
5824
+ */
5825
+ "unstable-ollama": "unstable-ollama"
5826
+ };
5827
+ function clientCapabilities() {
5828
+ var _a3;
5829
+ if (_mockValue) {
5830
+ return _mockValue;
5831
+ }
5832
+ if (!_value) {
5833
+ throw new Error(
5834
+ "clientCapabilities called before configuration was set with setClientCapabilitiesFromConfiguration"
5835
+ );
5836
+ }
5837
+ return {
5838
+ ..._value.agentCapabilities,
5839
+ edit: ((_a3 = _value.agentCapabilities) == null ? void 0 : _a3.edit) ?? "enabled",
5840
+ agentIDE: _value.configuration.agentIDE ?? CodyIDE.VSCode,
5841
+ isVSCode: !_value.configuration.agentIDE || _value.configuration.agentIDE === CodyIDE.VSCode,
5842
+ isCodyWeb: _value.configuration.agentIDE === CodyIDE.Web,
5843
+ agentExtensionVersion: _value.configuration.agentExtensionVersion ?? _extensionVersion,
5844
+ agentIDEVersion: _value.configuration.agentIDEVersion,
5845
+ telemetryClientName: _value.configuration.telemetryClientName
5846
+ };
5847
+ }
5848
+ let _value;
5849
+ function setClientCapabilities(value) {
5850
+ _value = value;
5851
+ }
5852
+ let _extensionVersion;
5853
+ function setExtensionVersion(version2) {
5854
+ _extensionVersion = version2;
5855
+ }
5856
+ let _mockValue;
5857
+ function mockClientCapabilities(value) {
5858
+ _mockValue = value;
5859
+ }
5860
+ const CLIENT_CAPABILITIES_FIXTURE = {
5861
+ agentIDE: CodyIDE.VSCode,
5862
+ isVSCode: true,
5863
+ isCodyWeb: false,
5864
+ agentExtensionVersion: "1.2.3",
5865
+ agentIDEVersion: "4.5.6"
5866
+ };
5867
+ async function getOIDCConfiguration(endpoint) {
5868
+ try {
5869
+ const wellKnownUrl = new URL("/.well-known/openid-configuration", endpoint);
5870
+ const response = await fetch(wellKnownUrl.toString());
5871
+ if (!response.ok) {
5872
+ return null;
5873
+ }
5874
+ const config = await response.json();
5875
+ if (!config.device_authorization_endpoint || !config.token_endpoint || !config.authorization_endpoint || !config.issuer || !config.revocation_endpoint) {
5876
+ return null;
5877
+ }
5878
+ return {
5879
+ device_authorization_endpoint: config.device_authorization_endpoint,
5880
+ token_endpoint: config.token_endpoint,
5881
+ authorization_endpoint: config.authorization_endpoint,
5882
+ issuer: config.issuer,
5883
+ revocation_endpoint: config.revocation_endpoint
5884
+ };
5885
+ } catch (error2) {
5886
+ logError("oauth", "Failed to resolve openid configuration; error:", error2);
5887
+ return null;
5888
+ }
5889
+ }
5890
+ async function refreshOAuthToken(serverEndpoint, refreshToken) {
5891
+ try {
5892
+ const oidcConfig = await getOIDCConfiguration(serverEndpoint);
5893
+ if (!oidcConfig) return null;
5894
+ const response = await fetch(oidcConfig.token_endpoint, {
5895
+ method: "POST",
5896
+ headers: {
5897
+ "Content-Type": "application/x-www-form-urlencoded"
5898
+ },
5899
+ body: new URLSearchParams({
5900
+ grant_type: "refresh_token",
5901
+ refresh_token: refreshToken,
5902
+ client_id: getOAuthClientId()
5903
+ })
5904
+ });
5905
+ if (!response.ok) {
5906
+ logDebug("oauth", "OAuth token refresh failed:", {
5907
+ status: response.status,
5908
+ statusText: response.statusText,
5909
+ endpoint: serverEndpoint,
5910
+ clientId: getOAuthClientId()
5911
+ });
5912
+ return null;
5913
+ }
5914
+ const tokenResponse = await response.json();
5915
+ return {
5916
+ accessToken: tokenResponse.access_token,
5917
+ refreshToken: tokenResponse.refresh_token,
5918
+ expiresIn: tokenResponse.expires_in
5919
+ };
5920
+ } catch {
5921
+ return null;
5922
+ }
5923
+ }
5924
+ async function revokeOAuthTokens(serverEndpoint, refreshToken, accessToken) {
5925
+ try {
5926
+ const oidcConfig = await getOIDCConfiguration(serverEndpoint);
5927
+ if (!oidcConfig) {
5928
+ logDebug("oauth", "No revocation endpoint available, skipping token revocation");
5929
+ return;
5930
+ }
5931
+ await fetch(oidcConfig.revocation_endpoint, {
5932
+ method: "POST",
5933
+ headers: {
5934
+ "Content-Type": "application/x-www-form-urlencoded"
5935
+ },
5936
+ body: new URLSearchParams({
5937
+ token: refreshToken,
5938
+ token_type_hint: "refresh_token",
5939
+ client_id: getOAuthClientId()
5940
+ })
5941
+ });
5942
+ await fetch(oidcConfig.revocation_endpoint, {
5943
+ method: "POST",
5944
+ headers: {
5945
+ "Content-Type": "application/x-www-form-urlencoded"
5946
+ },
5947
+ body: new URLSearchParams({
5948
+ token: accessToken,
5949
+ token_type_hint: "access_token",
5950
+ client_id: getOAuthClientId()
5951
+ })
5952
+ });
5953
+ logDebug("oauth", "OAuth tokens revoked successfully");
5954
+ } catch (error2) {
5955
+ logDebug("oauth", "OAuth token revocation failed:", error2);
5956
+ }
5957
+ }
5958
+ function getOAuthClientId() {
5959
+ const currentIDE = clientCapabilities().agentIDE;
5960
+ switch (currentIDE) {
5961
+ case "VSCode":
5962
+ return "sgo_cid_codyvscode";
5963
+ case "JetBrains":
5964
+ return "sgo_cid_codyjetbrains";
5965
+ case "VisualStudio":
5966
+ return "sgo_cid_codyvisualstudio";
5967
+ default:
5968
+ return "sgo_cid_codyvscode";
5969
+ }
5970
+ }
5971
+ class OAuthCredential {
5972
+ constructor(endpoint, clientSecrets) {
5973
+ __publicField(this, "error", null);
5974
+ __publicField(this, "refreshInFlight", null);
5975
+ this.endpoint = endpoint;
5976
+ this.clientSecrets = clientSecrets;
5977
+ }
5978
+ static async refreshAndStore(endpoint, refreshToken, clientSecrets) {
5979
+ var _a3, _b2, _c2;
5980
+ const result = await refreshOAuthToken(endpoint, refreshToken);
5981
+ if (!(result == null ? void 0 : result.accessToken)) return void 0;
5982
+ if (result.refreshToken) {
5983
+ await ((_a3 = clientSecrets.storeRefreshToken) == null ? void 0 : _a3.call(clientSecrets, endpoint, result.refreshToken));
5984
+ }
5985
+ if (result.expiresIn) {
5986
+ const expiresAt = Date.now() + result.expiresIn * 1e3;
5987
+ await ((_b2 = clientSecrets.storeTokenExpiresAt) == null ? void 0 : _b2.call(clientSecrets, endpoint, expiresAt));
5988
+ }
5989
+ if (result.accessToken) {
5990
+ await ((_c2 = clientSecrets.storeToken) == null ? void 0 : _c2.call(clientSecrets, endpoint, result.accessToken, "oauth"));
5991
+ }
5992
+ return result.accessToken;
5993
+ }
5994
+ async getHeaders() {
5995
+ var _a3, _b2, _c2, _d2, _e2, _f2;
5996
+ const refreshToken = await ((_b2 = (_a3 = this.clientSecrets).getRefreshToken) == null ? void 0 : _b2.call(_a3, this.endpoint));
5997
+ const expiresAt = await ((_d2 = (_c2 = this.clientSecrets).getTokenExpiresAt) == null ? void 0 : _d2.call(_c2, this.endpoint));
5998
+ let token = await ((_f2 = (_e2 = this.clientSecrets).getToken) == null ? void 0 : _f2.call(_e2, this.endpoint));
5999
+ if (!token || this.needsRefresh(expiresAt, refreshToken)) {
6000
+ if (!this.refreshInFlight && refreshToken) {
6001
+ this.refreshInFlight = OAuthCredential.refreshAndStore(
6002
+ this.endpoint,
6003
+ refreshToken,
6004
+ this.clientSecrets
6005
+ ).finally(() => {
6006
+ this.refreshInFlight = null;
6007
+ });
6008
+ }
6009
+ const refreshPromise = this.refreshInFlight;
6010
+ if (refreshPromise) {
6011
+ token = await refreshPromise;
6012
+ if (!token) {
6013
+ if (!this.error) {
6014
+ externalAuthRefresh.next();
6015
+ }
6016
+ this.error = new OAuthProviderError("An error occurred while refreshing the token");
6017
+ throw this.error;
6018
+ }
6019
+ this.error = null;
6020
+ } else {
6021
+ if (!this.error) {
6022
+ externalAuthRefresh.next();
6023
+ }
6024
+ this.error = new OAuthProviderError("An error occurred while refreshing the token");
6025
+ throw this.error;
6026
+ }
6027
+ }
6028
+ const headers = {
6029
+ Authorization: `Bearer ${token}`
6030
+ };
6031
+ return headers;
6032
+ }
6033
+ needsRefresh(expiresAt, refreshToken) {
6034
+ if (!expiresAt || !refreshToken) {
6035
+ return true;
6036
+ }
6037
+ const now2 = Date.now();
6038
+ const timeUntilExpiry = expiresAt - now2;
6039
+ return timeUntilExpiry <= 5 * 60 * 1e3;
6040
+ }
6041
+ }
5357
6042
  var define_process_default$a = { env: {} };
5358
6043
  const externalAuthRefresh = new MulticastSubject();
5359
6044
  function normalizeServerEndpointURL(url) {
@@ -5364,7 +6049,7 @@ async function executeCommand(cmd) {
5364
6049
  throw new Error("Command execution is only supported in Node.js environments");
5365
6050
  }
5366
6051
  const { exec: exec2 } = await Promise.resolve().then(() => child_process);
5367
- const { promisify: promisify2 } = await import("./util-D8ltdME7.mjs").then((n) => n.u);
6052
+ const { promisify: promisify2 } = await import("./util-Ci-ROool.mjs").then((n) => n.u);
5368
6053
  const execAsync = promisify2(exec2);
5369
6054
  const command = cmd.commandLine.join(" ");
5370
6055
  const { stdout } = await execAsync(command, {
@@ -5436,6 +6121,7 @@ function createHeaderCredentials(externalProvider, serverEndpoint) {
5436
6121
  };
5437
6122
  }
5438
6123
  async function resolveAuth(endpoint, configuration2, clientSecrets) {
6124
+ var _a3;
5439
6125
  const { authExternalProviders, overrideServerEndpoint, overrideAuthToken } = configuration2;
5440
6126
  const serverEndpoint = normalizeServerEndpointURL(overrideServerEndpoint || endpoint);
5441
6127
  try {
@@ -5445,7 +6131,18 @@ async function resolveAuth(endpoint, configuration2, clientSecrets) {
5445
6131
  const externalProvider = authExternalProviders.find(
5446
6132
  (provider) => normalizeServerEndpointURL(provider.endpoint) === serverEndpoint
5447
6133
  );
5448
- return externalProvider ? createHeaderCredentials(externalProvider, serverEndpoint) : createTokenCredentials(clientSecrets, serverEndpoint);
6134
+ if (externalProvider) {
6135
+ return createHeaderCredentials(externalProvider, serverEndpoint);
6136
+ }
6137
+ const refreshToken = await ((_a3 = clientSecrets.getRefreshToken) == null ? void 0 : _a3.call(clientSecrets, serverEndpoint).catch(() => null));
6138
+ if (refreshToken) {
6139
+ const credential = new OAuthCredential(serverEndpoint, clientSecrets);
6140
+ return {
6141
+ credentials: credential || void 0,
6142
+ serverEndpoint
6143
+ };
6144
+ }
6145
+ return createTokenCredentials(clientSecrets, serverEndpoint);
5449
6146
  } catch (error2) {
5450
6147
  return {
5451
6148
  credentials: void 0,
@@ -5498,10 +6195,24 @@ function setResolvedConfigurationObservable(input) {
5498
6195
  false
5499
6196
  );
5500
6197
  }
6198
+ function setStaticResolvedConfigurationValue(input) {
6199
+ _resolvedConfig.setSource(input instanceof Observable ? input : Observable.of(input), false);
6200
+ }
5501
6201
  const resolvedConfig = _resolvedConfig.observable;
5502
6202
  function currentResolvedConfig() {
5503
6203
  return firstValueFrom(resolvedConfig);
5504
6204
  }
6205
+ function mockResolvedConfig(value) {
6206
+ _resolvedConfig.setSource(
6207
+ Observable.of({
6208
+ configuration: {},
6209
+ auth: {},
6210
+ clientState: { modelPreferences: {} },
6211
+ ...value
6212
+ }),
6213
+ false
6214
+ );
6215
+ }
5505
6216
  var g = typeof globalThis !== "undefined" && globalThis || typeof self !== "undefined" && self || // eslint-disable-next-line no-undef
5506
6217
  typeof global !== "undefined" && global || {};
5507
6218
  var support = {
@@ -5928,7 +6639,7 @@ try {
5928
6639
  DOMException$1.prototype = Object.create(Error.prototype);
5929
6640
  DOMException$1.prototype.constructor = DOMException$1;
5930
6641
  }
5931
- function fetch$1(input, init) {
6642
+ function fetch$2(input, init) {
5932
6643
  return new Promise(function(resolve2, reject) {
5933
6644
  var request = new Request(input, init);
5934
6645
  if (request.signal && request.signal.aborted) {
@@ -6016,9 +6727,9 @@ function fetch$1(input, init) {
6016
6727
  xhr.send(typeof request._bodyInit === "undefined" ? null : request._bodyInit);
6017
6728
  });
6018
6729
  }
6019
- fetch$1.polyfill = true;
6730
+ fetch$2.polyfill = true;
6020
6731
  if (!g.fetch) {
6021
- g.fetch = fetch$1;
6732
+ g.fetch = fetch$2;
6022
6733
  g.Headers = Headers$1;
6023
6734
  g.Request = Request;
6024
6735
  g.Response = Response;
@@ -6083,7 +6794,7 @@ function addClientInfoParams(params) {
6083
6794
  }
6084
6795
  }
6085
6796
  }
6086
- function fetch(input, init) {
6797
+ function fetch$1(input, init) {
6087
6798
  init = init ?? {};
6088
6799
  const headers = new Headers(init == null ? void 0 : init.headers);
6089
6800
  addCodyClientIdentificationHeaders(headers);
@@ -10105,6 +10816,15 @@ function logResponseHeadersToSpan(span, response) {
10105
10816
  status: response.status
10106
10817
  });
10107
10818
  }
10819
+ function getTraceparentHeaders() {
10820
+ const headers = {};
10821
+ propagation.inject(context$1.active(), headers, {
10822
+ set(carrier, key, value) {
10823
+ carrier[key] = value;
10824
+ }
10825
+ });
10826
+ return headers;
10827
+ }
10108
10828
  function recordErrorToSpan(span, error2) {
10109
10829
  span.recordException(error2);
10110
10830
  span.setStatus({ code: SpanStatusCode.ERROR });
@@ -10123,6 +10843,28 @@ function extractContextFromTraceparent(traceparent) {
10123
10843
  };
10124
10844
  return propagation.extract(ROOT_CONTEXT, carrier, getter);
10125
10845
  }
10846
+ function toPartialUtf8String(buf) {
10847
+ if (buf.length === 0) {
10848
+ return { str: "", buf: Buffer.of() };
10849
+ }
10850
+ let lastValidByteOffsetExclusive = buf.length;
10851
+ if ((buf[lastValidByteOffsetExclusive - 1] & 128) !== 0) {
10852
+ let numBytes = 1;
10853
+ while ((buf[lastValidByteOffsetExclusive - numBytes] & 192) === 128) {
10854
+ numBytes++;
10855
+ }
10856
+ const byte = buf[lastValidByteOffsetExclusive - numBytes];
10857
+ const mask = 255 ^ (1 << 7 - numBytes) - 1;
10858
+ const value = numBytes === 6 ? 252 : mask ^ 1 << 7 - numBytes;
10859
+ if ((byte & mask) !== value) {
10860
+ lastValidByteOffsetExclusive -= numBytes;
10861
+ }
10862
+ }
10863
+ return {
10864
+ str: buf.slice(0, lastValidByteOffsetExclusive).toString("utf8"),
10865
+ buf: Buffer.from(buf.slice(lastValidByteOffsetExclusive))
10866
+ };
10867
+ }
10126
10868
  async function getAuthHeaders(auth, url) {
10127
10869
  if (auth.serverEndpoint && auth.credentials && url.host === new URL(auth.serverEndpoint).host) {
10128
10870
  if ("token" in auth.credentials) {
@@ -11922,7 +12664,7 @@ class SourcegraphGraphQLAPIClient {
11922
12664
  const { abortController, timeoutSignal } = dependentAbortControllerWithTimeout(signal);
11923
12665
  return wrapInActiveSpan(
11924
12666
  `graphql.fetch${queryName ? `.${queryName}` : ""}`,
11925
- () => fetch(url, {
12667
+ () => fetch$1(url, {
11926
12668
  method: "POST",
11927
12669
  body: JSON.stringify({ query, variables }),
11928
12670
  headers,
@@ -11957,7 +12699,7 @@ class SourcegraphGraphQLAPIClient {
11957
12699
  const { abortController, timeoutSignal } = dependentAbortControllerWithTimeout(signal);
11958
12700
  return wrapInActiveSpan(
11959
12701
  `httpapi.fetch${queryName ? `.${queryName}` : ""}`,
11960
- () => fetch(url, {
12702
+ () => fetch$1(url, {
11961
12703
  method,
11962
12704
  body,
11963
12705
  headers,
@@ -12060,7 +12802,6 @@ var FeatureFlag = /* @__PURE__ */ ((FeatureFlag2) => {
12060
12802
  FeatureFlag2["CodyAutoEditExperimentEnabledFeatureFlag"] = "cody-autoedit-experiment-enabled-flag";
12061
12803
  FeatureFlag2["CodyAutoEditHotStreak"] = "cody-autoedit-hot-streak-v2";
12062
12804
  FeatureFlag2["CodyEditDefaultToGpt4oMini"] = "cody-edit-default-to-gpt-4o-mini";
12063
- FeatureFlag2["CodyChatDefaultToClaude35Haiku"] = "cody-chat-default-to-claude-3-5-haiku";
12064
12805
  FeatureFlag2["UseSscForCodySubscription"] = "use-ssc-for-cody-subscription";
12065
12806
  FeatureFlag2["CodyProTrialEnded"] = "cody-pro-trial-ended";
12066
12807
  FeatureFlag2["GitMentionProvider"] = "git-mention-provider";
@@ -12235,7 +12976,7 @@ function isS2(arg) {
12235
12976
  return false;
12236
12977
  }
12237
12978
  }
12238
- new URL("https://sourcegraph.com/cody/manage");
12979
+ const DOTCOM_WORKSPACE_UPGRADE_URL = new URL("https://sourcegraph.com/cody/manage");
12239
12980
  const Workspaces_Host_Prod = ".sourcegraph.app";
12240
12981
  const Workspaces_Host_Dev = ".sourcegraphdev.app";
12241
12982
  const Workspaces_Host_Local = ".sourcegraphapp.test:3443";
@@ -12257,56 +12998,6 @@ const CHAT_OUTPUT_TOKEN_BUDGET = 4e3;
12257
12998
  const CORPUS_CONTEXT_ALLOCATION = 0.6;
12258
12999
  const EXTENDED_USER_CONTEXT_TOKEN_BUDGET = 3e4;
12259
13000
  const EXTENDED_CHAT_INPUT_TOKEN_BUDGET = 15e3;
12260
- var CodyIDE = /* @__PURE__ */ ((CodyIDE2) => {
12261
- CodyIDE2["VSCode"] = "VSCode";
12262
- CodyIDE2["JetBrains"] = "JetBrains";
12263
- CodyIDE2["Neovim"] = "Neovim";
12264
- CodyIDE2["Emacs"] = "Emacs";
12265
- CodyIDE2["Web"] = "Web";
12266
- CodyIDE2["VisualStudio"] = "VisualStudio";
12267
- CodyIDE2["Eclipse"] = "Eclipse";
12268
- CodyIDE2["StandaloneWeb"] = "StandaloneWeb";
12269
- return CodyIDE2;
12270
- })(CodyIDE || {});
12271
- var CodyAutoSuggestionMode = /* @__PURE__ */ ((CodyAutoSuggestionMode2) => {
12272
- CodyAutoSuggestionMode2["Autocomplete"] = "autocomplete";
12273
- CodyAutoSuggestionMode2["Autoedit"] = "auto-edit";
12274
- CodyAutoSuggestionMode2["Off"] = "off";
12275
- return CodyAutoSuggestionMode2;
12276
- })(CodyAutoSuggestionMode || {});
12277
- function clientCapabilities() {
12278
- var _a3;
12279
- if (!_value) {
12280
- throw new Error(
12281
- "clientCapabilities called before configuration was set with setClientCapabilitiesFromConfiguration"
12282
- );
12283
- }
12284
- return {
12285
- ..._value.agentCapabilities,
12286
- edit: ((_a3 = _value.agentCapabilities) == null ? void 0 : _a3.edit) ?? "enabled",
12287
- agentIDE: _value.configuration.agentIDE ?? CodyIDE.VSCode,
12288
- isVSCode: !_value.configuration.agentIDE || _value.configuration.agentIDE === CodyIDE.VSCode,
12289
- isCodyWeb: _value.configuration.agentIDE === CodyIDE.Web,
12290
- agentExtensionVersion: _value.configuration.agentExtensionVersion ?? _extensionVersion,
12291
- agentIDEVersion: _value.configuration.agentIDEVersion,
12292
- telemetryClientName: _value.configuration.telemetryClientName
12293
- };
12294
- }
12295
- let _value;
12296
- function setClientCapabilities(value) {
12297
- _value = value;
12298
- }
12299
- let _extensionVersion;
12300
- function setExtensionVersion(version2) {
12301
- _extensionVersion = version2;
12302
- }
12303
- ({
12304
- agentIDE: CodyIDE.VSCode,
12305
- isVSCode: true,
12306
- isCodyWeb: false,
12307
- agentExtensionVersion: "1.2.3",
12308
- agentIDEVersion: "4.5.6"
12309
- });
12310
13001
  var lodash = { exports: {} };
12311
13002
  /**
12312
13003
  * @license
@@ -19274,6 +19965,10 @@ function pathFunctionsForURI(uri, isWindows$1 = isWindows()) {
19274
19965
  pathFunctions(true, sep2, false)
19275
19966
  ) : posixFilePaths;
19276
19967
  }
19968
+ function defaultPathFunctions() {
19969
+ const isWindows$1 = isWindows();
19970
+ return pathFunctions(isWindows$1, isWindows$1 ? "\\" : "/", isMacOS());
19971
+ }
19277
19972
  function pathFunctions(isWindows2, sep2, caseSensitive) {
19278
19973
  const f = {
19279
19974
  dirname(path2) {
@@ -19768,6 +20463,39 @@ class GraphQLTelemetryExporter {
19768
20463
  }
19769
20464
  }
19770
20465
  }
20466
+ const MOCK_URL = "http://localhost:49300";
20467
+ const ENDPOINT = "/.test/mockEventRecording";
20468
+ class MockServerTelemetryExporter {
20469
+ constructor(anonymousUserID) {
20470
+ this.anonymousUserID = anonymousUserID;
20471
+ }
20472
+ async exportEvents(events2) {
20473
+ const resultOrError = await this.postTestEventRecording(
20474
+ events2.map((event) => ({ ...event, testOnlyAnonymousUserID: this.anonymousUserID }))
20475
+ );
20476
+ if (isError(resultOrError)) {
20477
+ logError("MockServerTelemetryExporter", "Error exporting telemetry events:", resultOrError);
20478
+ }
20479
+ }
20480
+ postTestEventRecording(events2) {
20481
+ const headers = new Headers({
20482
+ "Content-Type": "application/json",
20483
+ "X-Sourcegraph-Actor-Anonymous-UID": this.anonymousUserID ?? ""
20484
+ });
20485
+ return fetch(`${MOCK_URL}${ENDPOINT}`, {
20486
+ method: "POST",
20487
+ headers,
20488
+ body: JSON.stringify(events2)
20489
+ }).then((response) => {
20490
+ if (!response.ok) {
20491
+ throw new Error(`HTTP status code: ${response.status}`);
20492
+ }
20493
+ return response;
20494
+ }).then((response) => response.json()).catch(
20495
+ (error2) => new Error(`error sending data to mock event-recording API: ${error2} (${MOCK_URL})`)
20496
+ );
20497
+ }
20498
+ }
19771
20499
  function getTier(authStatus2) {
19772
20500
  return !authStatus2.authenticated ? 3 : 2;
19773
20501
  }
@@ -19826,7 +20554,20 @@ class NoOpTelemetryRecorderProvider extends dist.TelemetryRecorderProvider {
19826
20554
  super({ client: "" }, new dist.NoOpTelemetryExporter(), processors2 || []);
19827
20555
  }
19828
20556
  }
19829
- new NoOpTelemetryRecorderProvider().getRecorder();
20557
+ const noOpTelemetryRecorder = new NoOpTelemetryRecorderProvider().getRecorder();
20558
+ class MockServerTelemetryRecorderProvider extends dist.TelemetryRecorderProvider {
20559
+ constructor(config) {
20560
+ const cap2 = clientCapabilities();
20561
+ super(
20562
+ {
20563
+ client: `${cap2.agentIDE}.Cody`,
20564
+ clientVersion: cap2.agentExtensionVersion
20565
+ },
20566
+ new MockServerTelemetryExporter(config.clientState.anonymousUserID),
20567
+ [new ConfigurationMetadataProcessor()]
20568
+ );
20569
+ }
20570
+ }
19830
20571
  class ConfigurationMetadataProcessor {
19831
20572
  processEvent(event) {
19832
20573
  if (!event.parameters.metadata) {
@@ -19916,6 +20657,54 @@ var dedent$1 = { exports: {} };
19916
20657
  })(dedent$1);
19917
20658
  var dedentExports = dedent$1.exports;
19918
20659
  const dedent = /* @__PURE__ */ getDefaultExportFromCjs(dedentExports);
20660
+ function isMatlabFile(content) {
20661
+ const contentLower = content.toLowerCase();
20662
+ const matlabIndicators = {
20663
+ "function ": 3,
20664
+ // High confidence
20665
+ "classdef ": 3,
20666
+ end: 2,
20667
+ fprintf: 2,
20668
+ "disp(": 2,
20669
+ "plot(": 2,
20670
+ "figure(": 2,
20671
+ "clear all": 3,
20672
+ clc: 2,
20673
+ "% ": 1,
20674
+ // MATLAB comments
20675
+ matlab: 2
20676
+ };
20677
+ const objcIndicators = {
20678
+ "@interface": 4,
20679
+ // Very strong indicator
20680
+ "@implementation": 4,
20681
+ "@end": 3,
20682
+ "#import": 3,
20683
+ "#include": 3,
20684
+ "int main": 4,
20685
+ nsstring: 3,
20686
+ nsobject: 3,
20687
+ alloc: 2,
20688
+ retain: 2,
20689
+ release: 2,
20690
+ autorelease: 2,
20691
+ double: 1,
20692
+ printf: 2
20693
+ };
20694
+ let matlabScore = 0;
20695
+ let objcScore = 0;
20696
+ for (const [indicator, weight] of Object.entries(matlabIndicators)) {
20697
+ if (contentLower.includes(indicator)) {
20698
+ matlabScore += weight;
20699
+ }
20700
+ }
20701
+ for (const [indicator, weight] of Object.entries(objcIndicators)) {
20702
+ if (contentLower.includes(indicator)) {
20703
+ objcScore += weight;
20704
+ }
20705
+ }
20706
+ return objcScore <= matlabScore + 2;
20707
+ }
19919
20708
  const ProgrammingLanguage = {
19920
20709
  JavaScript: "JavaScript",
19921
20710
  TypeScript: "TypeScript",
@@ -19938,6 +20727,8 @@ const EXTENSION_TO_LANGUAGE = {
19938
20727
  rb: "Ruby",
19939
20728
  md: ProgrammingLanguage.Markdown,
19940
20729
  markdown: ProgrammingLanguage.Markdown,
20730
+ m: "MATLAB",
20731
+ mm: "Objective-C",
19941
20732
  php: "PHP",
19942
20733
  go: ProgrammingLanguage.Go,
19943
20734
  java: ProgrammingLanguage.Java,
@@ -19959,9 +20750,16 @@ function extensionForLanguage(language) {
19959
20750
  return void 0;
19960
20751
  }
19961
20752
  function languageFromFilename(file) {
19962
- const extWithoutDot = uriExtname(file).slice(1);
20753
+ const extWithoutDot = uriExtname(file).slice(1).toLowerCase();
19963
20754
  return EXTENSION_TO_LANGUAGE[extWithoutDot] ?? extWithoutDot;
19964
20755
  }
20756
+ function languageFromFilenameAndContent(file, content) {
20757
+ const extWithoutDot = uriExtname(file).slice(1).toLowerCase();
20758
+ if (extWithoutDot === "m") {
20759
+ return isMatlabFile(content) ? "MATLAB" : "Objective-C";
20760
+ }
20761
+ return languageFromFilename(file);
20762
+ }
19965
20763
  function markdownCodeBlockLanguageIDForFilename(file) {
19966
20764
  return languageFromFilename(file).toLowerCase();
19967
20765
  }
@@ -19993,6 +20791,15 @@ function expandToLineRange(range2) {
19993
20791
  end: { line: endLine, character: 0 }
19994
20792
  };
19995
20793
  }
20794
+ function displayRange(range2) {
20795
+ if (range2.end.line === range2.start.line) {
20796
+ if (range2.end.character === range2.start.character) {
20797
+ return ps`${range2.start.line + 1}:${range2.start.character + 1}`;
20798
+ }
20799
+ return ps`${range2.start.line + 1}:${range2.start.character + 1}-${range2.end.character + 1}`;
20800
+ }
20801
+ return ps`${range2.start.line + 1}:${range2.start.character + 1}-${range2.end.line + 1}:${range2.end.character + 1}`;
20802
+ }
19996
20803
  function isPositionEqual(a3, b2) {
19997
20804
  return a3.line === b2.line && a3.character === b2.character;
19998
20805
  }
@@ -20134,6 +20941,11 @@ function getEditorTabSize(uri, workspace2, window2) {
20134
20941
  }
20135
20942
  return tabSize;
20136
20943
  }
20944
+ function getEditorIndentString(uri, workspace2, window2) {
20945
+ const insertSpaces = getEditorInsertSpaces(uri, workspace2, window2);
20946
+ const tabSize = getEditorTabSize(uri, workspace2, window2);
20947
+ return insertSpaces ? " ".repeat(tabSize) : " ";
20948
+ }
20137
20949
  const ALIAS = Symbol.for("yaml.alias");
20138
20950
  const DOC = Symbol.for("yaml.document");
20139
20951
  const MAP = Symbol.for("yaml.map");
@@ -34078,6 +34890,9 @@ function deserializeContextItem(contextItem) {
34078
34890
  function isSerializedContextItemMentionNode(node) {
34079
34891
  return Boolean(node && node.type === CONTEXT_ITEM_MENTION_NODE_TYPE);
34080
34892
  }
34893
+ function isSerializedTemplateInputNode(node) {
34894
+ return Boolean(node && node.type === TEMPLATE_INPUT_NODE_TYPE);
34895
+ }
34081
34896
  function getMentionOperations(existing, toAdd) {
34082
34897
  const groups = Array.from(
34083
34898
  /* @__PURE__ */ new Set([
@@ -34334,10 +35149,10 @@ function textContentFromSerializedLexicalNode(root2, __testing_wrapText) {
34334
35149
  const nodeText = contextItemMentionNodePromptText(
34335
35150
  node.contextItem
34336
35151
  );
34337
- text.push(nodeText);
35152
+ text.push(__testing_wrapText ? __testing_wrapText(nodeText) ?? nodeText : nodeText);
34338
35153
  } else if ("type" in node && node.type === TEMPLATE_INPUT_NODE_TYPE) {
34339
35154
  const nodeText = templateInputNodeDisplayText(node);
34340
- text.push(nodeText);
35155
+ text.push(__testing_wrapText ? __testing_wrapText(nodeText) ?? nodeText : nodeText);
34341
35156
  } else if ("text" in node && typeof node.text === "string") {
34342
35157
  text.push(node.text);
34343
35158
  }
@@ -35292,7 +36107,6 @@ const VSCODE_CHANGELOG_URL = new URL(
35292
36107
  "https://github.com/sourcegraph/cody/blob/main/vscode/CHANGELOG.md"
35293
36108
  );
35294
36109
  const DISCORD_URL = new URL("https://discord.gg/s2qDtYGnAE");
35295
- const CODY_FEEDBACK_URL = new URL("https://github.com/sourcegraph/cody/issues/new/choose");
35296
36110
  const CODY_SUPPORT_URL = new URL("https://srcgr.ph/cody-support");
35297
36111
  const ACCOUNT_USAGE_URL = new URL("https://sourcegraph.com/cody/manage");
35298
36112
  const ACCOUNT_LIMITS_INFO_URL = new URL(
@@ -39762,6 +40576,24 @@ const child_process = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defin
39762
40576
  execSync,
39763
40577
  spawn
39764
40578
  }, Symbol.toStringTag, { value: "Module" }));
40579
+ function appendFileSync() {
40580
+ throw new Error("not implemented");
40581
+ }
40582
+ function existsSync() {
40583
+ throw new Error("not implemented");
40584
+ }
40585
+ function mkdirSync() {
40586
+ throw new Error("not implemented");
40587
+ }
40588
+ function rmSync() {
40589
+ throw new Error("not implemented");
40590
+ }
40591
+ function copySync() {
40592
+ throw new Error("not implemented");
40593
+ }
40594
+ function statSync() {
40595
+ throw new Error("not implemented");
40596
+ }
39765
40597
  var define_process_default$2 = { env: {} };
39766
40598
  function assertPath(path2) {
39767
40599
  if (typeof path2 !== "string") {
@@ -41562,7 +42394,7 @@ const camelCase$1 = /* @__PURE__ */ getDefaultExportFromCjs(camelCase_1);
41562
42394
  const $schema = "package.schema.json";
41563
42395
  const name = "cody-ai";
41564
42396
  const displayName = "Cody: AI Code Assistant";
41565
- const version = "1.126.0";
42397
+ const version = "1.136.0";
41566
42398
  const publisher = "sourcegraph";
41567
42399
  const license = "Apache-2.0";
41568
42400
  const icon = "resources/sourcegraph.png";
@@ -42080,6 +42912,55 @@ const contributes = {
42080
42912
  group: "Debug",
42081
42913
  when: "cody.activated"
42082
42914
  },
42915
+ {
42916
+ command: "cody.debug.auth.setTokenExpiry",
42917
+ title: "[Dev] Set Token Expiry",
42918
+ category: "Cody Debug",
42919
+ group: "Debug",
42920
+ enablement: "cody.activated && cody.devOrTest"
42921
+ },
42922
+ {
42923
+ command: "cody.debug.auth.checkTokenExpiry",
42924
+ title: "[Dev] Check Token Expiry",
42925
+ category: "Cody Debug",
42926
+ group: "Debug",
42927
+ enablement: "cody.activated && cody.devOrTest"
42928
+ },
42929
+ {
42930
+ command: "cody.debug.auth.setInvalidRefreshToken",
42931
+ title: "[Dev] Set Invalid Refesh Token",
42932
+ category: "Cody Debug",
42933
+ group: "Debug",
42934
+ enablement: "cody.activated && cody.devOrTest"
42935
+ },
42936
+ {
42937
+ command: "cody.debug.auth.clearAll",
42938
+ title: "[Dev] Clear All Auth Data",
42939
+ category: "Cody Debug",
42940
+ group: "Debug",
42941
+ enablement: "cody.devOrTest"
42942
+ },
42943
+ {
42944
+ command: "cody.debug.auth.showStoredData",
42945
+ title: "[Dev] Show Stored Auth Data",
42946
+ category: "Cody Debug",
42947
+ group: "Debug",
42948
+ enablement: "cody.devOrTest"
42949
+ },
42950
+ {
42951
+ command: "cody.debug.auth.showInfo",
42952
+ title: "[Dev] Show Auth Info",
42953
+ category: "Cody Debug",
42954
+ group: "Debug",
42955
+ enablement: "cody.activated && cody.devOrTest"
42956
+ },
42957
+ {
42958
+ command: "cody.debug.auth.toggleDeviceAuth",
42959
+ title: "[Dev] Toggle Device Auth Support",
42960
+ category: "Cody Debug",
42961
+ group: "Debug",
42962
+ enablement: "cody.devOrTest"
42963
+ },
42083
42964
  {
42084
42965
  command: "cody.test.set-context-filters",
42085
42966
  title: "[Internal] Set Context Filters Overwrite",
@@ -44692,16 +45573,72 @@ function matchesGlobPatterns(includeGlobs, excludeGlobs, value) {
44692
45573
  var define_process_default = { env: {} };
44693
45574
  const isTesting = false === "true";
44694
45575
  const isIntegrationTesting = define_process_default.env.CODY_CLIENT_INTEGRATION_TESTING === "true";
44695
- const emptyFileWatcher = {
44696
- onDidChange: emptyEvent(),
44697
- onDidCreate: emptyEvent(),
44698
- onDidDelete: emptyEvent(),
44699
- ignoreChangeEvents: true,
44700
- ignoreCreateEvents: true,
44701
- ignoreDeleteEvents: true,
44702
- dispose() {
45576
+ function createRealFileSystemWatcher(globPattern) {
45577
+ var _a3, _b2;
45578
+ const onDidChangeEmitter = new AgentEventEmitter();
45579
+ const onDidCreateEmitter = new AgentEventEmitter();
45580
+ const onDidDeleteEmitter = new AgentEventEmitter();
45581
+ let watcher;
45582
+ let isDisposed = false;
45583
+ let pattern;
45584
+ let basePath;
45585
+ if (typeof globPattern === "string") {
45586
+ pattern = globPattern;
45587
+ basePath = ((_a3 = workspaceFolders[0]) == null ? void 0 : _a3.uri.fsPath) || define_process_default.cwd();
45588
+ } else if ("baseUri" in globPattern && "pattern" in globPattern) {
45589
+ pattern = globPattern.pattern;
45590
+ basePath = globPattern.baseUri.fsPath;
45591
+ } else {
45592
+ pattern = "**/*";
45593
+ basePath = ((_b2 = workspaceFolders[0]) == null ? void 0 : _b2.uri.fsPath) || define_process_default.cwd();
44703
45594
  }
44704
- };
45595
+ const fullPath = path$1.join(basePath, pattern);
45596
+ let fileExists = existsSync();
45597
+ try {
45598
+ const watchPath = path$1.dirname(fullPath);
45599
+ const fileName = path$1.basename(fullPath);
45600
+ watcher = (void 0)(watchPath, { persistent: false }, (eventType, filename) => {
45601
+ if (isDisposed || !filename || filename !== fileName) {
45602
+ return;
45603
+ }
45604
+ const uri = Uri.file(fullPath);
45605
+ const exists = existsSync(fullPath);
45606
+ if (eventType === "rename") {
45607
+ if (exists && !fileExists) {
45608
+ fileExists = true;
45609
+ onDidCreateEmitter.fire(uri);
45610
+ } else if (!exists && fileExists) {
45611
+ fileExists = false;
45612
+ onDidDeleteEmitter.fire(uri);
45613
+ } else if (exists && fileExists) {
45614
+ onDidChangeEmitter.fire(uri);
45615
+ }
45616
+ } else if (eventType === "change" && exists) {
45617
+ onDidChangeEmitter.fire(uri);
45618
+ }
45619
+ });
45620
+ watcher.on("error", (error2) => {
45621
+ logError("FileSystemWatcher", "Watch error", error2);
45622
+ });
45623
+ } catch (error2) {
45624
+ logError("FileSystemWatcher", "Failed to create watcher", error2);
45625
+ }
45626
+ return {
45627
+ onDidChange: onDidChangeEmitter.event,
45628
+ onDidCreate: onDidCreateEmitter.event,
45629
+ onDidDelete: onDidDeleteEmitter.event,
45630
+ ignoreChangeEvents: false,
45631
+ ignoreCreateEvents: false,
45632
+ ignoreDeleteEvents: false,
45633
+ dispose() {
45634
+ isDisposed = true;
45635
+ watcher == null ? void 0 : watcher.close();
45636
+ onDidChangeEmitter.dispose();
45637
+ onDidCreateEmitter.dispose();
45638
+ onDidDeleteEmitter.dispose();
45639
+ }
45640
+ };
45641
+ }
44705
45642
  let clientInfo;
44706
45643
  function setClientInfo(newClientInfo) {
44707
45644
  clientInfo = newClientInfo;
@@ -44956,9 +45893,9 @@ ${workspaceFolders.map((wf) => ` - ${wf.uri.toString()}
44956
45893
  }
44957
45894
  return relativePath;
44958
45895
  },
44959
- // TODO: used for Cody Context Filters, WorkspaceRepoMapper and custom commands
44960
- // https://github.com/sourcegraph/cody/issues/4136
44961
- createFileSystemWatcher: () => emptyFileWatcher,
45896
+ createFileSystemWatcher: (globPattern) => {
45897
+ return createRealFileSystemWatcher(globPattern);
45898
+ },
44962
45899
  getConfiguration: (section, scope) => {
44963
45900
  if (section) {
44964
45901
  if (section.startsWith("[")) {
@@ -45648,9 +46585,10 @@ const _env = {
45648
46585
  writeText: () => Promise.resolve()
45649
46586
  },
45650
46587
  openExternal: (uri) => {
45651
- var _a3, _b2;
45652
- if ((_a3 = decodeURIComponent(uri.toString())) == null ? void 0 : _a3.includes("user/settings/tokens/new/callback?requestFrom")) {
45653
- (_b2 = agent == null ? void 0 : agent.authenticationHandler) == null ? void 0 : _b2.handleCallback(uri);
46588
+ var _a3;
46589
+ const uriString = decodeURIComponent(uri.toString());
46590
+ if ((uriString == null ? void 0 : uriString.includes("user/settings/tokens/new/callback?requestFrom")) || (uriString == null ? void 0 : uriString.includes("/auth/device?user_code=")) || (uriString == null ? void 0 : uriString.includes("user_code%3D"))) {
46591
+ (_a3 = agent == null ? void 0 : agent.authenticationHandler) == null ? void 0 : _a3.handleCallback(uri);
45654
46592
  return Promise.resolve(true);
45655
46593
  }
45656
46594
  try {
@@ -45853,411 +46791,477 @@ const vscode = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProper
45853
46791
  workspaceTextDocuments
45854
46792
  }, Symbol.toStringTag, { value: "Module" }));
45855
46793
  export {
45856
- SpanStatusCode as $,
45857
- memoizeLastValue as A,
45858
- toSerializedPromptEditorValue as B,
46794
+ fixPathSep as $,
46795
+ pathFunctionsForURI as A,
46796
+ defaultPathFunctions as B,
45859
46797
  ContextItemSource as C,
45860
- isEqual$1 as D,
45861
- scanForMentionTriggerInUserTextInput as E,
45862
- FILE_CONTEXT_MENTION_PROVIDER as F,
45863
- getMentionOperations as G,
45864
- combineLatest as H,
46798
+ DefaultChatCommands as D,
46799
+ isMacOS as E,
46800
+ FILE_RANGE_TOOLTIP_LABEL as F,
46801
+ GENERAL_HELP_LABEL as G,
46802
+ assertFileURI as H,
45865
46803
  IGNORED_FILE_WARNING_LABEL as I,
45866
- map$1 as J,
45867
- forceHydration as K,
46804
+ isFileURI as J,
46805
+ uriBasename as K,
45868
46806
  LARGE_FILE_WARNING_LABEL as L,
45869
- hydrateAfterPostMessage as M,
46807
+ ModelTag as M,
45870
46808
  NO_SYMBOL_MATCHES_HELP_LABEL as N,
45871
- Observable as O,
45872
- isDotCom as P,
45873
- isWorkspaceInstance as Q,
45874
- REMOTE_REPOSITORY_PROVIDER_URI as R,
45875
- SYMBOL_CONTEXT_MENTION_PROVIDER as S,
45876
- TEMPLATE_INPUT_NODE_TYPE as T,
46809
+ uriDirname as O,
46810
+ ProgrammingLanguage as P,
46811
+ uriExtname as Q,
46812
+ uriParseNameAndExtension as R,
46813
+ SUPPORTED_URI_SCHEMAS as S,
46814
+ displayPath as T,
45877
46815
  Uri as U,
45878
- isAuthError as V,
45879
- WEB_PROVIDER_URI as W,
45880
- isAvailabilityError as X,
45881
- isSourcegraphToken as Y,
45882
- trace as Z,
45883
- context$1 as _,
45884
- REMOTE_FILE_PROVIDER_URI as a,
45885
- graphqlClient as a$,
45886
- svg as a0,
45887
- html as a1,
45888
- whitespace as a2,
45889
- find as a3,
45890
- stringify$1 as a4,
45891
- stringify as a5,
45892
- ccount as a6,
45893
- CodyIDE as a7,
45894
- CodyTaskState as a8,
45895
- cryptoJsExports as a9,
45896
- isCodeSearchContextItem as aA,
45897
- v4 as aB,
45898
- lodashExports as aC,
45899
- deserializeContextItem as aD,
45900
- firstResultFromOperation as aE,
45901
- ChatHistoryType as aF,
45902
- ACCOUNT_USAGE_URL as aG,
45903
- CODY_DOC_QUICKSTART_URL as aH,
45904
- isDefined as aI,
45905
- browser$1 as aJ,
45906
- CodyAutoSuggestionMode as aK,
45907
- setDisplayPathEnvInfo as aL,
45908
- isErrorLike as aM,
45909
- PromptString as aN,
45910
- createGuardrailsImpl as aO,
45911
- serialize as aP,
45912
- deserialize as aQ,
45913
- unsubscribe as aR,
45914
- AsyncSerialScheduler$1 as aS,
45915
- authStatus as aT,
45916
- pick as aU,
45917
- distinctUntilChanged as aV,
45918
- switchMapReplayOperation as aW,
45919
- pendingOperation as aX,
45920
- promiseFactoryToObservable as aY,
45921
- retry as aZ,
45922
- logError as a_,
45923
- GuardrailsCheckStatus as aa,
45924
- LRUCache$1 as ab,
45925
- isError as ac,
45926
- RateLimitError as ad,
45927
- FeatureFlag as ae,
45928
- reformatBotMessageForChat as af,
45929
- isAbortErrorOrSocketHangUp as ag,
45930
- ModelTag as ah,
45931
- DeepCodyAgentID as ai,
45932
- serializedPromptEditorStateFromChatMessage as aj,
45933
- contextItemsFromPromptEditorValue as ak,
45934
- filterContextItemsFromPromptEditorValue as al,
45935
- View as am,
45936
- isMacOS as an,
45937
- ToolCodyModelName as ao,
45938
- CustomCommandType as ap,
45939
- textContentFromSerializedLexicalNode as aq,
45940
- firstValueFrom as ar,
45941
- skipPendingOperation as as,
45942
- FAST_CHAT_INPUT_TOKEN_BUDGET as at,
45943
- webviewOpenURIForContextItem as au,
45944
- pluralize as av,
45945
- UIToolStatus as aw,
45946
- getFileDiff as ax,
45947
- diffWithLineNum as ay,
45948
- UITerminalOutputType as az,
45949
- REMOTE_DIRECTORY_PROVIDER_URI as b,
45950
- UIKind as b$,
45951
- semver$1 as b0,
45952
- debounceTime as b1,
45953
- interval as b2,
45954
- filter$1 as b3,
45955
- startWith as b4,
45956
- switchMap as b5,
45957
- logDebug as b6,
45958
- isAbortError as b7,
45959
- expand$1 as b8,
45960
- TRANSIENT_REFETCH_INTERVAL_HINT as b9,
45961
- ps as bA,
45962
- GuardrailsMode as bB,
45963
- currentResolvedConfig as bC,
45964
- CORPUS_CONTEXT_ALLOCATION as bD,
45965
- recordErrorToSpan as bE,
45966
- addClientInfoParams as bF,
45967
- dependentAbortController as bG,
45968
- isS2 as bH,
45969
- GIT_OPENCTX_PROVIDER_URI as bI,
45970
- CODE_SEARCH_PROVIDER_URI as bJ,
45971
- currentOpenCtxController as bK,
45972
- MulticastSubject as bL,
45973
- AsyncSerialScheduler_1 as bM,
45974
- workspace as bN,
45975
- vscode as bO,
45976
- Range as bP,
45977
- commands as bQ,
45978
- window$1 as bR,
45979
- Selection as bS,
45980
- AgentEventEmitter as bT,
45981
- MarkdownString as bU,
45982
- Disposable as bV,
45983
- TextEditorRevealType as bW,
45984
- ThemeIcon as bX,
45985
- StatusBarAlignment as bY,
45986
- readFile as bZ,
45987
- env as b_,
45988
- createSubscriber as ba,
45989
- fromVSCodeEvent as bb,
45990
- cenv as bc,
45991
- EXCLUDE_EVERYTHING_CONTEXT_FILTERS as bd,
45992
- isFileURI as be,
45993
- INCLUDE_EVERYTHING_CONTEXT_FILTERS as bf,
45994
- onAbort as bg,
45995
- CHAT_INPUT_TOKEN_BUDGET as bh,
45996
- CHAT_OUTPUT_TOKEN_BUDGET as bi,
45997
- EXTENDED_CHAT_INPUT_TOKEN_BUDGET as bj,
45998
- EXTENDED_USER_CONTEXT_TOKEN_BUDGET as bk,
45999
- addCodyClientIdentificationHeaders as bl,
46000
- addTraceparent as bm,
46001
- addAuthHeaders as bn,
46002
- fetch as bo,
46003
- verifyResponseCode as bp,
46004
- take as bq,
46005
- clientCapabilities as br,
46006
- shareReplay as bs,
46007
- tap as bt,
46008
- featureFlagProvider as bu,
46009
- telemetryRecorder as bv,
46010
- currentAuthStatusOrNotReadyYet as bw,
46011
- mockAuthStatus as bx,
46012
- storeLastValue as by,
46013
- resolvedConfig as bz,
46014
- commonjsGlobal as c,
46015
- isRateLimitError as c$,
46016
- languages as c0,
46017
- InvalidAccessTokenError as c1,
46018
- _baseAssignValue as c2,
46019
- eq_1$1 as c3,
46020
- isArrayLike_1 as c4,
46021
- isObjectLike_1 as c5,
46022
- _copyObject as c6,
46023
- keysIn_1 as c7,
46024
- _cloneBufferExports as c8,
46025
- _cloneTypedArray as c9,
46026
- externalAuthRefresh as cA,
46027
- setAuthStatusObservable as cB,
46028
- normalizeServerEndpointURL as cC,
46029
- AuthConfigError as cD,
46030
- SourcegraphGraphQLAPIClient as cE,
46031
- isExternalProviderAuthError as cF,
46032
- isNetworkLikeError as cG,
46033
- NeedsAuthChallengeError as cH,
46034
- AvailabilityError as cI,
46035
- currentAuthStatus as cJ,
46036
- resolveAuth as cK,
46037
- QuickPickItemKind as cL,
46038
- getAuthHeaders as cM,
46039
- toLightweightChatTranscript as cN,
46040
- SUPPORTED_URI_SCHEMAS as cO,
46041
- RelativePattern as cP,
46042
- _baseIsEqual as cQ,
46043
- keys_1 as cR,
46044
- _baseGet as cS,
46045
- _castPath as cT,
46046
- isLength_1 as cU,
46047
- _toKey as cV,
46048
- _isKey as cW,
46049
- toNumber_1 as cX,
46050
- _baseFindIndex as cY,
46051
- require$$0 as cZ,
46052
- NetworkError as c_,
46053
- _copyArray as ca,
46054
- _initCloneObject as cb,
46055
- isArguments_1 as cc,
46056
- isArray_1 as cd,
46057
- isBufferExports as ce,
46058
- isFunction_1 as cf,
46059
- isObject_1 as cg,
46060
- isPlainObject_1 as ch,
46061
- isTypedArray_1 as ci,
46062
- _Stack as cj,
46063
- identity_1 as ck,
46064
- _overRest as cl,
46065
- _setToString as cm,
46066
- _isIndex as cn,
46067
- CONFIG_KEY as co,
46068
- ConfigurationTarget as cp,
46069
- pathBrowserify as cq,
46070
- stat as cr,
46071
- extensions as cs,
46072
- version as ct,
46073
- setExtensionVersion as cu,
46074
- isInvalidAccessTokenError as cv,
46075
- DOTCOM_URL as cw,
46076
- isNeedsAuthChallengeError as cx,
46077
- EMPTY as cy,
46078
- disposableSubscription as cz,
46079
- RULES_PROVIDER_URI as d,
46080
- main$1 as d$,
46081
- FileType as d0,
46082
- dedent as d1,
46083
- FoldingRange as d2,
46084
- CancellationTokenSource2 as d3,
46085
- SymbolKind as d4,
46086
- convertGitCloneURLToCodebaseName as d5,
46087
- pluck as d6,
46088
- toRangeData as d7,
46089
- Position as d8,
46090
- DefaultChatCommands as d9,
46091
- ruleSearchPaths as dA,
46092
- isRuleFilename as dB,
46093
- parseRuleFile as dC,
46094
- languageFromFilename as dD,
46095
- ruleTitle as dE,
46096
- debounce_1 as dF,
46097
- isWindows as dG,
46098
- GLOBAL_SEARCH_PROVIDER_URI as dH,
46099
- mentionProvidersMetadata as dI,
46100
- ThemeColor as dJ,
46101
- QuickInputButtons as dK,
46102
- GENERAL_HELP_LABEL as dL,
46103
- CodeLens as dM,
46104
- defaultWebviewPanel as dN,
46105
- EndOfLine as dO,
46106
- ViewColumn as dP,
46107
- Location as dQ,
46108
- onDidChangeActiveTextEditor as dR,
46109
- tabGroups as dS,
46110
- workspaceTextDocuments as dT,
46111
- visibleTextEditors as dU,
46112
- onDidChangeVisibleTextEditors as dV,
46113
- fs as dW,
46114
- onDidCloseTextDocument as dX,
46115
- setCreateWebviewPanel as dY,
46116
- getAugmentedNamespace as dZ,
46117
- extensionConfiguration as d_,
46118
- pathFunctionsForURI as da,
46119
- uriParseNameAndExtension as db,
46120
- uriDirname as dc,
46121
- Utils as dd,
46122
- uriExtname as de,
46123
- uriBasename as df,
46124
- DefaultEditCommands as dg,
46125
- subscriptionDisposable as dh,
46126
- updateGlobalTelemetryInstances as di,
46127
- TelemetryRecorderProvider as dj,
46128
- telemetryRecorderProvider as dk,
46129
- createGitDiff as dl,
46130
- AgentWorkspaceEdit as dm,
46131
- TextDocumentChangeReason as dn,
46132
- omit$1 as dp,
46133
- getEditorInsertSpaces as dq,
46134
- escapeRegExp$1 as dr,
46135
- TimeoutError as ds,
46136
- isNetworkError as dt,
46137
- displayPathWithoutWorkspaceFolderPrefix as du,
46138
- http as dv,
46139
- open as dw,
46140
- defer as dx,
46141
- merge$1 as dy,
46142
- abortableOperation as dz,
46143
- displayPath as e,
46144
- catchError as e$,
46145
- setAgent as e0,
46146
- setWorkspaceDocuments as e1,
46147
- setLastOpenedWorkspaceFolder as e2,
46148
- onDidRegisterNewCodeActionProvider as e3,
46149
- onDidUnregisterNewCodeActionProvider as e4,
46150
- onDidRegisterNewCodeLensProvider as e5,
46151
- onDidUnregisterNewCodeLensProvider as e6,
46152
- setClientInfo as e7,
46153
- firstNonPendingAuthStatus as e8,
46154
- workspaceFolders as e9,
46155
- dedupeWith as eA,
46156
- AbortError as eB,
46157
- createDisposables as eC,
46158
- isNodeResponse as eD,
46159
- getClientInfoQueryParams as eE,
46160
- tracer as eF,
46161
- getActiveTraceAndSpanId as eG,
46162
- getClientIdentificationHeaders as eH,
46163
- setJSONAcceptContentTypeHeaders as eI,
46164
- logResponseHeadersToSpan as eJ,
46165
- isCustomAuthChallengeResponse as eK,
46166
- TracedError as eL,
46167
- capitalize$2 as eM,
46168
- InlineCompletionItem as eN,
46169
- createTwoFilesPatch as eO,
46170
- vsCodeMocks as eP,
46171
- getEditorTabSize as eQ,
46172
- metrics as eR,
46173
- _ as eS,
46174
- editorStateFromPromptString as eT,
46175
- _baseGetTag as eU,
46176
- inputTextWithoutContextChipsFromPromptEditorState as eV,
46177
- exec as eW,
46178
- expandToLineRange as eX,
46179
- openctxController as eY,
46180
- openCtxProviderMetadata as eZ,
46181
- CODY_PASSTHROUGH_VSCODE_OPEN_COMMAND_ID as e_,
46182
- setWorkspaceFolders as ea,
46183
- onDidChangeWorkspaceFolders as eb,
46184
- onDidChangeWindowState as ec,
46185
- onDidOpenTextDocument as ed,
46186
- onDidSaveTextDocument as ee,
46187
- onDidRenameFiles as ef,
46188
- packageJson as eg,
46189
- progressBars as eh,
46190
- CodeActionTriggerKind as ei,
46191
- CodeAction as ej,
46192
- UriString as ek,
46193
- DiagnosticSeverity as el,
46194
- diagnostics as em,
46195
- isIntegrationTesting as en,
46196
- TESTING_TELEMETRY_EXPORTER as eo,
46197
- ProgressLocation as ep,
46198
- dist as eq,
46199
- completionProvider as er,
46200
- InlineCompletionTriggerKind as es,
46201
- currentAuthStatusAuthed as et,
46202
- waitUntilComplete as eu,
46203
- setExtensionConfiguration as ev,
46204
- onDidChangeConfiguration as ew,
46205
- onDidChangeTextDocument as ex,
46206
- onDidChangeTextEditorSelection as ey,
46207
- structuredPatch as ez,
46208
- displayLineRange as f,
46209
- getPlatform as f0,
46210
- PromptMode as f1,
46211
- skip as f2,
46212
- extractContextFromTraceparent as f3,
46213
- isContextWindowLimitError as f4,
46214
- addMessageListenersForExtensionAPI as f5,
46215
- createMessageAPIForExtension as f6,
46216
- NEVER as f7,
46217
- CodeActionKind as f8,
46218
- assertFileURI as f9,
46219
- createCodeSearchProvider as fa,
46220
- ProgrammingLanguage as fb,
46221
- psDedent as fc,
46222
- formatRuleForPrompt as fd,
46223
- posixFilePaths as fe,
46224
- DecorationRangeBehavior as ff,
46225
- diffLines as fg,
46226
- CODY_SUPPORT_URL as fh,
46227
- CODY_DOC_URL as fi,
46228
- CODY_FEEDBACK_URL as fj,
46229
- DISCORD_URL as fk,
46230
- globalAgentRef as fl,
46231
- VSCODE_CHANGELOG_URL as fm,
46232
- SG_CHANGELOG_URL as fn,
46233
- ACCOUNT_LIMITS_INFO_URL as fo,
46234
- assertUnreachable as fp,
46235
- promise as fq,
46236
- ExtensionMode as fr,
46237
- setLogger as fs,
46238
- setClientCapabilities as ft,
46239
- setResolvedConfigurationObservable as fu,
46240
- setClientNameVersion as fv,
46241
- setOpenCtxControllerObservable as fw,
46242
- child_process as fx,
46243
- getDefaultExportFromCjs as g,
46244
- displayPathDirname as h,
46245
- displayPathBasename as i,
46246
- string$1 as j,
46247
- displayPathWithLines as k,
46248
- literal as l,
46249
- URI as m,
46250
- is$2 as n,
46251
- object as o,
46816
+ displayPathWithLines as V,
46817
+ displayPathBasename as W,
46818
+ uriHasPrefix as X,
46819
+ displayPathDirname as Y,
46820
+ displayPathWithoutWorkspaceFolderPrefix as Z,
46821
+ setDisplayPathEnvInfo as _,
46822
+ isError as a,
46823
+ openctxController as a$,
46824
+ forceHydration as a0,
46825
+ hydrateAfterPostMessage as a1,
46826
+ FeatureFlag as a2,
46827
+ featureFlagProvider as a3,
46828
+ createGuardrailsImpl as a4,
46829
+ GuardrailsMode as a5,
46830
+ GuardrailsCheckStatus as a6,
46831
+ logDebug as a7,
46832
+ logError as a8,
46833
+ setLogger as a9,
46834
+ isNetworkLikeError as aA,
46835
+ isRateLimitError as aB,
46836
+ SourcegraphGraphQLAPIClient as aC,
46837
+ graphqlClient as aD,
46838
+ isNodeResponse as aE,
46839
+ INCLUDE_EVERYTHING_CONTEXT_FILTERS as aF,
46840
+ EXCLUDE_EVERYTHING_CONTEXT_FILTERS as aG,
46841
+ PromptMode as aH,
46842
+ setJSONAcceptContentTypeHeaders as aI,
46843
+ isCustomAuthChallengeResponse as aJ,
46844
+ GraphQLTelemetryExporter as aK,
46845
+ MockServerTelemetryRecorderProvider as aL,
46846
+ NoOpTelemetryRecorderProvider as aM,
46847
+ TelemetryRecorderProvider as aN,
46848
+ noOpTelemetryRecorder as aO,
46849
+ assertUnreachable as aP,
46850
+ convertGitCloneURLToCodebaseName as aQ,
46851
+ createSubscriber as aR,
46852
+ nextTick as aS,
46853
+ promise as aT,
46854
+ parseMentionQuery as aU,
46855
+ scanForMentionTriggerInUserTextInput as aV,
46856
+ mentionProvidersMetadata as aW,
46857
+ openCtxProviderMetadata as aX,
46858
+ FILE_CONTEXT_MENTION_PROVIDER as aY,
46859
+ SYMBOL_CONTEXT_MENTION_PROVIDER as aZ,
46860
+ setOpenCtxControllerObservable as a_,
46861
+ addClientInfoParams as aa,
46862
+ getClientInfoQueryParams as ab,
46863
+ getClientIdentificationHeaders as ac,
46864
+ setClientNameVersion as ad,
46865
+ addCodyClientIdentificationHeaders as ae,
46866
+ DOTCOM_URL as af,
46867
+ isDotCom as ag,
46868
+ DOTCOM_WORKSPACE_UPGRADE_URL as ah,
46869
+ AbortError as ai,
46870
+ AuthConfigError as aj,
46871
+ AuthError as ak,
46872
+ AvailabilityError as al,
46873
+ ExternalAuthProviderError as am,
46874
+ InvalidAccessTokenError as an,
46875
+ NeedsAuthChallengeError as ao,
46876
+ NetworkError as ap,
46877
+ RateLimitError as aq,
46878
+ TimeoutError as ar,
46879
+ TracedError as as,
46880
+ isAbortErrorOrSocketHangUp as at,
46881
+ isAuthError as au,
46882
+ isAvailabilityError as av,
46883
+ isContextWindowLimitError as aw,
46884
+ isInvalidAccessTokenError as ax,
46885
+ isNeedsAuthChallengeError as ay,
46886
+ isNetworkError as az,
46887
+ isDefined as b,
46888
+ filterContextItemsFromPromptEditorValue as b$,
46889
+ REMOTE_REPOSITORY_PROVIDER_URI as b0,
46890
+ REMOTE_FILE_PROVIDER_URI as b1,
46891
+ REMOTE_DIRECTORY_PROVIDER_URI as b2,
46892
+ WEB_PROVIDER_URI as b3,
46893
+ GIT_OPENCTX_PROVIDER_URI as b4,
46894
+ CODE_SEARCH_PROVIDER_URI as b5,
46895
+ GLOBAL_SEARCH_PROVIDER_URI as b6,
46896
+ currentOpenCtxController as b7,
46897
+ RULES_PROVIDER_URI as b8,
46898
+ proxyExtensionAPI as b9,
46899
+ extractContextFromTraceparent as bA,
46900
+ AUTH_STATUS_FIXTURE_AUTHED as bB,
46901
+ AUTH_STATUS_FIXTURE_UNAUTHED as bC,
46902
+ AUTH_STATUS_FIXTURE_AUTHED_DOTCOM as bD,
46903
+ PromptString as bE,
46904
+ ps as bF,
46905
+ psDedent as bG,
46906
+ isValidPromptString as bH,
46907
+ fetch$1 as bI,
46908
+ globalAgentRef as bJ,
46909
+ toPartialUtf8String as bK,
46910
+ getAuthHeaders as bL,
46911
+ addAuthHeaders as bM,
46912
+ CHAT_INPUT_TOKEN_BUDGET as bN,
46913
+ FAST_CHAT_INPUT_TOKEN_BUDGET as bO,
46914
+ CHAT_OUTPUT_TOKEN_BUDGET as bP,
46915
+ CORPUS_CONTEXT_ALLOCATION as bQ,
46916
+ EXTENDED_USER_CONTEXT_TOKEN_BUDGET as bR,
46917
+ EXTENDED_CHAT_INPUT_TOKEN_BUDGET as bS,
46918
+ CodyIDE as bT,
46919
+ CodyAutoSuggestionMode as bU,
46920
+ AUTOCOMPLETE_PROVIDER_ID as bV,
46921
+ toSerializedPromptEditorValue as bW,
46922
+ serializedPromptEditorStateFromText as bX,
46923
+ serializedPromptEditorStateFromChatMessage as bY,
46924
+ contextItemsFromPromptEditorValue as bZ,
46925
+ inputTextWithoutContextChipsFromPromptEditorState as b_,
46926
+ addMessageListenersForExtensionAPI as ba,
46927
+ createMessageAPIForWebview as bb,
46928
+ createMessageAPIForExtension as bc,
46929
+ isS2 as bd,
46930
+ isWorkspaceInstance as be,
46931
+ createGitDiff as bf,
46932
+ serialize as bg,
46933
+ deserialize as bh,
46934
+ isRuleFilename as bi,
46935
+ ruleTitle as bj,
46936
+ parseRuleFile as bk,
46937
+ ruleSearchPaths as bl,
46938
+ dependentAbortController as bm,
46939
+ onAbort as bn,
46940
+ getEditorInsertSpaces as bo,
46941
+ getEditorTabSize as bp,
46942
+ getEditorIndentString as bq,
46943
+ telemetryRecorderProvider as br,
46944
+ telemetryRecorder as bs,
46945
+ updateGlobalTelemetryInstances as bt,
46946
+ tracer as bu,
46947
+ getActiveTraceAndSpanId as bv,
46948
+ addTraceparent as bw,
46949
+ logResponseHeadersToSpan as bx,
46950
+ getTraceparentHeaders as by,
46951
+ recordErrorToSpan as bz,
46952
+ URI as c,
46953
+ switchMapReplayOperation as c$,
46954
+ textContentFromSerializedLexicalNode as c0,
46955
+ editorStateToText as c1,
46956
+ editorStateFromPromptString as c2,
46957
+ CONTEXT_ITEM_MENTION_NODE_TYPE as c3,
46958
+ TEMPLATE_INPUT_NODE_TYPE as c4,
46959
+ serializeContextItem as c5,
46960
+ deserializeContextItem as c6,
46961
+ isSerializedContextItemMentionNode as c7,
46962
+ isSerializedTemplateInputNode as c8,
46963
+ getMentionOperations as c9,
46964
+ pluck as cA,
46965
+ pick as cB,
46966
+ shareReplay as cC,
46967
+ takeUntil as cD,
46968
+ finalize as cE,
46969
+ distinctUntilChanged as cF,
46970
+ tap as cG,
46971
+ tapLog as cH,
46972
+ printDiff as cI,
46973
+ startWith as cJ,
46974
+ take as cK,
46975
+ skip as cL,
46976
+ mergeMap as cM,
46977
+ switchMap as cN,
46978
+ storeLastValue as cO,
46979
+ debounceTime as cP,
46980
+ concat as cQ,
46981
+ concatMap as cR,
46982
+ lifecycle as cS,
46983
+ abortableOperation as cT,
46984
+ catchError as cU,
46985
+ withLatestFrom as cV,
46986
+ defer as cW,
46987
+ filter$1 as cX,
46988
+ testing__firstValueFromWithinTime as cY,
46989
+ retry as cZ,
46990
+ pendingOperation as c_,
46991
+ contextItemMentionNodePromptText as ca,
46992
+ contextItemMentionNodeDisplayText as cb,
46993
+ templateInputNodeDisplayText as cc,
46994
+ createExtensionAPI as cd,
46995
+ subscriptionDisposable as ce,
46996
+ disposableSubscription as cf,
46997
+ observableOfSequence as cg,
46998
+ observableOfTimedSequence as ch,
46999
+ firstValueFrom as ci,
47000
+ toFirstValueGetter as cj,
47001
+ waitUntilComplete as ck,
47002
+ allValuesFrom as cl,
47003
+ readValuesFrom as cm,
47004
+ promiseToObservable as cn,
47005
+ promiseFactoryToObservable as co,
47006
+ fromLateSetSource as cp,
47007
+ EMPTY as cq,
47008
+ NEVER as cr,
47009
+ merge$1 as cs,
47010
+ combineLatest as ct,
47011
+ memoizeLastValue as cu,
47012
+ NO_INITIAL_VALUE as cv,
47013
+ fromVSCodeEvent as cw,
47014
+ vscodeResource as cx,
47015
+ disposeOnUnsubscribe as cy,
47016
+ createDisposables as cz,
47017
+ isWindows as d,
47018
+ expand$1 as d$,
47019
+ skipPendingOperation as d0,
47020
+ firstResultFromOperation as d1,
47021
+ setResolvedConfigurationObservable as d2,
47022
+ setStaticResolvedConfigurationValue as d3,
47023
+ resolvedConfig as d4,
47024
+ currentResolvedConfig as d5,
47025
+ mockResolvedConfig as d6,
47026
+ clientCapabilities as d7,
47027
+ setClientCapabilities as d8,
47028
+ setExtensionVersion as d9,
47029
+ SpanStatusCode as dA,
47030
+ svg as dB,
47031
+ html as dC,
47032
+ whitespace as dD,
47033
+ find as dE,
47034
+ stringify$1 as dF,
47035
+ stringify as dG,
47036
+ ccount as dH,
47037
+ CodyTaskState as dI,
47038
+ cryptoJsExports as dJ,
47039
+ LRUCache$1 as dK,
47040
+ DeepCodyAgentID as dL,
47041
+ View as dM,
47042
+ ToolCodyModelName as dN,
47043
+ getFileDiff as dO,
47044
+ diffWithLineNum as dP,
47045
+ isCodeSearchContextItem as dQ,
47046
+ v4 as dR,
47047
+ lodashExports as dS,
47048
+ ChatHistoryType as dT,
47049
+ ACCOUNT_USAGE_URL as dU,
47050
+ CODY_DOC_QUICKSTART_URL as dV,
47051
+ browser$1 as dW,
47052
+ unsubscribe as dX,
47053
+ AsyncSerialScheduler$1 as dY,
47054
+ semver$1 as dZ,
47055
+ interval as d_,
47056
+ mockClientCapabilities as da,
47057
+ CLIENT_CAPABILITIES_FIXTURE as db,
47058
+ cenv as dc,
47059
+ setAuthStatusObservable as dd,
47060
+ authStatus as de,
47061
+ currentAuthStatus as df,
47062
+ currentAuthStatusAuthed as dg,
47063
+ currentAuthStatusOrNotReadyYet as dh,
47064
+ firstNonPendingAuthStatus as di,
47065
+ mockAuthStatus as dj,
47066
+ UIToolStatus as dk,
47067
+ UITerminalOutputType as dl,
47068
+ commonjsGlobal as dm,
47069
+ getDefaultExportFromCjs as dn,
47070
+ object as dp,
47071
+ literal as dq,
47072
+ string$1 as dr,
47073
+ is$2 as ds,
47074
+ Observable as dt,
47075
+ debounce$1 as du,
47076
+ isEqual$1 as dv,
47077
+ map$1 as dw,
47078
+ isSourcegraphToken as dx,
47079
+ trace as dy,
47080
+ context$1 as dz,
47081
+ CODY_PASSTHROUGH_VSCODE_OPEN_COMMAND_ID as e,
47082
+ isLength_1 as e$,
47083
+ TRANSIENT_REFETCH_INTERVAL_HINT as e0,
47084
+ verifyResponseCode as e1,
47085
+ logInfo as e2,
47086
+ MulticastSubject as e3,
47087
+ AsyncSerialScheduler_1 as e4,
47088
+ workspace as e5,
47089
+ vscode as e6,
47090
+ Range as e7,
47091
+ commands as e8,
47092
+ window$1 as e9,
47093
+ isPlainObject_1 as eA,
47094
+ isTypedArray_1 as eB,
47095
+ _Stack as eC,
47096
+ identity_1 as eD,
47097
+ _overRest as eE,
47098
+ _setToString as eF,
47099
+ _isIndex as eG,
47100
+ CONFIG_KEY as eH,
47101
+ ConfigurationTarget as eI,
47102
+ appendFileSync as eJ,
47103
+ pathBrowserify as eK,
47104
+ stat as eL,
47105
+ extensions as eM,
47106
+ version as eN,
47107
+ normalizeServerEndpointURL as eO,
47108
+ isOAuthProviderError as eP,
47109
+ externalAuthRefresh as eQ,
47110
+ isExternalAuthProviderError as eR,
47111
+ resolveAuth as eS,
47112
+ QuickPickItemKind as eT,
47113
+ revokeOAuthTokens as eU,
47114
+ toLightweightChatTranscript as eV,
47115
+ RelativePattern as eW,
47116
+ _baseIsEqual as eX,
47117
+ keys_1 as eY,
47118
+ _baseGet as eZ,
47119
+ _castPath as e_,
47120
+ Selection as ea,
47121
+ AgentEventEmitter as eb,
47122
+ MarkdownString as ec,
47123
+ Disposable as ed,
47124
+ TextEditorRevealType as ee,
47125
+ ThemeIcon as ef,
47126
+ StatusBarAlignment as eg,
47127
+ readFile as eh,
47128
+ env as ei,
47129
+ UIKind as ej,
47130
+ languages as ek,
47131
+ _baseAssignValue as el,
47132
+ eq_1$1 as em,
47133
+ isArrayLike_1 as en,
47134
+ isObjectLike_1 as eo,
47135
+ _copyObject as ep,
47136
+ keysIn_1 as eq,
47137
+ _cloneBufferExports as er,
47138
+ _cloneTypedArray as es,
47139
+ _copyArray as et,
47140
+ _initCloneObject as eu,
47141
+ isArguments_1 as ev,
47142
+ isArray_1 as ew,
47143
+ isBufferExports as ex,
47144
+ isFunction_1 as ey,
47145
+ isObject_1 as ez,
47146
+ webviewOpenURIForContextItem as f,
47147
+ TESTING_TELEMETRY_EXPORTER as f$,
47148
+ _toKey as f0,
47149
+ _isKey as f1,
47150
+ toNumber_1 as f2,
47151
+ _baseFindIndex as f3,
47152
+ require$$0 as f4,
47153
+ FileType as f5,
47154
+ dedent as f6,
47155
+ FoldingRange as f7,
47156
+ CancellationTokenSource2 as f8,
47157
+ SymbolKind as f9,
47158
+ existsSync as fA,
47159
+ rmSync as fB,
47160
+ mkdirSync as fC,
47161
+ main$1 as fD,
47162
+ setAgent as fE,
47163
+ setWorkspaceDocuments as fF,
47164
+ setLastOpenedWorkspaceFolder as fG,
47165
+ onDidRegisterNewCodeActionProvider as fH,
47166
+ onDidUnregisterNewCodeActionProvider as fI,
47167
+ onDidRegisterNewCodeLensProvider as fJ,
47168
+ onDidUnregisterNewCodeLensProvider as fK,
47169
+ setClientInfo as fL,
47170
+ workspaceFolders as fM,
47171
+ setWorkspaceFolders as fN,
47172
+ onDidChangeWorkspaceFolders as fO,
47173
+ onDidChangeWindowState as fP,
47174
+ onDidOpenTextDocument as fQ,
47175
+ onDidSaveTextDocument as fR,
47176
+ onDidRenameFiles as fS,
47177
+ packageJson as fT,
47178
+ progressBars as fU,
47179
+ CodeActionTriggerKind as fV,
47180
+ CodeAction as fW,
47181
+ UriString as fX,
47182
+ DiagnosticSeverity as fY,
47183
+ diagnostics as fZ,
47184
+ isIntegrationTesting as f_,
47185
+ Position as fa,
47186
+ Utils as fb,
47187
+ AgentWorkspaceEdit as fc,
47188
+ TextDocumentChangeReason as fd,
47189
+ omit$1 as fe,
47190
+ escapeRegExp$1 as ff,
47191
+ http as fg,
47192
+ open as fh,
47193
+ debounce_1 as fi,
47194
+ ThemeColor as fj,
47195
+ QuickInputButtons as fk,
47196
+ CodeLens as fl,
47197
+ defaultWebviewPanel as fm,
47198
+ EndOfLine as fn,
47199
+ ViewColumn as fo,
47200
+ Location as fp,
47201
+ onDidChangeActiveTextEditor as fq,
47202
+ tabGroups as fr,
47203
+ workspaceTextDocuments as fs,
47204
+ visibleTextEditors as ft,
47205
+ onDidChangeVisibleTextEditors as fu,
47206
+ fs as fv,
47207
+ onDidCloseTextDocument as fw,
47208
+ setCreateWebviewPanel as fx,
47209
+ getAugmentedNamespace as fy,
47210
+ extensionConfiguration as fz,
47211
+ CustomCommandType as g,
47212
+ ProgressLocation as g0,
47213
+ dist as g1,
47214
+ completionProvider as g2,
47215
+ InlineCompletionTriggerKind as g3,
47216
+ setExtensionConfiguration as g4,
47217
+ onDidChangeConfiguration as g5,
47218
+ onDidChangeTextDocument as g6,
47219
+ onDidChangeTextEditorSelection as g7,
47220
+ statSync as g8,
47221
+ copySync as g9,
47222
+ getOIDCConfiguration as ga,
47223
+ getOAuthClientId as gb,
47224
+ OAuthCredential as gc,
47225
+ structuredPatch as gd,
47226
+ capitalize$2 as ge,
47227
+ InlineCompletionItem as gf,
47228
+ createTwoFilesPatch as gg,
47229
+ vsCodeMocks as gh,
47230
+ metrics as gi,
47231
+ _ as gj,
47232
+ _baseGetTag as gk,
47233
+ exec as gl,
47234
+ getPlatform as gm,
47235
+ CodeActionKind as gn,
47236
+ createCodeSearchProvider as go,
47237
+ formatRuleForPrompt as gp,
47238
+ DecorationRangeBehavior as gq,
47239
+ diffLines as gr,
47240
+ CODY_SUPPORT_URL as gs,
47241
+ CODY_DOC_URL as gt,
47242
+ DISCORD_URL as gu,
47243
+ VSCODE_CHANGELOG_URL as gv,
47244
+ SG_CHANGELOG_URL as gw,
47245
+ ACCOUNT_LIMITS_INFO_URL as gx,
47246
+ ExtensionMode as gy,
47247
+ child_process as gz,
47248
+ DefaultEditCommands as h,
47249
+ isAbortError as i,
47250
+ dedupeWith as j,
47251
+ isErrorLike as k,
47252
+ pluralize as l,
47253
+ displayLineRange as m,
47254
+ displayRange as n,
47255
+ expandToLineRange as o,
46252
47256
  path$1 as p,
46253
- serializeContextItem as q,
46254
- CONTEXT_ITEM_MENTION_NODE_TYPE as r,
47257
+ languageFromFilename as q,
47258
+ reformatBotMessageForChat as r,
46255
47259
  spawn as s,
46256
- contextItemMentionNodeDisplayText as t,
46257
- parseMentionQuery as u,
46258
- FILE_RANGE_TOOLTIP_LABEL as v,
47260
+ toRangeData as t,
47261
+ languageFromFilenameAndContent as u,
47262
+ markdownCodeBlockLanguageIDForFilename as v,
46259
47263
  wrapInActiveSpan as w,
46260
- createExtensionAPI as x,
46261
- createMessageAPIForWebview as y,
46262
- debounce$1 as z
47264
+ extensionForLanguage as x,
47265
+ isMatlabFile as y,
47266
+ posixFilePaths as z
46263
47267
  };