@graphprotocol/graph-cli 0.90.0-alpha-20241127142903-f137c43 → 0.90.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.
package/CHANGELOG.md CHANGED
@@ -1,6 +1,6 @@
1
1
  # @graphprotocol/graph-cli
2
2
 
3
- ## 0.90.0-alpha-20241127142903-f137c43
3
+ ## 0.90.0
4
4
 
5
5
  ### Minor Changes
6
6
 
@@ -10,10 +10,15 @@
10
10
 
11
11
  ### Patch Changes
12
12
 
13
- - [#1772](https://github.com/graphprotocol/graph-tooling/pull/1772)
14
- [`f922c8e`](https://github.com/graphprotocol/graph-tooling/commit/f922c8e05d037d521b86e194e54ee086dc9793ee)
15
- Thanks [@alinobrasil](https://github.com/alinobrasil)! - Add new chains: `abstract-testnet`,
16
- `corn` and `corn-testnet`
13
+ - [#1771](https://github.com/graphprotocol/graph-tooling/pull/1771)
14
+ [`93271b0`](https://github.com/graphprotocol/graph-tooling/commit/93271b07116752c74419720a39c1fdbd460c078d)
15
+ Thanks [@0237h](https://github.com/0237h)! - Support parsing full path contract name from block
16
+ explorers
17
+
18
+ - [#1774](https://github.com/graphprotocol/graph-tooling/pull/1774)
19
+ [`5d9f0c9`](https://github.com/graphprotocol/graph-tooling/commit/5d9f0c9c9d714d95ed455deb02137ea5440f3e2d)
20
+ Thanks [@0237h](https://github.com/0237h)! - Add new chains: `abstract-testnet`, `corn` and
21
+ `corn-testnet`
17
22
 
18
23
  - [#1767](https://github.com/graphprotocol/graph-tooling/pull/1767)
19
24
  [`6f2cb45`](https://github.com/graphprotocol/graph-tooling/commit/6f2cb45e5a07d8de2946a485763feb0b1bcfd4f0)
@@ -94,7 +94,11 @@ exports.fetchSourceCodeFromEtherscan = fetchSourceCodeFromEtherscan;
94
94
  const getContractNameForAddress = async (network, address) => {
95
95
  try {
96
96
  const contractSourceCode = await (0, exports.fetchSourceCodeFromEtherscan)(network, address);
97
- const contractName = contractSourceCode.result[0].ContractName;
97
+ let contractName = contractSourceCode.result[0].ContractName;
98
+ // Some explorers will return the full path of the contract instead of just the name
99
+ // Example: contracts/SyncSwapRouter.sol:SyncSwapRouter
100
+ if (contractName.includes(':'))
101
+ contractName = contractName.substring(contractName.lastIndexOf(':') + 1);
98
102
  logger('Successfully getContractNameForAddress. contractName: %s', contractName);
99
103
  return contractName;
100
104
  }
@@ -1,5 +1,5 @@
1
1
  {
2
- "version": "0.90.0-alpha-20241127142903-f137c43",
2
+ "version": "0.90.0",
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.90.0-alpha-20241127142903-f137c43",
3
+ "version": "0.90.0",
4
4
  "description": "CLI for building for and deploying to The Graph",
5
5
  "license": "(Apache-2.0 OR MIT)",
6
6
  "engines": {