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 master into feature/block-streaming #2004

Merged
merged 102 commits into from
May 19, 2022

Conversation

remoun
Copy link
Contributor

@remoun remoun commented May 19, 2022

Update feature branch with latest mainline.

cbeck88 and others added 30 commits April 22, 2022 12:56
Bumps [anyhow](https://github.com/dtolnay/anyhow) from 1.0.56 to 1.0.57.
- [Release notes](https://github.com/dtolnay/anyhow/releases)
- [Commits](dtolnay/anyhow@1.0.56...1.0.57)

---
updated-dependencies:
- dependency-name: anyhow
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <[email protected]>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Bumps [cbindgen](https://github.com/eqrion/cbindgen) from 0.22.0 to 0.23.0.
- [Release notes](https://github.com/eqrion/cbindgen/releases)
- [Changelog](https://github.com/eqrion/cbindgen/blob/master/CHANGES)
- [Commits](mozilla/cbindgen@v0.22.0...v0.23.0)

---
updated-dependencies:
- dependency-name: cbindgen
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <[email protected]>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Soundtrack of this PR: [Orlann Divo - Onde Anda O Meu Amor](https://youtu.be/fe-PXWEbCGg)

### Motivation

Function parameter types do not match definition.

### In this PR
* update to be correct.
* Adding chris's slip10 changes

* mnemonics replacing slip10

* fix clippy

* Removing slip10 where inappropriate

* Addressing review comments

* Update mobilecoind/api/proto/mobilecoind_api.proto

Co-authored-by: Remoun Metyas <[email protected]>

* Update util/keyfile/src/bin/main.rs

Co-authored-by: Remoun Metyas <[email protected]>

* Updating conformance and local network tests to pass report id

* linting

* Changing fog report id to empty string in conformace and local network tests

* Adding back readme

* Escaping the empty string in fog conformance test

* Adding missing account index

* lint

* Update fog/sample-paykit/proto/remote_wallet.proto

Co-authored-by: James Cape <[email protected]>

* Update util/keyfile/src/mnemonic_acct.rs

Co-authored-by: James Cape <[email protected]>

* Update util/keyfile/src/error.rs

Co-authored-by: James Cape <[email protected]>

* Fixing prost

* Update util/keyfile/src/bin/keygen_main.rs

Co-authored-by: Remoun Metyas <[email protected]>

* Update util/keyfile/src/bin/main.rs

Co-authored-by: Remoun Metyas <[email protected]>

* Update util/keyfile/src/bin/keygen_main.rs

Co-authored-by: Remoun Metyas <[email protected]>

* Update util/keyfile/src/bin/main.rs

Co-authored-by: Remoun Metyas <[email protected]>

* removing structopt from merge

* clean up

* fixing previous

* addressing review comments

* importing read and write directly instead of using prelude

* Resolving lint

Co-authored-by: Remoun Metyas <[email protected]>
Co-authored-by: James Cape <[email protected]>
* Add android bindings for recoverable transaction history

* Create android bindings for RTH

* Format files

* Fixing Memo Size in Test

* Add Block Version to TransactionBuilder

* Fix One-time Private Key Generation to Use Correct Subaddress

* Review Action Items

Removing some debug logs and unused imports

* Updating Android Bindings Dependencies

* Removing old comment

* Fixing bad merge

* Updating Cargo.lock

* Removing comments

* Removing unused binding

* Updating Cargo.lock

* Updating Cargo.lock

* Removing unnecessary log

* Removing redundant test

* Cleaning up unneeded dependencies

* Cargo lock updates

* Updating android-bindings dependencies

* Lint

* Lint

* Lint

Co-authored-by: Sam <[email protected]>
Bumps [clap](https://github.com/clap-rs/clap) from 3.1.10 to 3.1.12.
- [Release notes](https://github.com/clap-rs/clap/releases)
- [Changelog](https://github.com/clap-rs/clap/blob/master/CHANGELOG.md)
- [Commits](clap-rs/clap@v3.1.10...v3.1.12)

---
updated-dependencies:
- dependency-name: clap
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <[email protected]>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
* add workflow-dispatch placeholdes so we can run on other non-default branches

* add delete dispatch
* initial work on consensus config api endpoint

* add governors signature to config

* expose more configuration params

* minor edits

* try and fix go build

* Update consensus/api/proto/consensus_config.proto

Co-authored-by: Remoun Metyas <[email protected]>

* Update consensus/api/src/conversions.rs

Co-authored-by: Remoun Metyas <[email protected]>

Co-authored-by: Remoun Metyas <[email protected]>
* allow transactions with "mixed" token types

these are introduced at block version 3

the token type of every pseudo output and real output must be
listed in `pseudo_output_token_ids` and `output_token_ids` in the
`SignatureRctBulletproofs` object

* Update mobilecoind-json/src/data_types.rs

Co-authored-by: Remoun Metyas <[email protected]>

* Update mobilecoind-json/src/data_types.rs

Co-authored-by: Remoun Metyas <[email protected]>

* Update mobilecoind-json/src/data_types.rs

Co-authored-by: Remoun Metyas <[email protected]>

* cargo fmt

* fix mobilecoind-json conversions

* review comments

* fixups

* add more test coverage on mixed transactions

* add transaction builder support for mixed transactions, and tests

* fix the world

* don't, at this time, make mobilecoind start writing 0 value change

this should happen at the time of adding RTH support to mobilecoind

* eran comments

* Update transaction/core/src/ring_signature/error.rs

Co-authored-by: Remoun Metyas <[email protected]>

* more review comments

* Make a wrapper for u64 which serializes to json as string

this addresses review comments

* missing copyright

* more review comments

* more uses of `Amount::new`

* cleanup in transaction builder around Amount

* cleanup tx prefix around Amount

* cleanup input secret and output secret around Amount

* Update transaction/core/src/ring_signature/rct_bulletproofs.rs

Co-authored-by: Remoun Metyas <[email protected]>

* Update transaction/std/src/memo_builder/rth_memo_builder.rs

Co-authored-by: Remoun Metyas <[email protected]>

* Update transaction/std/src/transaction_builder.rs

Co-authored-by: Remoun Metyas <[email protected]>

* Update transaction/std/src/transaction_builder.rs

Co-authored-by: Remoun Metyas <[email protected]>

* Update transaction/std/src/transaction_builder.rs

Co-authored-by: Remoun Metyas <[email protected]>

* Update transaction/std/src/transaction_builder.rs

Co-authored-by: Remoun Metyas <[email protected]>

* Update transaction/std/src/transaction_builder.rs

Co-authored-by: Remoun Metyas <[email protected]>

* Update transaction/std/src/transaction_builder.rs

Co-authored-by: Remoun Metyas <[email protected]>

* Update consensus/service/src/validators.rs

Co-authored-by: Remoun Metyas <[email protected]>

* fix build

* JsonTokenId -> JsonU64, and code shortening in lots of places

* more JsonU64

* Update transaction/core/src/ring_signature/generator_cache.rs

Co-authored-by: Remoun Metyas <[email protected]>

* replace assert with error

* Make `TransactionBuilder::new(` take the fee `Amount`

this cleans up the constructor

* fix build

* fix clippy

* replace assert with error in another place

* fix a variable name, per review comments

* add a code comment about balance proofing after this mixed transactions stuff

* fixup code comment

* Update transaction/core/src/blockchain/block_version.rs

Co-authored-by: sugargoat <[email protected]>

* Update transaction/core/src/ring_signature/rct_bulletproofs.rs

Co-authored-by: sugargoat <[email protected]>

* Update transaction/std/src/transaction_builder.rs

Co-authored-by: sugargoat <[email protected]>

* Update transaction/std/src/transaction_builder.rs

Co-authored-by: sugargoat <[email protected]>

* Update transaction/std/src/transaction_builder.rs

Co-authored-by: sugargoat <[email protected]>

* Update transaction/core/src/tx_error.rs

Co-authored-by: sugargoat <[email protected]>

* Update transaction/core/src/ring_signature/rct_bulletproofs.rs

Co-authored-by: sugargoat <[email protected]>

* improve code comment

* add code comments in external.proto

* add github issue references in sources

* cargo format of code comments

Co-authored-by: Remoun Metyas <[email protected]>
Co-authored-by: sugargoat <[email protected]>
Add ability to create simulated blocks with custom content for benchmark tests
…1875)

* move validation tests to be an integration test, remove adapt_hack

This works because, when cargo compiles in-line unit tests, they are
compiled into the module of the code under test, but when cargo
compiles integration tests (in tests directory), that is considered
a separate module (effectively a separate crate, just without its
own cargo toml).

This fixes the adapt hack issue because now we no longer need to
compile the `mc-transaction-core` crate in test mode, which also
references the `mc-transaction-core` crate which `mc-ledger-db`
depends on. The types in the test code always refer to the types
in the same version of `mc-transaction-core` that `mc-ledger-db`
is using.

* address eran comments
* burn redemption memo type and builder

* another test

* misc fixes

* update comment

* Update transaction/std/src/memo_builder/burn_redemption_memo_builder.rs

Co-authored-by: Mike Turner <[email protected]>

* fmt

* use const

* Update transaction/std/src/memo_builder/burn_redemption_memo_builder.rs

Co-authored-by: Nick Santana <[email protected]>

* pr review fixes

* merge fixes

* lint

* remove address from InvalidRecipient

* review fixes

Co-authored-by: Mike Turner <[email protected]>
Co-authored-by: Nick Santana <[email protected]>
* Add --all-targets to clippy command in tools/lint.sh
* Fix clippy findings.
Set Change Subaddress Index to u64::MAX - 1
* add and impl generate_burn_redemption_tx

* add tests

* support destination memos

* fmt

* Update mobilecoind/src/service.rs

Co-authored-by: Remoun Metyas <[email protected]>

* Update mobilecoind/src/service.rs

Co-authored-by: Remoun Metyas <[email protected]>

* Update mobilecoind/api/proto/mobilecoind_api.proto

Co-authored-by: Nick Santana <[email protected]>

* change test to exercise off by one scenario

Co-authored-by: Remoun Metyas <[email protected]>
Co-authored-by: Nick Santana <[email protected]>
* Update rust-toolchain version
* Fix clippy warnings
* Write an integration test for mobilecoind-json

* sort

* enable test

* spaces

* move wait_for_monitor_to_sync down

* DRY

* Update mobilecoind/strategies/test_client.py

Co-authored-by: Remoun Metyas <[email protected]>

* Update mobilecoind/strategies/drain-accounts.py

Co-authored-by: Remoun Metyas <[email protected]>

Co-authored-by: Remoun Metyas <[email protected]>
* Adding a default value for fog_report_id and adding info level logging

* lint

* Fix bug calling wrong method in accounts.py

* Changing check in sample_keys_main to just be a clap default

* Changing option to string reference
Bumps [libc](https://github.com/rust-lang/libc) from 0.2.124 to 0.2.125.
- [Release notes](https://github.com/rust-lang/libc/releases)
- [Commits](rust-lang/libc@0.2.124...0.2.125)

---
updated-dependencies:
- dependency-name: libc
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <[email protected]>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Bumps [syn](https://github.com/dtolnay/syn) from 1.0.91 to 1.0.92.
- [Release notes](https://github.com/dtolnay/syn/releases)
- [Commits](dtolnay/syn@1.0.91...1.0.92)

---
updated-dependencies:
- dependency-name: syn
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <[email protected]>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
)

Bumps [serde](https://github.com/serde-rs/serde) from 1.0.136 to 1.0.137.
- [Release notes](https://github.com/serde-rs/serde/releases)
- [Commits](serde-rs/serde@v1.0.136...v1.0.137)

---
updated-dependencies:
- dependency-name: serde
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <[email protected]>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Bumps [serde](https://github.com/serde-rs/serde) from 1.0.136 to 1.0.137.
- [Release notes](https://github.com/serde-rs/serde/releases)
- [Commits](serde-rs/serde@v1.0.136...v1.0.137)

---
updated-dependencies:
- dependency-name: serde
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <[email protected]>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Bumps [serde](https://github.com/serde-rs/serde) from 1.0.136 to 1.0.137.
- [Release notes](https://github.com/serde-rs/serde/releases)
- [Commits](serde-rs/serde@v1.0.136...v1.0.137)

---
updated-dependencies:
- dependency-name: serde
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <[email protected]>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
)

Bumps [serde](https://github.com/serde-rs/serde) from 1.0.136 to 1.0.137.
- [Release notes](https://github.com/serde-rs/serde/releases)
- [Commits](serde-rs/serde@v1.0.136...v1.0.137)

---
updated-dependencies:
- dependency-name: serde
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <[email protected]>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
dependabot bot and others added 22 commits May 16, 2022 11:20
Bumps [syn](https://github.com/dtolnay/syn) from 1.0.93 to 1.0.94.
- [Release notes](https://github.com/dtolnay/syn/releases)
- [Commits](dtolnay/syn@1.0.93...1.0.94)

---
updated-dependencies:
- dependency-name: syn
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <[email protected]>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Bumps [mockall](https://github.com/asomers/mockall) from 0.11.0 to 0.11.1.
- [Release notes](https://github.com/asomers/mockall/releases)
- [Changelog](https://github.com/asomers/mockall/blob/master/CHANGELOG.md)
- [Commits](asomers/mockall@v0.11.0...v0.11.1)

---
updated-dependencies:
- dependency-name: mockall
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <[email protected]>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
…ty (#1979)

* Make the test client exercise the signed contingent input functionality

* fix multiline displaydoc after format

* fix review comments, make SCI builder clear the proofs, fix tests

* clippy

* Update fog/test-client/src/test_client.rs

Co-authored-by: Eran Rundstein <[email protected]>

* Update fog/test-client/src/test_client.rs

Co-authored-by: Eran Rundstein <[email protected]>

* Update fog/test-client/src/test_client.rs

Co-authored-by: Eran Rundstein <[email protected]>

* Update fog/sample-paykit/src/client.rs

Co-authored-by: Remoun Metyas <[email protected]>

* Update fog/sample-paykit/src/client.rs

Co-authored-by: Remoun Metyas <[email protected]>

* Update fog/sample-paykit/src/client.rs

Co-authored-by: Remoun Metyas <[email protected]>

* fix more review comments

* fix signed contingent input builder tests (we made the builder delete merkle proofs)

* test defaults with delimiter values

* add use-value-delimiter config

* add debug logging

* fix an issue where SCI builder wasn't sorting global indices with input ring

we realized that, the `InputCredentials` actually contains all the global
indices, so we don't need to have a second source of truth for this,
the SCI builder can just get the global indices from the membership proofs
The input credentials already sorts the inputs and membership proofs
together, so this simplification also fixes the issue

* increase atomic swap amount

* fix atomic swap fee calculation thing

* fix expected balances after changes to swap amounts

* fixup RTH tests in connection to atomic swaps

* add a note about SCI expiry check being racy

Co-authored-by: Eran Rundstein <[email protected]>
Co-authored-by: Remoun Metyas <[email protected]>
Bumps [ed25519](https://github.com/RustCrypto/signatures) from 1.5.0 to 1.5.2.
- [Release notes](https://github.com/RustCrypto/signatures/releases)
- [Commits](RustCrypto/signatures@ed25519/v1.5.0...ed25519/v1.5.2)

---
updated-dependencies:
- dependency-name: ed25519
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <[email protected]>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Bumps [signal-hook](https://github.com/vorner/signal-hook) from 0.3.13 to 0.3.14.
- [Release notes](https://github.com/vorner/signal-hook/releases)
- [Changelog](https://github.com/vorner/signal-hook/blob/master/CHANGELOG.md)
- [Commits](vorner/signal-hook@v0.3.13...v0.3.14)

---
updated-dependencies:
- dependency-name: signal-hook
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <[email protected]>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Bumps [rayon](https://github.com/rayon-rs/rayon) from 1.5.2 to 1.5.3.
- [Release notes](https://github.com/rayon-rs/rayon/releases)
- [Changelog](https://github.com/rayon-rs/rayon/blob/master/RELEASES.md)
- [Commits](rayon-rs/rayon@v1.5.2...v1.5.3)

---
updated-dependencies:
- dependency-name: rayon
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <[email protected]>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Bumps [syn](https://github.com/dtolnay/syn) from 1.0.94 to 1.0.95.
- [Release notes](https://github.com/dtolnay/syn/releases)
- [Commits](dtolnay/syn@1.0.94...1.0.95)

---
updated-dependencies:
- dependency-name: syn
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <[email protected]>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Bumps [libc](https://github.com/rust-lang/libc) from 0.2.125 to 0.2.126.
- [Release notes](https://github.com/rust-lang/libc/releases)
- [Commits](rust-lang/libc@0.2.125...0.2.126)

---
updated-dependencies:
- dependency-name: libc
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <[email protected]>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
* Bump rocket from 0.5.0-rc.1 to 0.5.0-rc.2

Bumps [rocket](https://github.com/SergioBenitez/Rocket) from 0.5.0-rc.1 to 0.5.0-rc.2.
- [Release notes](https://github.com/SergioBenitez/Rocket/releases)
- [Changelog](https://github.com/SergioBenitez/Rocket/blob/master/CHANGELOG.md)
- [Commits](rwf2/Rocket@v0.5.0-rc.1...v0.5.0-rc.2)

---
updated-dependencies:
- dependency-name: rocket
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <[email protected]>

* Update for Rocket v0.5.0-rc.2

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Andrew Wygle <[email protected]>
Bumps [ed25519](https://github.com/RustCrypto/signatures) from 1.5.0 to 1.5.2.
- [Release notes](https://github.com/RustCrypto/signatures/releases)
- [Commits](RustCrypto/signatures@ed25519/v1.5.0...ed25519/v1.5.2)

---
updated-dependencies:
- dependency-name: ed25519
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <[email protected]>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Bumps [ed25519](https://github.com/RustCrypto/signatures) from 1.5.0 to 1.5.2.
- [Release notes](https://github.com/RustCrypto/signatures/releases)
- [Commits](RustCrypto/signatures@ed25519/v1.5.0...ed25519/v1.5.2)

---
updated-dependencies:
- dependency-name: ed25519
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <[email protected]>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Logging at error causes a sentry alert, and so if a client like
fog distro is in a retry loop submitting transactions and getting
this error, it can blow out our sentry quota
…#1993)

* add TxFile and dump subcommand

* add signing command
Add memo builders for creating gift code memos and simulate gift code transaction
flow within transaction builder.
…ge-master

Resolved Conflicts:
	Cargo.lock
	api/src/convert/mod.rs
	go-grpc-gateway/build.sh
	transaction/core/Cargo.toml
	transaction/core/src/lib.rs
	transaction/core/src/tx.rs
@remoun remoun self-assigned this May 19, 2022
@remoun remoun changed the base branch from master to feature/block-streaming May 19, 2022 04:41
Copy link
Contributor

@iamalwaysuncomfortable iamalwaysuncomfortable left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me. I think once code coverage is implemented, we'll have a better idea of what might not be tested and getting missed in larger rebases.

@samdealy samdealy self-requested a review May 19, 2022 20:22
@remoun remoun merged commit ba2e833 into feature/block-streaming May 19, 2022
@remoun remoun deleted the block-streaming-merge-master branch May 19, 2022 21:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.