Closed afck closed 5 years ago
The authority_round
test in ethcore/sync/src/tests/consensus.rs
broke in the malice reports commit: https://github.com/poanetwork/parity-ethereum/commit/ae01f9b0a2d12f1d626aa7ebc3b2d774064c5997
---- tests::consensus::authority_round stdout ----
thread 'tests::consensus::authority_round' panicked at 'assertion failed: `(left == right)`
left: `1`,
right: `2`', ethcore/sync/src/tests/consensus.rs:74:2
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace.
Does also parity-ipfs-api
fail to compile? I have
error[E0433]: failed to resolve: could not find `format_args` in `core`
--> ipfs/src/lib.rs:133:8
|
133 | _ => format!("{}:{}", interface, port),
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ could not find `format_args` in `core`
|
= note: this error originates in a macro outside of the current crate (in Nightly builds, run with -Z external-macro-backtrace for more info)
Maybe the failure in parity-ipfs-api
is a nightly glitch? I'll try a different nightly...
No, I actually fixed it. Will push in a few minutes. (If I don't hit even more errors in the meantime…)
The problem here was that something was imported as core
, which breaks the format!
macro.
I also fixed tests::consensus::authority_round
, which was my fault: Seeing that AuthorityRound::step
is only used in tests, I marked it #[cfg(test)]
. That was a mistake because:
Engine::step
has a no-op default implementation.step
in their own tests, which means cfg(test)
is false! For that purpose there's the test-helpers
feature. So I guess I should have marked fn step
in all three places (the Engine
trait, and the impls for AuthorityRound
and Clique
) as #[cfg(any(test, feature = "test-helpers))]
or something.But I'll just revert my change, and possibly suggest that upstream later.
I added some fixes, but there's still a lot to do:
v1::tests::eth::eth_get_block_by_hash
still fails.evmbin/benches
, so I disabled it for now. It looks horribly outdated.Another problem is that a dependent crate fails to compile as well - jsonrpc
. It doesn't make sense to correct old versions of other crates. Maybe those problems are fixed in the latest stable, in which case we could rebase on it?
I agree! I'll take a look at the upstream branches tomorrow, and see by how many of these bugs they are still affected, then I'll either merge this PR, or we'll rebase.
The build errors in parity-ethereum
only were fixed in paritytech/parity-ethereum#10991.
All tests pass if compiled with stable Rust 1.37.
190 applies to
aura-pos
as well, not just tohbbft
.This PR only fixes the build, but the tests still fail.