@gearbox-protocol/deploy-tools 5.11.8 → 5.11.10

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 +31 -38
  2. package/package.json +1 -1
package/dist/index.mjs CHANGED
@@ -414037,6 +414037,13 @@ function openAccounts() {
414037
414037
  automine: automineIntervalS = "1"
414038
414038
  } = opts;
414039
414039
  await mkdir2(path9.resolve(sharedDir, "deploy-state"), { recursive: true });
414040
+ const anvil = createAnvilClient({ transport: http(anvilUrl) });
414041
+ const automineInterval = parseInt(automineIntervalS, 10);
414042
+ const automine = await anvil.getAutomine();
414043
+ await anvil.setBlockTimestampInterval({ interval: automineInterval });
414044
+ log_default.debug(
414045
+ `setting block timestamp interval, automine: ${automine}, interval ${automineInterval}`
414046
+ );
414040
414047
  const sdkExample2 = new SDKExample(log_default);
414041
414048
  await sdkExample2.run({
414042
414049
  addressProvider,
@@ -414061,26 +414068,6 @@ function openAccounts() {
414061
414068
  args: [stringToHex("FAUCET", { size: 32 }), 0n]
414062
414069
  });
414063
414070
  log_default.debug(`faucet address: ${faucetAddr}`);
414064
- const anvil = createAnvilClient({ transport: http(anvilUrl) });
414065
- sdkExample2.sdk.priceFeeds.addHook(
414066
- "updatesGenerated",
414067
- async ({ timestamp }) => {
414068
- try {
414069
- const block = await anvil.evmMineDetailed(timestamp);
414070
- log_default.debug(
414071
- { tag: "timing" },
414072
- `new block ts: ${block?.timestamp}`
414073
- );
414074
- } catch {
414075
- }
414076
- }
414077
- );
414078
- const automineInterval = parseInt(automineIntervalS, 10);
414079
- const automine = await anvil.getAutomine();
414080
- await anvil.setBlockTimestampInterval({ interval: automineInterval });
414081
- log_default.debug(
414082
- `setting block timestamp interval, automine: ${automine}, interval ${automineInterval}`
414083
- );
414084
414071
  const borrowerKey = generatePrivateKey();
414085
414072
  const borrower = privateKeyToAccount(borrowerKey);
414086
414073
  await anvil.setBalance({
@@ -414255,7 +414242,7 @@ function getRenderer(opts) {
414255
414242
  var package_default = {
414256
414243
  name: "@gearbox-protocol/deploy-tools",
414257
414244
  description: "Gearbox deploy tools",
414258
- version: "5.11.8",
414245
+ version: "5.11.10",
414259
414246
  homepage: "https://gearbox.fi",
414260
414247
  keywords: [
414261
414248
  "gearbox"
@@ -414423,23 +414410,29 @@ function sdkExample() {
414423
414410
  sharedDir = "."
414424
414411
  } = opts;
414425
414412
  await mkdir3(path11.resolve(sharedDir, "deploy-state"), { recursive: true });
414426
- const sdkExample2 = new SDKExample(log_default);
414427
- await sdkExample2.run({
414428
- addressProvider,
414429
- addressProviderJson,
414430
- marketConfigurators: marketConfigurators ?? [],
414431
- anvilUrl,
414432
- outFile: path11.resolve(
414433
- sharedDir,
414434
- "deploy-state",
414435
- "stateAfter.human.json"
414436
- )
414437
- });
414438
- await writeFile8(
414439
- path11.resolve(sharedDir, "deploy-state", "stateAfter.json"),
414440
- json_stringify(sdkExample2.sdk.state),
414441
- "utf-8"
414442
- );
414413
+ const anvil = createAnvilClient({ transport: http(anvilUrl) });
414414
+ await anvil.setBlockTimestampInterval({ interval: 0 });
414415
+ try {
414416
+ const sdkExample2 = new SDKExample(log_default);
414417
+ await sdkExample2.run({
414418
+ addressProvider,
414419
+ addressProviderJson,
414420
+ marketConfigurators: marketConfigurators ?? [],
414421
+ anvilUrl,
414422
+ outFile: path11.resolve(
414423
+ sharedDir,
414424
+ "deploy-state",
414425
+ "stateAfter.human.json"
414426
+ )
414427
+ });
414428
+ await writeFile8(
414429
+ path11.resolve(sharedDir, "deploy-state", "stateAfter.json"),
414430
+ json_stringify(sdkExample2.sdk.state),
414431
+ "utf-8"
414432
+ );
414433
+ } finally {
414434
+ await anvil.removeBlockTimestampInterval();
414435
+ }
414443
414436
  log_default.info("done");
414444
414437
  });
414445
414438
  }
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.11.8",
4
+ "version": "5.11.10",
5
5
  "homepage": "https://gearbox.fi",
6
6
  "keywords": [
7
7
  "gearbox"