@cloudsnorkel/cdk-github-runners 0.7.6 → 0.8.1

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.
@@ -6913,7 +6913,9 @@ var require_lib3 = __commonJS({
6913
6913
  if (signal && signal.aborted) {
6914
6914
  return;
6915
6915
  }
6916
- destroyStream(response.body, err);
6916
+ if (response && response.body) {
6917
+ destroyStream(response.body, err);
6918
+ }
6917
6919
  });
6918
6920
  if (parseInt(process.version.substring(1)) < 14) {
6919
6921
  req.on("socket", function(s) {
@@ -7689,7 +7691,7 @@ var require_dist_node6 = __commonJS({
7689
7691
  parse
7690
7692
  });
7691
7693
  }
7692
- var VERSION = "7.0.3";
7694
+ var VERSION = "7.0.5";
7693
7695
  var userAgent = `octokit-endpoint.js/${VERSION} ${universalUserAgent.getUserAgent()}`;
7694
7696
  var DEFAULTS = {
7695
7697
  method: "GET",
@@ -7775,7 +7777,7 @@ var require_dist_node8 = __commonJS({
7775
7777
  var isPlainObject = require_is_plain_object();
7776
7778
  var nodeFetch = _interopDefault(require_lib3());
7777
7779
  var requestError = require_dist_node7();
7778
- var VERSION = "6.2.2";
7780
+ var VERSION = "6.2.3";
7779
7781
  function getBufferResponse(response) {
7780
7782
  return response.arrayBuffer();
7781
7783
  }
@@ -8248,7 +8250,7 @@ var require_dist_node10 = __commonJS({
8248
8250
  parse
8249
8251
  });
8250
8252
  }
8251
- var VERSION = "7.0.3";
8253
+ var VERSION = "7.0.5";
8252
8254
  var userAgent = `octokit-endpoint.js/${VERSION} ${universalUserAgent.getUserAgent()}`;
8253
8255
  var DEFAULTS = {
8254
8256
  method: "GET",
@@ -8280,7 +8282,7 @@ var require_dist_node11 = __commonJS({
8280
8282
  var isPlainObject = require_is_plain_object();
8281
8283
  var nodeFetch = _interopDefault(require_lib3());
8282
8284
  var requestError = require_dist_node7();
8283
- var VERSION = "6.2.2";
8285
+ var VERSION = "6.2.3";
8284
8286
  function getBufferResponse(response) {
8285
8287
  return response.arrayBuffer();
8286
8288
  }
@@ -8437,7 +8439,7 @@ var require_dist_node12 = __commonJS({
8437
8439
  var request = require_dist_node11();
8438
8440
  var requestError = require_dist_node7();
8439
8441
  var btoa = _interopDefault(require_btoa_node());
8440
- var VERSION = "2.0.4";
8442
+ var VERSION = "2.0.5";
8441
8443
  function requestToOAuthBaseUrl(request2) {
8442
8444
  const endpointDefaults = request2.endpoint.DEFAULTS;
8443
8445
  return /^https:\/\/(api\.)?github\.com$/.test(endpointDefaults.baseUrl) ? "https://github.com" : endpointDefaults.baseUrl.replace("/api/v3", "");
@@ -8796,7 +8798,7 @@ var require_dist_node13 = __commonJS({
8796
8798
  endpoint.headers.authorization = `token ${token}`;
8797
8799
  return request2(endpoint);
8798
8800
  }
8799
- var VERSION = "4.0.3";
8801
+ var VERSION = "4.0.4";
8800
8802
  function createOAuthDeviceAuth(options) {
8801
8803
  const requestWithDefaults = options.request || request.request.defaults({
8802
8804
  headers: {
@@ -8844,7 +8846,7 @@ var require_dist_node14 = __commonJS({
8844
8846
  var authOauthDevice = require_dist_node13();
8845
8847
  var oauthMethods = require_dist_node12();
8846
8848
  var btoa = _interopDefault(require_btoa_node());
8847
- var VERSION = "2.1.0";
8849
+ var VERSION = "2.1.1";
8848
8850
  async function getAuthentication(state) {
8849
8851
  if ("code" in state.strategyOptions) {
8850
8852
  const {
@@ -8901,7 +8903,7 @@ var require_dist_node14 = __commonJS({
8901
8903
  }
8902
8904
  const currentAuthentication = state.authentication;
8903
8905
  if ("expiresAt" in currentAuthentication) {
8904
- if (options.type === "refresh" || new Date(currentAuthentication.expiresAt) < new Date()) {
8906
+ if (options.type === "refresh" || new Date(currentAuthentication.expiresAt) < /* @__PURE__ */ new Date()) {
8905
8907
  const {
8906
8908
  authentication
8907
8909
  } = await oauthMethods.refreshToken({
@@ -19126,7 +19128,7 @@ var require_dist_node17 = __commonJS({
19126
19128
  parse
19127
19129
  });
19128
19130
  }
19129
- var VERSION = "7.0.3";
19131
+ var VERSION = "7.0.5";
19130
19132
  var userAgent = `octokit-endpoint.js/${VERSION} ${universalUserAgent.getUserAgent()}`;
19131
19133
  var DEFAULTS = {
19132
19134
  method: "GET",
@@ -19158,7 +19160,7 @@ var require_dist_node18 = __commonJS({
19158
19160
  var isPlainObject = require_is_plain_object();
19159
19161
  var nodeFetch = _interopDefault(require_lib3());
19160
19162
  var requestError = require_dist_node7();
19161
- var VERSION = "6.2.2";
19163
+ var VERSION = "6.2.3";
19162
19164
  function getBufferResponse(response) {
19163
19165
  return response.arrayBuffer();
19164
19166
  }
@@ -20088,7 +20090,7 @@ var require_dist_node23 = __commonJS({
20088
20090
  }
20089
20091
  const currentAuthentication = state.authentication;
20090
20092
  if ("expiresAt" in currentAuthentication) {
20091
- if (options.type === "refresh" || new Date(currentAuthentication.expiresAt) < new Date()) {
20093
+ if (options.type === "refresh" || new Date(currentAuthentication.expiresAt) < /* @__PURE__ */ new Date()) {
20092
20094
  const {
20093
20095
  authentication
20094
20096
  } = await oauthMethods.refreshToken({
@@ -20476,7 +20478,7 @@ var require_dist_node24 = __commonJS({
20476
20478
  const repositorySelection = repositorySelectionOptional || "all";
20477
20479
  const repositoryIds = repositories ? repositories.map((r) => r.id) : void 0;
20478
20480
  const repositoryNames = repositories ? repositories.map((repo) => repo.name) : void 0;
20479
- const createdAt = new Date().toISOString();
20481
+ const createdAt = (/* @__PURE__ */ new Date()).toISOString();
20480
20482
  await set(state.cache, optionsWithInstallationTokenFromState, {
20481
20483
  token,
20482
20484
  createdAt,
@@ -20557,7 +20559,7 @@ var require_dist_node24 = __commonJS({
20557
20559
  if (typeof error.response.headers.date === "undefined") {
20558
20560
  throw error;
20559
20561
  }
20560
- const diff = Math.floor((Date.parse(error.response.headers.date) - Date.parse(new Date().toString())) / 1e3);
20562
+ const diff = Math.floor((Date.parse(error.response.headers.date) - Date.parse((/* @__PURE__ */ new Date()).toString())) / 1e3);
20561
20563
  state.log.warn(error.message);
20562
20564
  state.log.warn(`[@octokit/auth-app] GitHub API time and system time are different by ${diff} seconds. Retrying request with the difference accounted for.`);
20563
20565
  const {
@@ -20590,7 +20592,7 @@ var require_dist_node24 = __commonJS({
20590
20592
  return sendRequestWithRetries(state, request2, endpoint, createdAt);
20591
20593
  }
20592
20594
  async function sendRequestWithRetries(state, request2, options, createdAt, retries = 0) {
20593
- const timeSinceTokenCreationInMs = +new Date() - +new Date(createdAt);
20595
+ const timeSinceTokenCreationInMs = +/* @__PURE__ */ new Date() - +new Date(createdAt);
20594
20596
  try {
20595
20597
  return await request2(options);
20596
20598
  } catch (error) {