Skip to content

Commit 56690c2

Browse files
authored
fix: verification pointlessly regenerates settings issue (#142)
1 parent 6752356 commit 56690c2

File tree

1 file changed

+7
-9
lines changed

1 file changed

+7
-9
lines changed

ape_etherscan/verify.py

Lines changed: 7 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@
3939
}
4040
_SPDX_ID_KEY = "SPDX-License-Identifier: "
4141

42-
ECOSYSTEMS_VERIFY_USING_JSON = ("ethereum",)
42+
ECOSYSTEMS_VERIFY_USING_JSON = ("arbitrum", "base", "blast", "ethereum")
4343

4444

4545
class LicenseType(Enum):
@@ -289,8 +289,6 @@ def attempt_verification(self):
289289

290290
version = str(self.compiler.version)
291291

292-
# TODO: Fix compiler output in ape-solidity
293-
# and/or add more validation to ethpm_types.Compiler
294292
compiler = self.compiler
295293
valid = True
296294
settings = {}
@@ -299,12 +297,12 @@ def attempt_verification(self):
299297
output_contracts = settings.get("outputSelection", {})
300298
for contract_id in self.compiler.contractTypes or []:
301299
parts = contract_id.split(":")
302-
if len(parts) != 2:
303-
# Bad compiler.
304-
valid = False
305-
continue
300+
if len(parts) == 2:
301+
_, cname = parts
302+
303+
else:
304+
cname = parts[0]
306305

307-
_, cname = parts
308306
if cname not in output_contracts:
309307
valid = False
310308
break
@@ -357,7 +355,7 @@ def attempt_verification(self):
357355

358356
def _get_new_settings(self, version: str) -> dict:
359357
logger.warning(
360-
"Settings missing from cached manifest. " "Attempting to re-calculate find settings."
358+
"Settings missing from cached manifest. Attempting to re-calculate to find settings."
361359
)
362360

363361
# Attempt to re-calculate settings.

0 commit comments

Comments
 (0)