@graphprotocol/graph-cli 0.52.1-alpha-20230718210510-d7a5634 → 0.52.1-alpha-20230718212224-9d21810

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -1,6 +1,6 @@
1
1
  # @graphprotocol/graph-cli
2
2
 
3
- ## 0.52.1-alpha-20230718210510-d7a5634
3
+ ## 0.52.1-alpha-20230718212224-9d21810
4
4
 
5
5
  ### Patch Changes
6
6
 
@@ -66,20 +66,23 @@ class AddCommand extends core_1.Command {
66
66
  startBlock || (startBlock = Number(await (0, abi_1.loadStartBlockForContract)(network, address)).toString());
67
67
  }
68
68
  catch (error) {
69
- // If we can't get the start block, we'll just leave it out of the manifest
70
- const { startBlock: userInputStartBlock } = await gluegun_1.prompt.ask([
71
- {
72
- type: 'input',
73
- name: 'startBlock',
74
- message: 'Start Block',
75
- initial: '0',
76
- validate: value => parseInt(value) >= 0,
77
- result(value) {
78
- return value;
69
+ // we cannot ask user to do prompt in test environment
70
+ if (process.env.NODE_ENV !== 'test') {
71
+ // If we can't get the start block, we'll just leave it out of the manifest
72
+ const { startBlock: userInputStartBlock } = await gluegun_1.prompt.ask([
73
+ {
74
+ type: 'input',
75
+ name: 'startBlock',
76
+ message: 'Start Block',
77
+ initial: '0',
78
+ validate: value => parseInt(value) >= 0,
79
+ result(value) {
80
+ return value;
81
+ },
79
82
  },
80
- },
81
- ]);
82
- startBlock = userInputStartBlock;
83
+ ]);
84
+ startBlock = userInputStartBlock;
85
+ }
83
86
  }
84
87
  await (0, scaffold_1.writeABI)(ethabi, contractName);
85
88
  const { collisionEntities, onlyCollisions, abiData } = updateEventNamesOnCollision(ethabi, entities, contractName, mergeEntities);
@@ -1,5 +1,5 @@
1
1
  {
2
- "version": "0.52.1-alpha-20230718210510-d7a5634",
2
+ "version": "0.52.1-alpha-20230718212224-9d21810",
3
3
  "commands": {
4
4
  "add": {
5
5
  "id": "add",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@graphprotocol/graph-cli",
3
- "version": "0.52.1-alpha-20230718210510-d7a5634",
3
+ "version": "0.52.1-alpha-20230718212224-9d21810",
4
4
  "description": "CLI for building for and deploying to The Graph",
5
5
  "license": "(Apache-2.0 OR MIT)",
6
6
  "engines": {