Commit Graph

40 Commits

Author SHA1 Message Date
arnau
b0cfcb0d50 Merge pull request #111 from hermeznetwork/feature/L1TxCodec
L1Tx Codec
2020-09-15 11:57:07 +02:00
Eduard S
d416203f10 Merge pull request #114 from hermeznetwork/feature/compute-zkinputs
Feature/compute zkinputs
2020-09-10 18:02:19 +02:00
arnaucube
69fe471f11 Add StateTree leafs & ExtTree data ZKI calculation 2020-09-10 17:58:08 +02:00
ToniRamirezM
a8f6488eb1 L1Tx Codec 2020-09-10 13:32:22 +02:00
Eduard S
475614cc3a Implement first iteration of node
The coordinator implementation has been refactored to allow all the goroutines
to be handled from the node.
2020-09-10 11:36:58 +02:00
arnaucube
aa0bde61d2 Add StateDB ZKInputs generation for L1 & L2 Txs 2020-09-09 14:40:55 +02:00
arnaucube
a7fe80f150 Refactor ZKInputs & add struct initialization
Refactor ZKInputs & add struct initialization & add BJJCompressedTo256BigInts util
2020-09-09 14:16:09 +02:00
Eduard S
56604ecc69 Use int64 for blockNum (like it's sroted in DB) 2020-09-07 18:09:27 +02:00
Eduard S
003c353f05 Add ethclient full skeleton 2020-09-07 17:29:55 +02:00
krlosMata
4d02308057 update zkInputs (#104)
* update zkInputs

* ZKInputs clean uncomment use nolint

Co-authored-by: arnaucube <root@arnaucube.com>
2020-09-04 09:49:23 +02:00
arnaucube
fdaf2c9ce2 Update log package with fields & file log
Update log package with fields & file log, and update constants in the
repository code to be MixedCase.

resolves #91, resolves #92, resolves #95
2020-09-02 10:56:48 +02:00
arnaucube
cbbcb65c8c Add lint checks: gofmt, goimports, golint
- gofmt - Gofmt checks whether code was gofmt-ed. By default this tool runs
  with -s option to check for code simplification
- goimports - Goimports does everything that gofmt does. Additionally it checks
  unused imports
- golint - Golint differs from gofmt. Gofmt reformats Go source code, whereas
  golint prints out style mistakes
    - checks the uncommented exported functions & types

Update the code to fix the lint checks.
2020-08-31 12:32:05 +02:00
arnaucube
fd1e9c25ee Add linter checks to GHA & Fix code to pass lints
Add linter checks to GHA & Fix code to pass lints.
The linters added are:
- whitespace: Tool for detection of leading and trailing whitespace
- gosec: Inspects source code for security problems
- gci: Gci control golang package import order and make it always deterministic
- misspell: Finds commonly misspelled English words in comments
- gomnd: An analyzer to detect magic numbers

The file utils/utils.go is excluded from the checks of gomnd, as uses magic numbers through the code
2020-08-28 09:58:39 +02:00
arnaucube
9309722dfc Update StateDB to new & ExitInfo struct & BatchNum
Update StateDB to new & ExitInfo struct & BatchNum
Also a small fix at txselector & log packages
2020-08-26 18:28:53 +02:00
Arnau B
3e7173b1da Impl historyDB methods for sync main loop 2020-08-26 14:31:24 +02:00
Arnau B
c108739c24 Add usefull methods for reorg 2020-08-25 14:15:12 +02:00
Arnau B
1cbf54acc7 Add sync interface 2020-08-25 14:14:51 +02:00
arnaucube
b4044a2ef7 Add abstraction method of processTxs to StateDB
- Update GHA lint.yml increasing timeout time to avoid GHA Lint errors
- Update common.BatchNum & common.Idx & common.Nonce usage in StateDB
- Add abstraction method of processTxs to StateDB
    - Which will be used by Synchronizer & BatchBuilder
2020-08-24 13:06:51 +02:00
arnaucube
b33d18ff55 Import & adapt iden/go-iden3-core/eth/client 2020-08-24 11:19:39 +02:00
arnaucube
7fa658cc84 Add PoolL2Tx verify signature needed methods
Implements the hash to be signed from PoolL2Tx, compatible with javascript version.
Implements the signature verification for a given PoolL2Tx.
2020-08-24 09:46:25 +02:00
arnaucube
a28c81f4ae Add TxCompressedData & V2 with some extra parsers for common 2020-08-21 15:35:31 +02:00
arnaucube
8eb42c011c Add tx L1&L2 test generation & keys for TestingFramework
Add test-lang Fee & ForceExit option
2020-08-20 11:57:44 +02:00
arnaucube
e2d4599690 Add tx generation lang interpreter 2020-08-19 15:58:20 +02:00
arnaucube
c702442287 Update Coordinator & BatchBuilder & TxSelector to new SQL schemas changes 2020-08-17 16:16:25 +02:00
a_bennassar
cb1b820256 Update SQL schemas 2020-08-17 16:16:17 +02:00
arnaucube
8390e4a784 Add initial structure Coordinator Forge Sequence 2020-08-14 14:06:28 +02:00
arnaucube
60fa76b4d2 Integrate TxSelector with StateDB 2020-08-13 13:07:30 +02:00
a_bennassar
428dcd7590 create sql tables (#40)
Co-authored-by: Eduard S <eduard@iden3.io>
2020-08-11 16:25:55 +02:00
arnau
edb8974a5a Apply fix method description typos
Co-authored-by: Eduard S. <eduard@iden3.io>
2020-08-10 16:46:15 +02:00
arnaucube
d8cb7298e0 Add StateDB & LocalStateDB 2020-08-07 10:59:30 +02:00
arnau
2109d9f1cf Apply suggestions from code review
Co-authored-by: Eduard S. <eduard@iden3.io>
2020-08-06 12:50:52 +02:00
arnaucube
16555b51e3 Update Leaf to new spec (Sign+Ay) 2020-08-05 16:06:31 +02:00
arnaucube
bcd9f96e1b Add batchbuilder applyCreateLeaf, applyDeposit, applyTransfer 2020-08-05 15:31:27 +02:00
arnaucube
37cefb0057 Add common> Idx parsers 2020-08-05 15:26:15 +02:00
arnaucube
f3cfba1bbe Add initial structure of BatchBuilder 2020-08-05 15:22:51 +02:00
arnaucube
dd1901709c Add common/Leaf struct & parsers (bigint & byte arrays) 2020-08-05 15:22:48 +02:00
arnaucube
59644c3435 Add common/Leaf struct & parsers (bigint & byte arrays) 2020-08-05 13:32:24 +02:00
a_bennassar
638defd031 Update to follow DB spec 2020-08-03 10:26:29 +02:00
a_bennassar
1d8f9411f7 Review changes and operator -> coordinator 2020-07-28 16:54:28 +02:00
a_bennassar
b9936f8564 Initial dract of the common structs 2020-07-28 12:37:36 +02:00