Skip to content

Commit

Permalink
save
Browse files Browse the repository at this point in the history
  • Loading branch information
Giulio2002 committed May 5, 2024
1 parent 49e0171 commit 8e052bd
Show file tree
Hide file tree
Showing 4 changed files with 0 additions and 7 deletions.
2 changes: 0 additions & 2 deletions turbo/execution/eth1/block_building.go
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,6 @@ func (e *EthereumExecutionModule) evictOldBuilders() {
// Missing: NewPayload, AssembleBlock
func (e *EthereumExecutionModule) AssembleBlock(ctx context.Context, req *execution.AssembleBlockRequest) (*execution.AssembleBlockResponse, error) {
if !e.semaphore.TryAcquire(1) {
e.logger.Warn("ethereumExecutionModule.AssembleBlock: ExecutionStatus_Busy")
return &execution.AssembleBlockResponse{
Id: 0,
Busy: true,
Expand Down Expand Up @@ -109,7 +108,6 @@ func blockValue(br *types.BlockWithReceipts, baseFee *uint256.Int) *uint256.Int

func (e *EthereumExecutionModule) GetAssembledBlock(ctx context.Context, req *execution.GetAssembledBlockRequest) (*execution.GetAssembledBlockResponse, error) {
if !e.semaphore.TryAcquire(1) {
e.logger.Warn("ethereumExecutionModule.GetAssembledBlock: ExecutionStatus_Busy")
return &execution.GetAssembledBlockResponse{
Busy: true,
}, nil
Expand Down
3 changes: 0 additions & 3 deletions turbo/execution/eth1/ethereum_execution.go
Original file line number Diff line number Diff line change
Expand Up @@ -151,7 +151,6 @@ func (e *EthereumExecutionModule) canonicalHash(ctx context.Context, tx kv.Tx, b

func (e *EthereumExecutionModule) ValidateChain(ctx context.Context, req *execution.ValidationRequest) (*execution.ValidationReceipt, error) {
if !e.semaphore.TryAcquire(1) {
e.logger.Warn("ethereumExecutionModule.ValidateChain: ExecutionStatus_Busy")
return &execution.ValidationReceipt{
LatestValidHash: gointerfaces.ConvertHashToH256(libcommon.Hash{}),
ValidationStatus: execution.ExecutionStatus_Busy,
Expand Down Expand Up @@ -212,7 +211,6 @@ func (e *EthereumExecutionModule) ValidateChain(ctx context.Context, req *execut
}
}
if isInvalidChain {
e.logger.Warn("ethereumExecutionModule.ValidateChain: chain is invalid", "hash", libcommon.Hash(blockHash))
validationStatus = execution.ExecutionStatus_BadBlock
}
validationReceipt := &execution.ValidationReceipt{
Expand Down Expand Up @@ -269,7 +267,6 @@ func (e *EthereumExecutionModule) Start(ctx context.Context) {

func (e *EthereumExecutionModule) Ready(context.Context, *emptypb.Empty) (*execution.ReadyResponse, error) {
if !e.semaphore.TryAcquire(1) {
e.logger.Warn("ethereumExecutionModule.Ready: ExecutionStatus_Busy")
return &execution.ReadyResponse{Ready: false}, nil
}
defer e.semaphore.Release(1)
Expand Down
1 change: 0 additions & 1 deletion turbo/execution/eth1/forkchoice.go
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,6 @@ func writeForkChoiceHashes(tx kv.RwTx, blockHash, safeHash, finalizedHash libcom

func (e *EthereumExecutionModule) updateForkChoice(ctx context.Context, blockHash, safeHash, finalizedHash libcommon.Hash, outcomeCh chan forkchoiceOutcome) {
if !e.semaphore.TryAcquire(1) {
e.logger.Warn("ethereumExecutionModule.updateForkChoice: ExecutionStatus_Busy")
sendForkchoiceReceiptWithoutWaiting(outcomeCh, &execution.ForkChoiceReceipt{
LatestValidHash: gointerfaces.ConvertHashToH256(libcommon.Hash{}),
Status: execution.ExecutionStatus_Busy,
Expand Down
1 change: 0 additions & 1 deletion turbo/execution/eth1/inserters.go
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,6 @@ func (s *EthereumExecutionModule) validatePayloadBlobs(expectedBlobHashes []libc

func (e *EthereumExecutionModule) InsertBlocks(ctx context.Context, req *execution.InsertBlocksRequest) (*execution.InsertionResult, error) {
if !e.semaphore.TryAcquire(1) {
e.logger.Warn("ethereumExecutionModule.InsertBlocks: ExecutionStatus_Busy")
return &execution.InsertionResult{
Result: execution.ExecutionStatus_Busy,
}, nil
Expand Down

0 comments on commit 8e052bd

Please sign in to comment.