omgnetwork / elixir-omg

OMG-Network repository of Watcher and Watcher Info
https://omg.network
Apache License 2.0
211 stars 59 forks source link

As a user I would like to understand on what constitutes as a valid block so that I can create my own block validation implementation. #1183

Open thec00n opened 4 years ago

thec00n commented 4 years ago

Description

Currently there is no specification on what constitutes as a valid block. Block validation is a critical function of the network and validation should not strictly be limited to the watcher but be possible in any implementation that a user chooses. Similar to transaction validation https://github.com/omisego/elixir-omg/blob/master/docs/transaction_validation.md there should be a spec for block validation.

InoMurko commented 4 years ago

@achiurizo ex_plasma?

achiurizo commented 4 years ago

yep, it's certainly a good place to put this kind of knowledge/behavior in ex_plasma. It can already handle crafting transactions, utxos(input/output), and block formations.

Idea I'm playing around is if it makes sense to use the ecto changeset functionality to help implement validation. It also would pave the way towards using ecto as our storage driver.

pdobacz commented 4 years ago

Idea I'm playing around is if it makes sense to use the ecto changeset

this in particular is on my mind since long, never got to it :cry: