@gearbox-protocol/deploy-tools 5.49.3 → 5.49.5

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.
Files changed (2) hide show
  1. package/dist/index.mjs +7 -14
  2. package/package.json +1 -1
package/dist/index.mjs CHANGED
@@ -395314,16 +395314,6 @@ function createRawTx(to, parameters, description) {
395314
395314
  };
395315
395315
  }
395316
395316
 
395317
- // ../../node_modules/@gearbox-protocol/sdk/dist/esm/sdk/utils/etherscan.js
395318
- function etherscanApiUrl(networkOrChainId) {
395319
- const chain = getChain(networkOrChainId);
395320
- const url2 = chain.blockExplorers?.default?.apiUrl;
395321
- if (!url2) {
395322
- throw new Error(`block explorer api url for ${chain.name} not configured`);
395323
- }
395324
- return url2;
395325
- }
395326
-
395327
395317
  // ../../node_modules/date-fns/constants.js
395328
395318
  var daysInYear = 365.2425;
395329
395319
  var maxTime = Math.pow(10, 8) * 24 * 60 * 60 * 1e3;
@@ -429523,7 +429513,10 @@ var log_default = logger;
429523
429513
  // ../../packages/node/dist/git.js
429524
429514
  var log = log_default.child({ name: "git" });
429525
429515
  function getGithubUrl(repo, https = false) {
429526
- const credentials = process.env.GITHUB_TOKEN ?? process.env.GH_TOKEN;
429516
+ const credentials = process.env.GIT_TOKEN ?? process.env.GITHUB_TOKEN ?? process.env.GH_TOKEN;
429517
+ if (credentials) {
429518
+ log.debug(`using git token *****${credentials.slice(-4)}`);
429519
+ }
429527
429520
  const path12 = repo.replace(/^@/, "").replace(/\/$/, "");
429528
429521
  const cred = credentials ? `${credentials}@` : "";
429529
429522
  return https || credentials ? `https://${cred}github.com/${path12}.git` : `git@github.com:${path12}.git`;
@@ -451219,7 +451212,7 @@ var EtherscanVerifier = class extends ProviderBase {
451219
451212
  #etherscanApiKey;
451220
451213
  async init() {
451221
451214
  await super.init();
451222
- this.#etherscanBase = etherscanApiUrl(this.chainId);
451215
+ this.#etherscanBase = `https://api.etherscan.io/v2/api?chainid=${this.chainId}`;
451223
451216
  const apikey = API_KEYS[this.network]?.(this.options);
451224
451217
  if (!apikey) {
451225
451218
  throw new Error(`etherscan api key not specified for ${this.network}`);
@@ -451301,7 +451294,7 @@ var EtherscanVerifier = class extends ProviderBase {
451301
451294
  await writeFile2(cacheFile, json_stringify(result));
451302
451295
  }
451303
451296
  async #fetch(address) {
451304
- const url2 = `${this.etherscanBase}?module=contract&action=getsourcecode&address=${address}&apikey=${this.etherscanApiKey}`;
451297
+ const url2 = `${this.etherscanBase}&module=contract&action=getsourcecode&address=${address}&apikey=${this.etherscanApiKey}`;
451305
451298
  const _fetch = async () => {
451306
451299
  const resp = await fetch(url2);
451307
451300
  const data = await resp.json();
@@ -458770,7 +458763,7 @@ function getRenderer(opts) {
458770
458763
  var package_default = {
458771
458764
  name: "@gearbox-protocol/deploy-tools",
458772
458765
  description: "Gearbox deploy tools",
458773
- version: "5.49.3",
458766
+ version: "5.49.5",
458774
458767
  homepage: "https://gearbox.fi",
458775
458768
  keywords: [
458776
458769
  "gearbox"
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@gearbox-protocol/deploy-tools",
3
3
  "description": "Gearbox deploy tools",
4
- "version": "5.49.3",
4
+ "version": "5.49.5",
5
5
  "homepage": "https://gearbox.fi",
6
6
  "keywords": [
7
7
  "gearbox"