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

Release/v0.1.0 #75

Merged
merged 320 commits into from
Sep 2, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
320 commits
Select commit Hold shift + click to select a range
5425615
format
RUAN0007 Aug 2, 2024
ef8b88d
update gitaction yml
cliff0412 Aug 2, 2024
36dcefc
chore:refactor-into-prover
Aug 2, 2024
7c5059d
update yml
cliff0412 Aug 2, 2024
79c925b
refactor:refactor-and-wrap-recursive-in-prover
Aug 2, 2024
749a6e9
chore:fmt
Aug 2, 2024
99acafb
update svg generation script
cliff0412 Aug 2, 2024
287fd5e
Merge pull request #26 from okx/doc/ruanpc/bench
cliff0412 Aug 2, 2024
38624bf
Merge branch 'dev' of https://github.com/okx/proof-of-reserves-v2 int…
Aug 2, 2024
ddc26d4
update action yml
cliff0412 Aug 2, 2024
2c8ad68
update action yml
cliff0412 Aug 2, 2024
6e8eb0f
chore:update bench
Aug 2, 2024
3d1fc32
add gen svg sh script
cliff0412 Aug 2, 2024
d31c60d
update yml
cliff0412 Aug 2, 2024
a008424
finsih tseting for circuit registry
RUAN0007 Aug 2, 2024
aa7d236
format
RUAN0007 Aug 2, 2024
fb7d9e8
update svg badge
cliff0412 Aug 2, 2024
28d2d35
refactor
cliff0412 Aug 2, 2024
5b7056f
Merge pull request #24 from okx/ci/cliff/workflow
cliff0412 Aug 2, 2024
e6ddb85
Merge remote-tracking branch 'origin/dev' into feature/ruanpc/precomp…
RUAN0007 Aug 2, 2024
6a949d9
chore:Add-removed-fn
Aug 5, 2024
20cdb33
refactor: log, gitignore
cliff0412 Aug 5, 2024
8187a6e
chore fix fmt
cliff0412 Aug 5, 2024
059f8b9
Merge pull request #14 from okx/feature/add-merkle-proof-circuit
cliff0412 Aug 5, 2024
29b2f2b
Merge remote-tracking branch 'origin/dev' into feature/ruanpc/precomp…
RUAN0007 Aug 5, 2024
f408ad5
add back bench
RUAN0007 Aug 5, 2024
ccd3d7d
feature:add global mst
cliff0412 Aug 5, 2024
2fdfda4
fmt
cliff0412 Aug 5, 2024
369b9d2
fmt
cliff0412 Aug 5, 2024
a01eb99
fmt
cliff0412 Aug 5, 2024
eeea2aa
fix
cliff0412 Aug 5, 2024
c0dddb8
fix warn
cliff0412 Aug 5, 2024
6b86c04
fmt
cliff0412 Aug 5, 2024
c1fc780
fmt
cliff0412 Aug 5, 2024
2a7a2af
fmt
cliff0412 Aug 5, 2024
4aba955
fmt
cliff0412 Aug 5, 2024
97a5242
finish circuit registry
RUAN0007 Aug 6, 2024
8575dfc
chore:add-mst-bench
Aug 6, 2024
000ac60
chore:fmt
Aug 6, 2024
8bf0f90
chore:fmt
Aug 6, 2024
44a0099
chore:fmt
Aug 6, 2024
0884140
finish batch proving in main prover
RUAN0007 Aug 6, 2024
357a0d9
address code comments
RUAN0007 Aug 6, 2024
ef46983
tmp
RUAN0007 Aug 6, 2024
b065aa5
remove unused imports
RUAN0007 Aug 6, 2024
eb787c9
fmt
RUAN0007 Aug 6, 2024
bcc4965
Merge pull request #27 from okx/feature/ruanpc/precompute_circuit_and…
cliff0412 Aug 6, 2024
f5b8d96
Merge branch 'dev' into feature/cliff/gen-mst
cliff0412 Aug 6, 2024
f0407ed
finish main prover
RUAN0007 Aug 6, 2024
0fd9d82
Merge remote-tracking branch 'origin/dev' into feature/ruanpc/main_pr…
RUAN0007 Aug 6, 2024
76122e3
finish main prover without testing
RUAN0007 Aug 6, 2024
3548de4
reature:add general abstraction of data parser
cliff0412 Aug 6, 2024
043b329
fmt
cliff0412 Aug 6, 2024
1c1f255
fmt
cliff0412 Aug 6, 2024
9bc862d
fmt
cliff0412 Aug 6, 2024
da4c187
fmt
cliff0412 Aug 6, 2024
b0ed0b7
fix build warn
cliff0412 Aug 6, 2024
d2d2c4a
fix test warn
cliff0412 Aug 6, 2024
a2ac3b9
refactor
cliff0412 Aug 6, 2024
cfedaf2
refactor
cliff0412 Aug 6, 2024
7680a48
fmt
cliff0412 Aug 6, 2024
3634ac9
refactor
cliff0412 Aug 7, 2024
48e9e53
refactor
cliff0412 Aug 7, 2024
efec49b
fmt
cliff0412 Aug 7, 2024
bee7eed
fix clippy
cliff0412 Aug 7, 2024
21b30b6
fmt
cliff0412 Aug 7, 2024
f115ce1
fix clippy
cliff0412 Aug 7, 2024
90a9b1a
install clippy on action
cliff0412 Aug 7, 2024
5ce7e53
refactor
cliff0412 Aug 7, 2024
a10e634
finish testing e2e
RUAN0007 Aug 7, 2024
1f98780
move circuit benchmarks into benchmark folder
RUAN0007 Aug 7, 2024
2377cfc
add test
cliff0412 Aug 7, 2024
ba0f89d
Fix build warn
cliff0412 Aug 7, 2024
c3b0fbb
fmt
cliff0412 Aug 7, 2024
f8be897
add tests
cliff0412 Aug 7, 2024
6dfc6f1
fmt
cliff0412 Aug 7, 2024
bf65eb4
add dockerfile
cliff0412 Aug 7, 2024
718498a
Merge pull request #29 from okx/feature/cliff/gen-mst
cliff0412 Aug 7, 2024
d4c5b9b
chore:update dockerfile
cliff0412 Aug 7, 2024
61a96cc
finish e2e proving test
RUAN0007 Aug 7, 2024
9b0e2ad
format
RUAN0007 Aug 7, 2024
260e6bd
Merge remote-tracking branch 'origin/dev' into feature/ruanpc/main_pr…
RUAN0007 Aug 7, 2024
b4f7394
Merge pull request #36 from okx/ci/cliff/workflow
cliff0412 Aug 7, 2024
7f38806
add merkle proof logic
Aug 7, 2024
a92780b
chore:merge
Aug 7, 2024
3830a22
add gen test data
cliff0412 Aug 8, 2024
ef8724f
fmt
cliff0412 Aug 8, 2024
2a6d0d2
rm local toml
cliff0412 Aug 8, 2024
2c8f6d4
refactor gitignore
cliff0412 Aug 8, 2024
c23e00b
refactor
cliff0412 Aug 8, 2024
1bfdb2c
Merge pull request #38 from okx/feature/cliff/gen-test-data-script
cliff0412 Aug 8, 2024
7bb3564
finish e2e
RUAN0007 Aug 8, 2024
f256a5d
Merge remote-tracking branch 'origin/dev' into feature/ruanpc/main_pr…
RUAN0007 Aug 8, 2024
495c430
feature:add-merkle-proof-logic
Aug 8, 2024
fdd7024
test:add-tests-for-merkle-proof
Aug 8, 2024
02b05fa
chore:fmt
Aug 8, 2024
8129ff6
format
RUAN0007 Aug 8, 2024
a0677bc
minor
RUAN0007 Aug 8, 2024
7ad4a03
test the root hash from mst and plonky2 proving are identical
RUAN0007 Aug 8, 2024
393da77
refactor prover
cliff0412 Aug 8, 2024
bfe1f4a
Merge remote-tracking branch 'origin/feature/ruanpc/main_prover' into…
RUAN0007 Aug 8, 2024
fb905bb
refactor
cliff0412 Aug 8, 2024
6356c55
Merge pull request #41 from okx/feature/get-merkle-proof
cliff0412 Aug 8, 2024
69341a7
finish code review
RUAN0007 Aug 8, 2024
7a88585
fix bug
RUAN0007 Aug 8, 2024
9659d25
bug fix
RUAN0007 Aug 8, 2024
7335d8d
Merge remote-tracking branch 'origin/dev' into feature/ruanpc/main_pr…
RUAN0007 Aug 8, 2024
3b7818b
Merge branch 'feature/ruanpc/main_prover' into feature/ruanpc/gen_rec…
RUAN0007 Aug 8, 2024
e99e7ff
factor out recursive proving at each level as separate function
RUAN0007 Aug 12, 2024
6d8f7c3
fix recursive index
cliff0412 Aug 12, 2024
8a55072
rm println
cliff0412 Aug 12, 2024
d6d54bc
fix padding
cliff0412 Aug 12, 2024
902a31e
fix fmt
cliff0412 Aug 12, 2024
9c778c3
Merge pull request #43 from okx/feature/cliff/gen-mst
RUAN0007 Aug 12, 2024
6d3daac
finish integration mst with prover
RUAN0007 Aug 12, 2024
de6ded4
Merge remote-tracking branch 'origin/dev' into feature/ruanpc/gen_rec…
RUAN0007 Aug 12, 2024
0031cd0
fix running bug
cliff0412 Aug 12, 2024
51f4202
merge with dev
cliff0412 Aug 12, 2024
9e24c67
fmt
cliff0412 Aug 12, 2024
95fab5e
refactor
cliff0412 Aug 12, 2024
55830f9
Merge pull request #37 from okx/feature/ruanpc/main_prover
cliff0412 Aug 12, 2024
ae4f1f0
fix bug that wrongly calculate global tree size
RUAN0007 Aug 12, 2024
fb67f64
check all nodes in global tree is set
RUAN0007 Aug 12, 2024
960158e
Merge remote-tracking branch 'origin/dev' into feature/ruanpc/gen_rec…
RUAN0007 Aug 12, 2024
f192607
fix recursive index
cliff0412 Aug 12, 2024
73a1cbf
add cli, progress bar
cliff0412 Aug 12, 2024
a3f9ede
fix:merkle-proof-non-power-of-2-recursive
Aug 12, 2024
2fc888e
Merge branch 'ci/cliff/workflow' of https://github.com/okx/proof-of-r…
Aug 12, 2024
c6f205e
test tree integrity
RUAN0007 Aug 12, 2024
9884288
finish integrating prover and gmst
RUAN0007 Aug 13, 2024
dc2d4d9
finish address code reviews
RUAN0007 Aug 13, 2024
ee2e13c
fix offset range
cliff0412 Aug 13, 2024
36d84cd
refactor
cliff0412 Aug 13, 2024
9d7ef59
refactor
cliff0412 Aug 13, 2024
e5ab502
fmt
cliff0412 Aug 13, 2024
af6df40
fix
cliff0412 Aug 13, 2024
29b3bb6
fix
cliff0412 Aug 13, 2024
ec92d05
fix
cliff0412 Aug 13, 2024
4e5f631
fix
cliff0412 Aug 13, 2024
0c570fd
Merge pull request #55 from okx/feature/ruanpc/gen_recursive_hash
cliff0412 Aug 13, 2024
c688997
merge with dev
cliff0412 Aug 13, 2024
123aa15
refactor
cliff0412 Aug 13, 2024
a40aaf0
fmt
cliff0412 Aug 13, 2024
129a744
fix build warn
cliff0412 Aug 13, 2024
7706a9b
Bug testing
Aug 13, 2024
264d567
fix:fix-mst-proof-bug
Aug 13, 2024
1d5e2af
chore:fmt
Aug 13, 2024
b424354
finsih verifier sdk
RUAN0007 Aug 13, 2024
4469b90
Merge pull request #45 from okx/ci/cliff/workflow
RUAN0007 Aug 13, 2024
94272fb
Merge remote-tracking branch 'origin/dev' into feature/ruanpc/verifier
RUAN0007 Aug 13, 2024
8e0cd26
Feature/cliff/database (#56)
cliff0412 Aug 13, 2024
9933818
Merge remote-tracking branch 'origin/dev' into feature/ruanpc/verifier
RUAN0007 Aug 14, 2024
48eeba0
finish prover and verifier sdk
RUAN0007 Aug 14, 2024
35052d6
finish prove and verify cli
RUAN0007 Aug 14, 2024
00681d4
minor bug fix
RUAN0007 Aug 14, 2024
efbc147
remove gen_mst
RUAN0007 Aug 14, 2024
4b865ad
use as ref
cliff0412 Aug 14, 2024
d7b5dff
edit readme
RUAN0007 Aug 15, 2024
3d430c6
typo
RUAN0007 Aug 15, 2024
803daef
finish address code comments
RUAN0007 Aug 15, 2024
3e52427
Merge pull request #58 from okx/feature/ruanpc/verifier
cliff0412 Aug 15, 2024
2622489
support read cross files
cliff0412 Aug 15, 2024
5228224
fmt
cliff0412 Aug 15, 2024
efd5948
fix
cliff0412 Aug 15, 2024
9c45b2c
Merge pull request #61 from okx/feature/cliff/parser_support_read_cro…
cliff0412 Aug 15, 2024
e0cc776
feature:add-merkle-verification-logic
Aug 16, 2024
1c4ef8e
test:test-get-index
Aug 16, 2024
c5167d2
feature:add-merkle-proof-sdk
Aug 16, 2024
f47a21b
Merge branch 'dev' of https://github.com/okx/proof-of-reserves-v2 int…
Aug 16, 2024
4b85554
chore:merge-fix
Aug 16, 2024
65fc1be
bugfix: file reader reads zero account
cliff0412 Aug 19, 2024
6e534df
fmt
cliff0412 Aug 19, 2024
e9030d5
bug fix gmst store index
cliff0412 Aug 19, 2024
d49ccc1
fmt
cliff0412 Aug 19, 2024
9023c4a
chore:pr-changes
Aug 19, 2024
6bda8ec
Merge branch 'feature/add-merkle-proof-sdk' of https://github.com/okx…
Aug 19, 2024
6ed5dba
feat:add-merkle-verification-to-verifier
Aug 19, 2024
c3b678d
chore:fmt
Aug 19, 2024
596e1bc
refactoring readme
cliff0412 Aug 19, 2024
fcb183a
fix bug
cliff0412 Aug 19, 2024
522edb9
fmt
cliff0412 Aug 19, 2024
354728b
chore:small-renaming-changes
Aug 19, 2024
500e8d9
add doc
cliff0412 Aug 19, 2024
53a8f57
feature:add-account-to-merkle-proof
Aug 19, 2024
55d4115
chore:fmt
Aug 19, 2024
fca1381
chore:merge-fix
Aug 19, 2024
5501b36
add solution doc
cliff0412 Aug 19, 2024
699c3e5
refactor readme
cliff0412 Aug 19, 2024
7344bbf
change-parser-logic
Aug 19, 2024
ffa70f9
Merge branch 'feature/add-merkle-proof-sdk' of https://github.com/okx…
Aug 19, 2024
9b5a0af
chore:fmt
Aug 19, 2024
1f562e5
add batch tree desctiption
cliff0412 Aug 19, 2024
45e6174
refactoring
cliff0412 Aug 19, 2024
11f7cc3
refactoring
cliff0412 Aug 19, 2024
fdb2ba9
refactor:add-root-as-input
Aug 19, 2024
bec9902
refactor
cliff0412 Aug 19, 2024
8ac681a
refactor
cliff0412 Aug 19, 2024
a0f159a
Merge pull request #63 from okx/feature/add-merkle-proof-sdk
cliff0412 Aug 19, 2024
a6cda4d
Merge branch 'dev' into doc/cliff/tech_description
cliff0412 Aug 19, 2024
895e9e8
refactoring docs
cliff0412 Aug 19, 2024
1249150
refactoring
cliff0412 Aug 19, 2024
8ff346a
refactoring
cliff0412 Aug 19, 2024
aca1c55
add batch tree
cliff0412 Aug 20, 2024
d06533d
for better demo
RUAN0007 Aug 20, 2024
0cae72f
add batch tree
cliff0412 Aug 20, 2024
50b0454
Merge pull request #67 from okx/ruanpc/feature/remove_root
cliff0412 Aug 20, 2024
670d251
refactor json
cliff0412 Aug 20, 2024
f6be3d7
refactor MERMAID
cliff0412 Aug 20, 2024
163f788
refactor
cliff0412 Aug 20, 2024
889ff85
add circuit constraints
cliff0412 Aug 20, 2024
8984756
add circuit constraints
cliff0412 Aug 20, 2024
069ac88
add circuit constraints
cliff0412 Aug 20, 2024
2d9d1d8
add circuit constraints
cliff0412 Aug 20, 2024
0887d4f
add circuit constraints
cliff0412 Aug 20, 2024
3276022
add circuit constraints
cliff0412 Aug 20, 2024
24741b7
add circuit constraints
cliff0412 Aug 20, 2024
de81056
add circuit constraints
cliff0412 Aug 20, 2024
d122100
refactoring
cliff0412 Aug 20, 2024
89e57a0
refactoring
cliff0412 Aug 20, 2024
64e26ab
refactoring
cliff0412 Aug 20, 2024
1cfdbf1
refactoring
cliff0412 Aug 20, 2024
23b9646
rephrasing
dloghin Aug 20, 2024
6264007
refactoring
cliff0412 Aug 20, 2024
714be61
Merge remote-tracking branch 'origin/doc/cliff/tech_description' into…
cliff0412 Aug 20, 2024
69713cf
edit readme
dloghin Aug 20, 2024
ab567bf
correct wroding
cliff0412 Aug 20, 2024
f716534
correct wording
cliff0412 Aug 20, 2024
2fdeb91
correct wording
cliff0412 Aug 20, 2024
3a2d134
small fix
dloghin Aug 20, 2024
722223d
Merge pull request #65 from okx/doc/cliff/tech_description
cliff0412 Aug 20, 2024
d94e86e
add tokens to config to decide token order in account
RUAN0007 Aug 21, 2024
3e0ced0
make batch size optional in config
RUAN0007 Aug 21, 2024
b240220
abstract out db as trait
RUAN0007 Aug 22, 2024
1070a28
make some config fields optional with default
RUAN0007 Aug 22, 2024
09cfab9
finish edit io for pm
RUAN0007 Aug 22, 2024
6b2d900
replace parser btreemap to json map
RUAN0007 Aug 23, 2024
70ecb13
address code reviews
RUAN0007 Aug 23, 2024
5bc8c62
add inline
cliff0412 Aug 23, 2024
0546619
refactor|
cliff0412 Aug 23, 2024
602bcb9
fmt
cliff0412 Aug 23, 2024
f983814
Merge pull request #69 from okx/ruanpc/feature/product
cliff0412 Aug 23, 2024
db31d02
Merge pull request #66 from okx/dev
cliff0412 Sep 2, 2024
51db482
update change log
cliff0412 Sep 2, 2024
aef216a
update-changelog
Sep 2, 2024
19f4e01
default 0 equity for missing token
RUAN0007 Sep 2, 2024
a7bef3a
change to rust format
RUAN0007 Sep 2, 2024
b0ecc5f
Merge pull request #74 from okx/feature/ruanpc/default_token_equity
cliff0412 Sep 2, 2024
a4b30e9
Merge pull request #72 from okx/chore/update-changelog
cliff0412 Sep 2, 2024
ad66bde
updage change log
cliff0412 Sep 2, 2024
1e214ca
Merge pull request #73 from okx/dev
cliff0412 Sep 2, 2024
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
71 changes: 71 additions & 0 deletions .github/workflows/rust.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,71 @@
name: CI

on:
push:
branches: [ "main" ]
pull_request:
branches: [ "*" ]

env:
CARGO_TERM_COLOR: always

jobs:
build:
runs-on: ubuntu-latest
env:
CODE_COV_VAL: '0'

steps:
- name: Clone main repository
uses: actions/checkout@v4

- uses: moonrepo/setup-rust@v1
with:
components: rustfmt
cache: false
name: Setup Rust Toolchain

- uses: Swatinem/rust-cache@v2
name: Cache Rust Dependencies

- run: export RUSTFLAGS="-D warnings" && cargo build
name: Run build scripts

- name: Check Format
run: cargo fmt --check
working-directory: .

- name: Run Clippy
run: rustup component add clippy && cargo clippy
working-directory: .

- name: Install dependencies
run: sudo apt-get install -y musl-tools

- name: Install tarpaulin
run: cargo install cargo-tarpaulin

- name: Run tests with coverage
run: |
cargo tarpaulin --lib --out Html --output-dir target/debug/tarpaulin/ -- --nocapture > test.log
LAST_LINE=$( tail -n 1 test.log)
CODE_COV=$(echo "$LAST_LINE" | cut -d '%' -f 1)
echo "CODE_COV: $CODE_COV"
COLOR=$(
float=$(echo "$CODE_COV" | bc)
threshold=80.0
if (( $(echo "$float > $threshold" | bc -l) )); then
echo "brightgreen"
else
echo "yellow"
fi
)
echo "COLOR: $COLOR"
sh ./scripts/gen_svg.sh $COLOR $CODE_COV

- name: Deploy to GitHub Pages
uses: peaceiris/actions-gh-pages@v4
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: ./target/debug/tarpaulin/
publish_branch: gh-pages
12 changes: 12 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
/target
.vscode/
target/
logs/
plonky2/
config/local.toml
config/prod.toml
test-data/user-data*/
test-data/proofs*/
my_permanent_leveldb/
*level_db*/
*.json
50 changes: 50 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
# Changelog

All notable changes to this project will be documented in this file.

## [0.1.0] - 2024-08-23

### 🚀 Features

- Add general-recursive-n proofs ([#74](https://github.com/okx/proof-of-reserves-v2/pull/74))
- Add-merkle-sum-tree-circuit-with-tests ([#14](https://github.com/okx/proof-of-reserves-v2/pull/14))
- Add tracing ([#9](https://github.com/okx/proof-of-reserves-v2/pull/9))
- Add leveldb ([#20](https://github.com/okx/proof-of-reserves-v2/pull/20))
- Add-scheme-for-userid-hashing ([#14](https://github.com/okx/proof-of-reserves-v2/pull/14))
- Add global mst ([#35](https://github.com/okx/proof-of-reserves-v2/issues/35))
- Add-merkle-proof-logic ([#41](https://github.com/okx/proof-of-reserves-v2/pull/41))
- Add-merkle-verification-logic ([#63](https://github.com/okx/proof-of-reserves-v2/pull/63))
- Add-merkle-proof-sdk ([#63](https://github.com/okx/proof-of-reserves-v2/pull/63))
- Add-account-to-merkle-proof ([#63](https://github.com/okx/proof-of-reserves-v2/pull/63))

### 🐛 Bug Fixes

- Merkle-proof-non-power-of-2-recursive
- Fix-mst-proof-bug

### 🚜 Refactor

- Remove-proving-circuits
- Refactor-and-wrap-recursive-in-prover
- Add-root-as-input

### 📚 Documentation

- Add readme description

### 🧪 Testing

- Add-tests-for-merkle-proof ([#41](https://github.com/okx/proof-of-reserves-v2/pull/41))
- Test-get-index

### ⚙️ Miscellaneous Tasks

- Add code coverage ([#24](https://github.com/okx/proof-of-reserves-v2/pull/24))
- Refactor-recursive-wrap-in-prover
- Refactor-into-prover

### Bugfix

- File reader reads zero account

<!-- generated by git-cliff -->
Loading