Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merge main into 23.1.x release branch to prep for 23.1.1 release #5155

Merged
merged 40 commits into from
Mar 3, 2023
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
40 commits
Select commit Hold shift + click to select a range
fd90643
Prepare for version 23.1.1-SNAPSHOT (#5067)
siladu Feb 8, 2023
05bf6ab
Add getPayloadBodiesByRangeV1 and getPayloadBodiesByHash engine metho…
gfukushima Feb 9, 2023
d7afa41
Revert "Keep Worldstate Storage open for Bonsai archive latest layer …
siladu Feb 9, 2023
b2d378e
Support post merge forks at genesis for hive tests (#5019)
jframe Feb 9, 2023
01b16bd
Fix manifest docker not skipping interim builds for RCs (#5068)
jframe Feb 9, 2023
21312b1
Fix PoS checkpoint validation (#5081)
gfukushima Feb 10, 2023
56ae1fc
moves check for init code length before balance check (#5077)
jflo Feb 10, 2023
3151c60
Fix Layered World State issue (#5076)
ahamlat Feb 13, 2023
5452159
Add shanghaiTime to sepolia (#5088)
siladu Feb 14, 2023
97edc67
If a PoS block creation repetition takes less than a configurable dur…
fab-10 Feb 14, 2023
7b81ff0
Allow dashes in ethstats password (#5090)
siladu Feb 14, 2023
08e2f87
reintroduce checking of block height for certain tasks when we are no…
pinges Feb 15, 2023
c4b4598
Allow other users to read the /opt/besu dir when using docker (#5092)
skylenet Feb 15, 2023
bff05d8
Only use MAINNET version of KZG (#5095)
fab-10 Feb 15, 2023
c750163
add more context to exception messages and debug logging (#5066)
macfarla Feb 16, 2023
51956b7
Fix block value calculation (#5100)
gfukushima Feb 16, 2023
ac23d31
re-default global max rpc batch size to 1k (#5104)
garyschulte Feb 17, 2023
ab576d6
Update to Java 17 (#5110)
ryjones Feb 18, 2023
bac7ade
bump to 1024 (#5108) (#5114)
siladu Feb 20, 2023
53b4afc
Initialize KZG native lib at startup if Cancun is enabled (#5084)
fab-10 Feb 20, 2023
17455d6
trigger auto heal in case of bad code (#5103)
matkt Feb 20, 2023
11a4f73
[MINOR] text edits to plugins javadoc (#5115)
macfarla Feb 21, 2023
532797f
Add needed tooling support for execution-spec-tests (#5030)
shemnon Feb 21, 2023
32583f4
Fix error output in standard trace (#5118)
shemnon Feb 21, 2023
66521cb
Stop adding bad proposed block to bad block manager (#5082)
gfukushima Feb 22, 2023
143f59c
Match FullSync no target message with SnapSync no target message (#5119)
Gabriel-Trintinalia Feb 22, 2023
28d5702
In forkchoiceUpdated, log VALID instead of INVALID when ignoring upda…
siladu Feb 22, 2023
28f2bd4
Gas accounting for EIP-4844 (#4992)
fab-10 Feb 23, 2023
ea6ac5e
Decode long instead of parseLong (#5135)
shemnon Feb 24, 2023
5a7c639
Mode specific handling of BLOCKHASH in evmtool (#5126)
shemnon Feb 24, 2023
b850aa7
Fix transaction selection result regression (#5133)
fab-10 Feb 25, 2023
66c757d
Update SLF4J version (#4587)
diega Feb 28, 2023
6a14d72
Withdrawals engine API ATs (#5141)
jframe Mar 1, 2023
b0daf14
Add Withdrawls execution tests to reference test (#5143)
usmansaleem Mar 1, 2023
81e7d5d
Add slf4j api so that acceptance tests work with using acctests.runBe…
siladu Mar 2, 2023
19eef23
Fix issues with RLPExceptions (#5140)
Gabriel-Trintinalia Mar 3, 2023
bf01981
Replace getByBlockNumber by getByBlockHeader (#5127)
gfukushima Mar 3, 2023
d04d35b
eth_getBlockByNumber and eth_getBlockByHash Shanghai Acceptance Test …
siladu Mar 3, 2023
d48403d
Schedule Goerli shanghaiTime and configure forkId for tests (#5151)
siladu Mar 3, 2023
36eceed
Merge remote-tracking branch 'origin/main' into 23.1.1-prep
garyschulte Mar 3, 2023
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
add more context to exception messages and debug logging (#5066)
Signed-off-by: Sally MacFarlane <macfarla.github@gmail.com>
  • Loading branch information
macfarla authored Feb 16, 2023
commit c75016324bdf09e508d4a830f23141c3787b4243
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,12 @@ public void shouldFailToSendToToStrictNodeWithoutChainId() {
strictNode.verify(eth.expectEthSendRawTransactionException(rawTx, "ChainId is required"));
}

@Test
public void shouldFailToSendWithInvalidRlp() {
final String invalidRawTx = "0x5555";
strictNode.verify(eth.expectEthSendRawTransactionException(invalidRawTx, "Invalid params"));
}

@Test
public void shouldSendSuccessfullyWithChainId_lenientNode() {
final TransferTransaction tx = createTransactionWithChainId();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@
import org.hyperledger.besu.ethereum.api.jsonrpc.JsonRpcErrorConverter;
import org.hyperledger.besu.ethereum.api.jsonrpc.RpcMethod;
import org.hyperledger.besu.ethereum.api.jsonrpc.internal.JsonRpcRequestContext;
import org.hyperledger.besu.ethereum.api.jsonrpc.internal.exception.InvalidJsonRpcRequestException;
import org.hyperledger.besu.ethereum.api.jsonrpc.internal.response.JsonRpcError;
import org.hyperledger.besu.ethereum.api.jsonrpc.internal.response.JsonRpcErrorResponse;
import org.hyperledger.besu.ethereum.api.jsonrpc.internal.response.JsonRpcResponse;
Expand Down Expand Up @@ -68,13 +69,21 @@ public JsonRpcResponse response(final JsonRpcRequestContext requestContext) {
final Transaction transaction;
try {
transaction = DomainObjectDecodeUtils.decodeRawTransaction(rawTransaction);
} catch (final RLPException | IllegalArgumentException e) {
LOG.trace("Received local transaction {}", transaction);
} catch (final RLPException e) {
LOG.debug("RLPException: {} caused by {}", e.getMessage(), e.getCause());
return new JsonRpcErrorResponse(
requestContext.getRequest().getId(), JsonRpcError.INVALID_PARAMS);
} catch (final InvalidJsonRpcRequestException i) {
LOG.debug("InvalidJsonRpcRequestException: {} caused by {}", i.getMessage(), i.getCause());
return new JsonRpcErrorResponse(
requestContext.getRequest().getId(), JsonRpcError.INVALID_PARAMS);
} catch (final IllegalArgumentException ill) {
LOG.debug("IllegalArgumentException: {} caused by {}", ill.getMessage(), ill.getCause());
return new JsonRpcErrorResponse(
requestContext.getRequest().getId(), JsonRpcError.INVALID_PARAMS);
}

LOG.trace("Received local transaction {}", transaction);

final ValidationResult<TransactionInvalidReason> validationResult =
transactionPool.get().addLocalTransaction(transaction);
return validationResult.either(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,8 +30,10 @@ public static Transaction decodeRawTransaction(final String rawTransaction)
Bytes txnBytes = Bytes.fromHexString(rawTransaction);
final boolean isGoQuorumCompatibilityMode = GoQuorumOptions.getGoQuorumCompatibilityMode();
return TransactionDecoder.decodeOpaqueBytes(txnBytes, isGoQuorumCompatibilityMode);
} catch (final IllegalArgumentException | RLPException e) {
} catch (final IllegalArgumentException e) {
throw new InvalidJsonRpcRequestException("Invalid raw transaction hex", e);
} catch (final RLPException r) {
throw new InvalidJsonRpcRequestException("Invalid RLP in raw transaction hex", r);
}
}
}