diff --git a/beacon_chain/spec/datatypes/base.nim b/beacon_chain/spec/datatypes/base.nim index 064501772..b3d4e2467 100644 --- a/beacon_chain/spec/datatypes/base.nim +++ b/beacon_chain/spec/datatypes/base.nim @@ -1029,9 +1029,6 @@ func checkForkConsistency*(cfg: RuntimeConfig) = # won't be hit. const denebImplementationMissing* = false -#template debugRaiseAssert*(x: string) = raiseAssert x -template debugRaiseAssert*(x: string) = discard - func ofLen*[T, N](ListType: type List[T, N], n: int): ListType = if n < N: distinctBase(result).setLen(n) diff --git a/beacon_chain/validator_client/api.nim b/beacon_chain/validator_client/api.nim index f3055ea9e..d30854a93 100644 --- a/beacon_chain/validator_client/api.nim +++ b/beacon_chain/validator_client/api.nim @@ -648,8 +648,8 @@ template firstSuccessSequential*( if not(bodyFut.finished()): await bodyFut.cancelAndWait() raise exc - except CatchableError as exc: - # This case could not be happened. + except CatchableError: + # This case should not happen. ApiOperation.Failure else: try: @@ -668,7 +668,7 @@ template firstSuccessSequential*( pending.add(timerFut.cancelAndWait()) await noCancel allFutures(pending) raise exc - except CatchableError as exc: + except CatchableError: # This case should not happen. ApiOperation.Failure @@ -2344,11 +2344,7 @@ proc publishBlindedBlock*( of ConsensusFork.Capella: publishBlindedBlock(it, data.capellaData) of ConsensusFork.Deneb: - debugRaiseAssert $denebImplementationMissing & - ": validator_client/api.nim:publishBlindedBlock (1)" - let f = newFuture[RestPlainResponse]("") - f.fail(new RestError) - f + publishBlindedBlock(it, data.denebData) do: if apiResponse.isErr(): handleCommunicationError() @@ -2393,11 +2389,7 @@ proc publishBlindedBlock*( of ConsensusFork.Capella: publishBlindedBlock(it, data.capellaData) of ConsensusFork.Deneb: - debugRaiseAssert $denebImplementationMissing & - ": validator_client/api.nim:publishBlindedBlock (2)" - let f = newFuture[RestPlainResponse]("") - f.fail(new RestError) - f + publishBlindedBlock(it, data.denebData) do: if apiResponse.isErr(): handleCommunicationError()