Jane Lusby
959f029457
make clippy warnings errors in CI ( #605 )
...
* make clippy warnings errors in CI
* Apply fixes from cargo clippy --all-features --all-targets -- -D warnings
* Resolve merge conflicts
Co-authored-by: Deirdre Connolly <deirdre@zfnd.org>
2020-07-07 16:26:22 -07:00
Alfredo Garcia
f14e577ea9
apply clippy code suggestions
2020-07-07 18:33:14 -04:00
dependabot[bot]
2a6a3ee518
Bump chrono from 0.4.12 to 0.4.13
...
Bumps [chrono](https://github.com/chronotope/chrono ) from 0.4.12 to 0.4.13.
- [Release notes](https://github.com/chronotope/chrono/releases )
- [Changelog](https://github.com/chronotope/chrono/blob/master/CHANGELOG.md )
- [Commits](https://github.com/chronotope/chrono/compare/v0.4.12...v0.4.13 )
Signed-off-by: dependabot[bot] <support@github.com>
2020-07-07 18:31:55 -04:00
Jane Lusby
270002c956
Add formal design for syncer ( #583 )
...
* Add formal design for syncer
* move away from RFC language
* Update design/0000-template.md
Co-authored-by: Dimitris Apostolou <dimitris.apostolou@icloud.com>
Co-authored-by: Dimitris Apostolou <dimitris.apostolou@icloud.com>
2020-07-07 12:54:34 -07:00
dependabot[bot]
3debe97cb2
Bump equihash from `5b2c71e` to `ae2a248`
...
Bumps [equihash](https://github.com/ZcashFoundation/librustzcash ) from `5b2c71e` to `ae2a248`.
- [Release notes](https://github.com/ZcashFoundation/librustzcash/releases )
- [Commits](5b2c71e112...ae2a248133
)
Signed-off-by: dependabot[bot] <support@github.com>
2020-07-07 12:31:09 -07:00
Henry de Valence
68f57b2577
Update ed25519-zebra to 1.0.
2020-07-07 11:49:21 -07:00
Henry de Valence
e54438f4e4
Update zebra-chain/src/block/header.rs
2020-07-07 11:13:49 -07:00
Dimitris Apostolou
ba81d7d4c0
Fix typos
2020-07-07 11:13:49 -07:00
Jane Lusby
a733580fd8
add proptests for invalid forms of input ( #550 )
...
* add proptests for invalid forms of input
* apply proptests to each valid block we have
* start moving equihash logic to BlockHeader
* provide an error based interface
* cleanup logging in dependent crate
* use is_equihash_solution_valid everywhere
* switch to proper equihash crate branch
2020-07-07 11:01:02 -07:00
Alfredo Garcia
db30e53470
Create a test for block size ( #558 )
...
* add block size limit test
* calculate max_transactions_in_block and max_inputs_in_tx
* abstract block generation
* move all test vectors to zebra-test
2020-07-07 10:37:32 +10:00
Jane Lusby
ac8185f2f3
remove patch for newly released color-eyre dependency ( #595 )
2020-07-06 13:37:11 -07:00
Alfredo Garcia
d736355f9f
Add ZIP143 and ZIP243 test vectors ( #585 )
2020-07-03 09:45:40 +10:00
Deirdre Connolly
a267030d7b
Adjust coverage job to only trigger on changes to *.rs files
...
Moves it to its own workflow. Also pulls in latest tarpaulin release every time. 🤞
2020-07-02 15:38:20 -04:00
dependabot[bot]
5ee48a6675
Bump chrono from 0.4.11 to 0.4.12 ( #580 )
...
Bumps [chrono](https://github.com/chronotope/chrono ) from 0.4.11 to 0.4.12.
- [Release notes](https://github.com/chronotope/chrono/releases )
- [Changelog](https://github.com/chronotope/chrono/blob/master/CHANGELOG.md )
- [Commits](https://github.com/chronotope/chrono/compare/v0.4.11...v0.4.12 )
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-07-02 10:33:39 -07:00
dependabot[bot]
a1d02c2606
Bump tracing-subscriber from 0.2.6 to 0.2.7
...
Bumps [tracing-subscriber](https://github.com/tokio-rs/tracing ) from 0.2.6 to 0.2.7.
- [Release notes](https://github.com/tokio-rs/tracing/releases )
- [Commits](https://github.com/tokio-rs/tracing/compare/tracing-subscriber-0.2.6...tracing-subscriber-0.2.7 )
Signed-off-by: dependabot[bot] <support@github.com>
2020-07-02 06:47:04 -04:00
dependabot[bot]
de08f66b33
Bump codecov/codecov-action from v1.0.7 to v1.0.10
...
Bumps [codecov/codecov-action](https://github.com/codecov/codecov-action ) from v1.0.7 to v1.0.10.
- [Release notes](https://github.com/codecov/codecov-action/releases )
- [Commits](https://github.com/codecov/codecov-action/compare/v1.0.7...f3570723ef743f6942b6a480461ed0cd6c0f9baa )
Signed-off-by: dependabot[bot] <support@github.com>
2020-07-02 06:44:39 -04:00
teor
c8829d8408
fix: Adjust bounds on the LockTime Arbitrary impl
...
The previous code could generate LockTime::Time with (u32::MAX + 1),
but the maximum valid value is u32::MAX due to the field size.
2020-07-02 14:30:34 +10:00
Jane Lusby
00e750654a
add nullifier types ( #568 )
...
* add nullifier types
* Apply suggestions from code review
Co-authored-by: Deirdre Connolly <deirdre@zfnd.org>
* add zcash_deserialize impls
* Add docs
Co-authored-by: Deirdre Connolly <deirdre@zfnd.org>
2020-07-01 17:57:32 -07:00
Jane Lusby
c216f5ca25
Refine type for MAC ( #577 )
2020-07-01 17:57:03 -07:00
Deirdre Connolly
7f1bc8d922
Try to make CodeCov bot comment on PRs quieter ( #576 )
...
* require_changes: true - "Comments will now only post when coverage
changes. Furthermore, if a comment already exists, and a newer commit
results in no coverage change for the entire pull, the comment will be
deleted."
* just the 'diff' view
2020-07-01 20:37:51 -04:00
Jane Lusby
8281b9040c
Start work on new Amount type ( #554 )
2020-07-01 16:31:30 -07:00
Jane Lusby
51f6ce86ff
Implement retry policy for syncer ( #551 )
2020-07-01 13:35:01 -07:00
teor
f999ec75e6
fix: Remove a non-standard unicode character in a comment
2020-07-01 16:03:14 -04:00
teor
7bace99569
fix: Update a comment with the correct parity-zcash path
2020-07-01 16:03:14 -04:00
Jane Lusby
6cbb6d4574
consolidate arbitrary impls to one file in zebra-chain ( #553 )
...
* consolidate arbitrary impls to one file in zebra-chain
* move the ones I missed
* move test-vectors
Co-authored-by: Jane Lusby <jane@zfnd.org>
2020-06-30 14:23:38 -07:00
Jane Lusby
7245d91fe9
fix block downloading to be parallelized and commited via the verifier ( #540 )
2020-06-30 09:42:09 -07:00
Jane Lusby
afd0e90a74
Implement equihash verification ( #549 )
...
This change brings in the `equihash` crate from librustzcash and uses it to add a basic `is_valid` test for `EquihashSolutions`.
Co-authored-by: Jane Lusby <jane@zfnd.org>
2020-06-26 11:21:02 -07:00
Deirdre Connolly
eff8a3889e
Revert "Sign container images for later binary authorization"
...
This reverts commit 0bb8b2b059
.
2020-06-25 17:03:07 -04:00
Deirdre Connolly
038a09ad36
Revert "Use gcloud sdk latest stable in actions; use --quiet for alpha commands"
...
This reverts commit 8367c765a0
.
2020-06-25 17:03:07 -04:00
Deirdre Connolly
839d4ab9fb
Revert "Move --quiet around"
...
This reverts commit 01e6d01d9b
.
2020-06-25 17:03:07 -04:00
Deirdre Connolly
e8ff7a1dd8
Revert "Verify that the attestation was created"
...
This reverts commit c1f97e21c9
.
2020-06-25 17:03:07 -04:00
Deirdre Connolly
c1f97e21c9
Verify that the attestation was created
2020-06-25 16:47:29 -04:00
Deirdre Connolly
01e6d01d9b
Move --quiet around
2020-06-25 16:47:29 -04:00
Deirdre Connolly
8367c765a0
Use gcloud sdk latest stable in actions; use --quiet for alpha commands
2020-06-25 16:47:29 -04:00
Deirdre Connolly
0bb8b2b059
Sign container images for later binary authorization
2020-06-25 16:47:29 -04:00
Alfredo Garcia
9cbd369a59
Refactor block module to have submodules ( #512 )
...
* create hash submodule for block
* create header submodule for block
* create serialize submodule for block
* add newline to hash.rs (fmt)
* Update zebra-chain/src/block/tests.rs
Co-authored-by: Jane Lusby <jlusby42@gmail.com>
Co-authored-by: Henry de Valence <hdevalence@hdevalence.ca>
Co-authored-by: Jane Lusby <jlusby42@gmail.com>
2020-06-25 09:18:05 -07:00
teor
a706b65325
Consensus test tweaks ( #538 )
...
* Use spandoc correctly
* Refactor consensus test error handling
* Delete a checkpoint test that will soon be obsolete
* Only initialise tracing once for the block tests
* Use tracing in the checkpoint tests
* Move BlockVerifier and tests into block.rs
* Update a BlockVerifier comment
* Tweak some TODO comments
2020-06-25 10:14:23 +10:00
Henry de Valence
21bf913b48
Revert "correctly trim and download tips ( #531 )"
...
This reverts commit e102bd5e34
.
2020-06-24 12:24:37 -07:00
Jane Lusby
e102bd5e34
correctly trim and download tips ( #531 )
...
* also download tips and filter tips
* dispatch all block downloads together
* tweek to match henry's changes
* switch to more intuitive match
Co-authored-by: Jane Lusby <jane@zfnd.org>
2020-06-24 15:19:34 -04:00
Jane Lusby
2abf4b93a8
consolidate test init functions into zebra-test ( #541 )
...
* consolidate test init logic into one place
* rustfmt
Co-authored-by: Jane Lusby <jane@zfnd.org>
2020-06-24 11:47:18 -07:00
Henry de Valence
87a8d328d5
Rewrite zebra-state tests to use transcripts.
...
This makes adding more tests easier.
2020-06-24 11:47:18 -07:00
Henry de Valence
e8d42264e8
Add a check method to the Transcript.
2020-06-24 11:47:18 -07:00
Henry de Valence
5c9cd52baf
Add a Transcript Service for testing.
2020-06-24 11:47:18 -07:00
teor
a9efb8715e
chain: Update the note about time truncation
2020-06-24 18:22:36 +10:00
teor
f40bfff7c0
consensus: Simplify error handling in a test
...
Part of #477 .
2020-06-24 18:22:36 +10:00
teor
f1ce4dcf14
consensus: Inline node_time_check() into callers
...
node_time_check() is a small function, so we inline it into its callers.
(And then rename node_time_check_helper() to node_time_check().)
Part of #477 .
2020-06-24 18:22:36 +10:00
teor
59bc8d7167
consensus: Make BlockVerifier only call AddBlock on success
...
We don't want to call the state's AddBlock until we know the block is
valid. This avoids subtle bugs if the state is modified in call().
(in_memory currently modifies the state in call(), on_disk modifies the
state in the async block.)
Part of #477 .
2020-06-24 18:22:36 +10:00
teor
8fde8c1a6b
consensus: Add tests for block node time checks
...
Part of #477 .
2020-06-24 18:22:36 +10:00
teor
a41f4f68cf
consensus: move verify::block to its own file
...
Part of #477 .
2020-06-24 18:22:36 +10:00
teor
d97c769869
consensus: Refactor the node time check for testing
...
Part of #477 .
2020-06-24 18:22:36 +10:00