Nethereum / Nethereum/Nethereum

Exception during contract deployment

Open
#1,082 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
C#
Stars
2.3k
Forks
744
PR merge metrics
No merged PRs in 30d

Description

We're randomly getting the following exception when calling DeployContractAndWaitForReceiptAsync
{"Contract code not deployed successfully"}
at Nethereum.RPC.TransactionReceipts.TransactionReceiptPollingService.d__13.MoveNext()
at Nethereum.RPC.TransactionReceipts.TransactionReceiptPollingService.d__12.MoveNext()
at Nethereum.Contracts.DeploymentHandlers.DeploymentTransactionReceiptPollHandler`1.d__3.MoveNext()

Note, the TransactionReceipt included in the exception does have a ContractAddress.

Occurs in our local test environment running Geth in dev mode (geth --http --http.api eth,net,web3,debug --dev --dev.period 2 --keystore --datadir )

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reproducing the failure with DeployContractAndWaitForReceiptAsync in the stated Geth dev-mode environment. Read TransactionReceiptPollingService, especially PollForContractAddressAsync and ValidateDeploymentTransactionReceipt, and compare the exception condition with the receipt's ContractAddress. Done means the intermittent deployment exception is understood and deployments with a populated ContractAddress are handled correctly.

Written by the indexing model from the issue text.

Assessment

Tech stack
csharp
Domain
backend-api-design, blockchain
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.