Skip to content

Commit

Permalink
rename miner->coinbase in client schema and zeroed extra_data in Gene…
Browse files Browse the repository at this point in the history
…sisGenerator (Consensys#4346)
  • Loading branch information
tbenr committed Sep 27, 2021
1 parent 0b2e0d6 commit 095315c
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 9 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,7 @@ public void updateCandidateState(
UInt64.ZERO,
UInt64.ZERO,
UInt64.ZERO,
Bytes.wrap(new byte[SpecConfig.MAX_EXTRA_DATA_BYTES]),
Bytes.EMPTY,
Bytes32.ZERO,
Bytes32.ZERO,
Bytes32.ZERO)));
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ public class ExecutionPayload {

@JsonSerialize(using = Bytes20Serializer.class)
@JsonDeserialize(using = Bytes20Deserializer.class)
public final Bytes20 miner;
public final Bytes20 coinbase;

@JsonSerialize(using = BytesSerializer.class)
@JsonDeserialize(using = Bytes32Deserializer.class)
Expand Down Expand Up @@ -96,7 +96,7 @@ public class ExecutionPayload {
public ExecutionPayload(
tech.pegasys.teku.spec.datastructures.execution.ExecutionPayload executionPayload) {
this.parentHash = executionPayload.getParent_hash();
this.miner = executionPayload.getCoinbase();
this.coinbase = executionPayload.getCoinbase();
this.stateRoot = executionPayload.getState_root();
this.receiptsRoot = executionPayload.getReceipt_root();
this.logsBloom = executionPayload.getLogs_bloom();
Expand All @@ -117,7 +117,7 @@ public ExecutionPayload(

public ExecutionPayload(
@JsonProperty("parentHash") Bytes32 parentHash,
@JsonProperty("miner") Bytes20 miner,
@JsonProperty("coinbase") Bytes20 coinbase,
@JsonProperty("stateRoot") Bytes32 stateRoot,
@JsonProperty("receiptRoot") Bytes32 receiptsRoot,
@JsonProperty("logsBloom") Bytes logsBloom,
Expand All @@ -131,7 +131,7 @@ public ExecutionPayload(
@JsonProperty("blockHash") Bytes32 blockHash,
@JsonProperty("transactions") List<Bytes> transactions) {
this.parentHash = parentHash;
this.miner = miner;
this.coinbase = coinbase;
this.stateRoot = stateRoot;
this.receiptsRoot = receiptsRoot;
this.logsBloom = logsBloom;
Expand All @@ -150,7 +150,7 @@ public ExecutionPayload(
asInternalExecutionPayload() {
return new tech.pegasys.teku.spec.datastructures.execution.ExecutionPayload(
parentHash,
miner,
coinbase,
stateRoot,
receiptsRoot,
logsBloom,
Expand All @@ -175,7 +175,7 @@ public boolean equals(final Object o) {
}
final ExecutionPayload that = (ExecutionPayload) o;
return Objects.equals(parentHash, that.parentHash)
&& Objects.equals(miner, that.miner)
&& Objects.equals(coinbase, that.coinbase)
&& Objects.equals(stateRoot, that.stateRoot)
&& Objects.equals(receiptsRoot, that.receiptsRoot)
&& Objects.equals(logsBloom, that.logsBloom)
Expand All @@ -193,7 +193,7 @@ public boolean equals(final Object o) {
public int hashCode() {
return Objects.hash(
parentHash,
miner,
coinbase,
stateRoot,
receiptsRoot,
logsBloom,
Expand All @@ -211,7 +211,7 @@ public int hashCode() {
public String toString() {
return MoreObjects.toStringHelper(this)
.add("parentHash", parentHash)
.add("miner", miner)
.add("coinbase", coinbase)
.add("stateRoot", stateRoot)
.add("receiptsRoot", receiptsRoot)
.add("logsBloom", logsBloom)
Expand Down

0 comments on commit 095315c

Please sign in to comment.