1. Mar 03, 2020
  2. Feb 21, 2020
    • Cecile Tonglet's avatar
      Add tests & Service's Configuration has optional fields that shouldn't be optional (#4842) · 97ad8026
      Cecile Tonglet authored
      Related to #4776 
      Related to https://github.com/paritytech/polkadot/pull/832
      
      To summarize the changes:
      1. I did not manage to validate with types the service's Configuration. But I did reduce the possibility of errors by moving all the "fill" functions to their respective structopts
      2. I split params.rs to multiple modules: one module params for just CLI parameters and one module commands for CLI subcommands (and RunCmd). Every command and params are in their own file so things are grouped better together and easier to remove
      3. I removed the run and run_subcommand helpers as they are not helping much anymore. Running a command is always a set of 3 commands: 1. init 2. update config 3. run. This still allow the user to change the config before arguments get parsed or right after.
      4. I added tests for all subcommands.
      5. [deleted]
      
      Overall the aim is to improve the situation with the Configuration and the optional parameters, add tests, make the API more consistent and simpler.
      97ad8026
  3. Feb 17, 2020
    • Shawn Tabrizi's avatar
      Fix various spelling errors (#4940) · db1ab7d1
      Shawn Tabrizi authored
      
      
      * meaningfull -> meaningful
      
      * initialise -> initialize
      
      * tokans -> tokens
      
      * incentivise -> incentivize
      
      * lenght -> length
      
      * incentivisation -> incentivization
      
      * doesnt't -> doesn't
      
      * overwriten -> overwritten
      
      * lifecycle -> life cycle
      
      * lifecycle -> life cycle
      
      * usefull -> useful
      
      * noone -> no one
      
      * spaming -> spamming
      
      * defered -> deferred
      
      * hieght -> height
      
      * sumation -> summation
      
      * ingore -> ignore
      
      * registed -> registered
      
      * Auxialary -> Auxiliary
      
      * loggin -> logging
      
      * independance -> independence
      
      * trailling -> trailing
      
      * responsability -> responsibility
      
      * trunkated -> truncated
      
      * Weither -> Whether
      
      * informations -> information
      
      * Runtume -> Runtime
      
      * choosen -> chosen
      
      * delcataion -> declaration
      
      * Unchekced -> Unchecked
      
      * defintion -> definition
      
      * scrach -> scratch
      
      * imput -> input
      
      * transfered -> transferred
      
      * endownment -> endowment
      
      * Determinator -> Determiner
      
      * relevent -> relevant
      
      * emited -> emitted
      
      * acocunt -> account
      
      * proprotional -> proportional
      
      * instantiaion -> instantiation
      
      * commited -> committed
      
      * tombstonedead -> tombstone
      
      * uwnrap -> unwrap
      
      * acount -> account
      
      * specialised -> specialized
      
      * existant -> existent
      
      * requried -> required
      
      * Anull -> Annul
      
      * AUTHORITES -> AUTHORITIES
      
      * underyling -> underlying
      
      * recognisable -> recognizable
      
      * Capitalise -> Capitalize
      
      * reportfor -> report for
      
      * hearbeat -> heartbeat
      
      * onlineness -> being online
      
      * creater -> creator
      
      * Bytearray -> Byte array
      
      * Despoit -> Deposit
      
      * substratced -> subtracted
      
      * Curent -> Current
      
      * imbalanes -> imbalances
      
      * countfown -> countdown
      
      * inexisting -> inexistent
      
      * additionaly -> additionally
      
      * substracted -> subtracted
      
      * auxilary -> auxiliary
      
      * parital -> partial
      
      * in't -> isn't
      
      * compatability -> compatibility
      
      * infomation -> information
      
      * etected -> detected
      
      * extrinsiscs -> extrinsics
      
      * reprensentation -> representation
      
      * coonfiguration -> configuration
      
      * primtives -> primitives
      
      * miscelanious -> miscellaneous
      
      * VERISON -> VERSION
      
      * endcoded -> encoded
      
      * Genrates -> Generates
      
      * miliseconds -> milliseconds
      
      * occured -> occurred
      
      * trully -> truely
      
      * truely -> truly
      
      * conjuction -> conjunction
      
      * encouters -> encounters
      
      * customised -> customized
      
      * deterministicly -> deterministically
      
      * finalisation -> finalization
      
      * pluggable -> plugable
      
      * wakeup -> wake-up
      
      * interemdiate -> intermediate
      
      * intepreting -> interpreting
      
      * finalzied -> finalized
      
      * throgh -> through
      
      * extinsic -> extrinsic
      
      * convient -> convenient
      
      * allocater -> allocator
      
      * propagateable -> propagatable
      
      * succesfuly -> successfully
      
      * finalising -> finalizing
      
      * publically -> publicly
      
      * phrasee -> phrase
      
      * substration -> substractions
      
      * substractions -> subtractions
      
      * neccessarily -> necessarily
      
      * Inlucde -> Include
      
      * unefficient -> inefficient
      
      * thay -> they
      
      * funtion -> function
      
      * datastructures -> data structures
      
      * infromation -> information
      
      * propagatable -> propagable
      
      * ecountered -> encountered
      
      * recognise -> recognize
      
      * intergration -> integration
      
      * lastet -> latest
      
      * datatypes -> data types
      
      * datatype -> data type
      
      * Strongarming -> Strong Arming
      
      * avaible -> available
      
      * Commiting -> Committing
      
      * Retreiving -> Retrieving
      
      * shoud -> should
      
      * canonicaliziation -> canonicalization
      
      * comitted -> committed
      
      * clonable -> cloneable
      
      * Uknown -> Unknown
      
      * reponse -> response
      
      * arbitary -> arbitrary
      
      * Capapbilities -> Capabilities
      
      * responsbile -> responsible
      
      * initialisation -> initialization
      
      * cames -> came
      
      * intemediate -> intermediate
      
      * reqeust -> request
      
      * intance -> instance
      
      * explcitly -> explicitly
      
      * neighor -> neighbor
      
      * reolving -> resolving
      
      * untill -> until
      
      * Validte -> Validate
      
      * deserailize -> deserialize
      
      * literaly -> literally
      
      * preceeding -> preceding
      
      * abpve -> above
      
      * chcecked -> checked
      
      * numbet -> number
      
      * Unknow -> Unknown
      
      * halfs -> halves
      
      * gossup -> gossip
      
      * givent -> given
      
      * immediatelly -> immediately
      
      * slicable -> sliceable
      
      * conensus -> consensus
      
      * Mimicks -> Mimics
      
      * acccept -> accept
      
      * serialise -> serialize
      
      * exstrinsics -> extrinsics
      
      * panicks -> panics
      
      * maintaince -> maintenance
      
      * repeatidely -> repeatedly
      
      * anecstor -> ancestor
      
      * becasue -> because
      
      * processer -> processor
      
      * Prunning -> Pruning
      
      * insterested -> interested
      
      * unuseful -> not useful
      
      * yeided -> yielded
      
      * descendfing -> descending
      
      * corresponts -> corresponds
      
      * survivew -> survive
      
      * keps -> keeps
      
      * ligh -> light
      
      * prerequisities -> prerequisites
      
      * positiion -> position
      
      * depedency -> dependency
      
      * extrinisic -> extrinsic
      
      * atomicaly -> atomically
      
      * staticly -> statically
      
      * resul -> result
      
      * timestamb -> timestamp
      
      * Utilites -> Utilities
      
      * ammount -> amount
      
      * pocess -> process
      
      * exteral -> external
      
      * Update client/finality-grandpa/src/tests.rs
      
      * Update primitives/io/src/lib.rs
      
      Co-Authored-By: default avatarjoe petrowski <[email protected]>
      
      * Update primitives/blockchain/src/lib.rs
      
      Co-Authored-By: default avatarjoe petrowski <[email protected]>
      
      * Update frame/support/src/weights.rs
      
      Co-Authored-By: default avatarjoe petrowski <[email protected]>
      
      * Update bin/node/cli/tests/common.rs
      
      Co-Authored-By: default avatarjoe petrowski <[email protected]>
      
      * Update client/api/src/execution_extensions.rs
      
      Co-Authored-By: default avatarjoe petrowski <[email protected]>
      
      * Update client/cli/src/params.rs
      
      Co-Authored-By: default avatarjoe petrowski <[email protected]>
      
      * Update client/executor/common/src/sandbox.rs
      
      Co-Authored-By: default avatarjoe petrowski <[email protected]>
      
      * Update client/api/src/execution_extensions.rs
      
      Co-Authored-By: default avatarjoe petrowski <[email protected]>
      
      * Update client/finality-grandpa/src/communication/mod.rs
      
      Co-Authored-By: default avatarjoe petrowski <[email protected]>
      
      * Update client/state-db/src/pruning.rs
      
      Co-Authored-By: default avatarjoe petrowski <[email protected]>
      
      * Update frame/contracts/src/tests.rs
      
      Co-Authored-By: default avatarjoe petrowski <[email protected]>
      
      * Update client/api/src/execution_extensions.rs
      
      * bump impl
      
      * timestamb -> timestamp
      
      Co-authored-by: default avatarjoe petrowski <[email protected]>
      db1ab7d1
  4. Feb 13, 2020
  5. Feb 10, 2020
    • Tomasz Drwięga's avatar
      Run offchain workers at hash, not number. (#4878) · 671cb852
      Tomasz Drwięga authored
      
      
      * Run offchain workers at particular hash, not number.
      
      * Don't run if not new best.
      
      * Don't run if not new best.
      
      * Update client/service/src/builder.rs
      
      Co-Authored-By: default avatarNikolay Volf <[email protected]>
      
      * Update client/service/src/builder.rs
      
      Co-Authored-By: default avatarNikolay Volf <[email protected]>
      
      * Update client/service/src/builder.rs
      
      Co-authored-by: default avatarNikolay Volf <[email protected]>
      671cb852
    • Shawn Tabrizi's avatar
      Create Benchmarking Setup for Identity Pallet #4695 (#4818) · 8b6b093d
      Shawn Tabrizi authored
      
      
      * Starting
      
      * closer
      
      * Compiles!
      
      * comments
      
      * Create seperate mock
      
      * Remove changes to test env
      
      * Fix step calculation
      
      * Add host function
      
      * Add runtime api
      
      * compiles
      
      * Update to use offchain timestamp
      
      * Gives a result
      
      * added some CLI wip
      
      * make generic
      
      * Update instance
      
      * Remove CLI stuff
      
      * Remove last cli stuff
      
      * undo more changes
      
      * Update benchmarks
      
      * Update Cargo.lock
      
      * remove test
      
      * Move loop out of runtime
      
      * Benchmarking externalities
      
      * Benchmarking state
      
      * Implemented commit
      
      * Make CLI work, move loop back into runtime
      
      * Wipe resets to genesis
      
      * Speedup benchmarks
      
      * Use enum to select extrinsic within pallet
      
      * CLI controls which module and extrinsic to call
      
      * Select a pallet with cli
      
      * Add steps and repeats to cli
      
      * Output as CSV format
      
      * Introduce benchmark pallet
      
      * Append bench
      
      * Use Results
      
      * fix merge
      
      * Clear Identity benchmark
      
      * Bench request judgment and cancel request
      
      * Add final benchmarks
      
      * Fix CSV output
      
      * Start cleaning up for PR
      
      * Bump numbers in `wasmtime` integration tests.
      
      * More docs
      
      * Add rockdb feature to bench
      
      * Fix formatting issues
      
      * Add test feature to bench
      
      * Add test feature to bench
      
      * Add rocksdb feature flag
      
      * Update bench.rs
      
      Co-authored-by: default avatarArkadiy Paronyan <[email protected]>
      Co-authored-by: default avatarGavin Wood <[email protected]>
      8b6b093d
  6. Feb 09, 2020
  7. Jan 29, 2020
  8. Jan 17, 2020
  9. Jan 16, 2020
    • Svyatoslav Nikolsky's avatar
      Allow updating configuration of changes tries (#3201) · 8e986433
      Svyatoslav Nikolsky authored
      
      
      * DigestItem::ChangesTrieSignal
      
      * introduce changes_trie::State
      
      * introduce config activation block
      
      * ChangesTrieSignal::as_new_configuration
      
      * moved well_known_cache_keys to client
      
      * extracted DbChangesTrieStorage to separate file
      
      * change meaning of none in blockchain cache
      
      * changes trie config (FULL) cache draft
      
      * eliminating const ChangesTrieConfiguration
      
      * delay pruning
      
      * continue elimination
      
      * do not prune CT config from cache
      
      * removed redundant code
      
      * fix some TODOs
      
      * introduce ConfigurationRange
      
      * use Configuration range in build
      
      * build skewed digest
      
      * remove debug print
      
      * extracted surface iterator
      
      * key_changes works with skewed digests
      
      * fix client build
      
      * add test for NeverPrune
      
      * fix TODO
      
      * fixed some TODOs
      
      * more tests
      
      * fixing TODOs
      
      * fixed compilation
      
      * update runtime version
      
      * git rid of large tuple
      
      * too long lines
      
      * config_activation_block -> zero
      
      * obsolete TODO
      
      * removed unjustified expect
      
      * update TODOs with issue number
      
      * new CT pruning algorithm
      
      fixed cache + multiple blocks finalization
      
      track CT configuraiton on light clients
      
      support CT configuration change revert
      
      revert CT config test
      
      new CT pruning algorithm
      
      fixed cache + multiple blocks finalization
      
      track CT configuraiton on light clients
      
      support CT configuration change revert
      
      revert CT config test
      
      * BlockIdOrHeader isn't really required
      
      * removed debug leftovers + some docs
      
      * more docs
      
      * more post-merge fixes
      
      * more post-merge fixes
      
      * revertes some unnecessary changes
      
      * reverted unnecessary changes
      
      * fix compilation + unnecessary changes
      
      * (restart CI)
      
      * fix cache update when finalizing multiple blocks
      
      * fixed tests
      
      * collect_extrinsics -> set_collect_extrinsics
      
      * restore lost test
      
      * do not calculate block number twice
      
      * Update primitives/blockchain/src/error.rs
      
      Co-Authored-By: default avatarcheme <[email protected]>
      
      * map_err -> unwrap_or
      
      * document get_at Result
      
      * delete abandoned file
      
      * added weight for set_changes_trie_config
      
      * prefer_configs -> fail_if_disabled
      
      * Update client/api/src/backend.rs
      
      Co-Authored-By: default avatarcheme <[email protected]>
      
      * Update client/db/src/changes_tries_storage.rs
      
      Co-Authored-By: default avatarcheme <[email protected]>
      
      * CommitOperation+merge -> CommitOperations
      
      * fixed test compilation
      
      * merged two different CTRange structs
      
      * lost file
      
      * uggrade db from v0 to v1 (init CT cache + add column)
      
      * fix after merge
      
      Co-authored-by: default avatarcheme <[email protected]>
      Co-authored-by: default avatarGavin Wood <[email protected]>
      8e986433
  10. Jan 14, 2020
    • Bastian Köcher's avatar
      Take `genesis_storage` by ref (#4617) · b443ddad
      Bastian Köcher authored
      Instead of having these weird implementation of `BuildStorage for
      &ChainSpec` we should just take the `genesis_storage` by ref. The
      `BuildStorage` trait changed some time ago to take a self ref anyway,
      instead of a self value.
      
      Also fixes warnings in frame-staking
      b443ddad
  11. Jan 13, 2020
  12. Jan 11, 2020
  13. Jan 10, 2020
    • Bastian Köcher's avatar
      Remove requirement on `Hash = H256`, make `Proposer` return `StorageChanges` and `Proof` (#3860) · 4ed0ad6f
      Bastian Köcher authored
      
      
      * Extend `Proposer` to optionally generate a proof of the proposal
      
      * Something
      
      * Refactor sr-api to not depend on client anymore
      
      * Fix benches
      
      * Apply suggestions from code review
      
      Co-Authored-By: default avatarTomasz Drwięga <[email protected]>
      
      * Apply suggestions from code review
      
      * Introduce new `into_storage_changes` function
      
      * Switch to runtime api for `execute_block` and don't require `H256`
      anywhere in the code
      
      * Put the `StorageChanges` into the `Proposal`
      
      * Move the runtime api error to its own trait
      
      * Adds `StorageTransactionCache` to the runtime api
      
      This requires that we add `type NodeBlock = ` to the
      `impl_runtime_apis!` macro to work around some bugs in rustc :(
      
      * Remove `type NodeBlock` and switch to a "better" hack
      
      * Start using the transaction cache from the runtime api
      
      * Make it compile
      
      * Move `InMemory` to its own file
      
      * Make all tests work again
      
      * Return block, storage_changes and proof from Blockbuilder::bake()
      
      * Make sure that we use/set `storage_changes` when possible
      
      * Add test
      
      * Fix deadlock
      
      * Remove accidentally added folders
      
      * Introduce `RecordProof` as argument type to be more explicit
      
      * Update client/src/client.rs
      
      Co-Authored-By: default avatarTomasz Drwięga <[email protected]>
      
      * Update primitives/state-machine/src/ext.rs
      
      Co-Authored-By: default avatarTomasz Drwięga <[email protected]>
      
      * Integrates review feedback
      
      * Remove `unsafe` usage
      
      * Update client/block-builder/src/lib.rs
      
      Co-Authored-By: default avatarBenjamin Kampmann <[email protected]>
      
      * Update client/src/call_executor.rs
      
      * Bump versions
      
      Co-authored-by: default avatarTomasz Drwięga <[email protected]>
      Co-authored-by: default avatarBenjamin Kampmann <[email protected]>
      4ed0ad6f
  14. Jan 09, 2020
  15. Jan 07, 2020
  16. Jan 06, 2020
  17. Jan 05, 2020
  18. Jan 03, 2020
  19. Dec 16, 2019
    • Tomasz Drwięga's avatar
      [big refactor] Remove crate aliasing. (#4395) · 40a16efe
      Tomasz Drwięga authored
      * Rename: Phase 1.
      
      * Unify codec.
      
      * Fixing: Phase 2
      
      * Fixing: Phase 3.
      
      * Fixing: Phase 4.
      
      * Fixing: Phase 5.
      
      * Fixing: Phase 6.
      
      * Fixing: Phase 7.
      
      * Fixing: Phase 8. Tests
      
      * Fixing: Phase 9. Tests!!!
      
      * Fixing: Phase 10. Moar tests!
      
      * Finally done!
      
      * More fixes.
      
      * Rename primitives:: to sp_core::
      
      * Apply renames in finality-grandpa.
      
      * Fix benches.
      
      * Fix benches 2.
      
      * Revert node-template.
      
      * Fix frame-system in our modules.
      40a16efe
  20. Dec 14, 2019
    • cheme's avatar
      Fix key collision for child trie (#4162) · 9f4c7b78
      cheme authored
      * In progress, runtime io must switch to future proof root +
      child_specific (unique id) + u32 type.
      
      * Switch interface, sr-io seems ok, rpc could use similar interface to
      sr-io, genesis json broken if there is child trie in existing encoding
      genesis.
      
      * test from previous implementation.
      
      * fix proving test.
      
      * Restore Keyspacedb from other branch, only apply to child trie.
      
      * Removing unneeded child_info from child root (child info are stored
      if things changed, otherwhise the root does not change).
      
      * Switch rpc to use same format as ext: more future proof.
      
      * use root from child info for trie backend essence.
      
      * Breaking long lines.
      
      * Update doc and clean pr a bit.
      
      * fix error type
      
      * Restore removed doc on merge and update sr-io doc.
      
      * Switch child storage api to use directly unique id, if managed id
      where to be put in place, the api will change at this time.
      
      * Clean deprecated host interface from child.
      
      * Removing assertio...
      9f4c7b78
  21. Dec 09, 2019
    • thiolliere's avatar
      Introduce prefixed storage with enumeration (#4185) · 6b70f127
      thiolliere authored
      * Introduce storage_next allowing iteration.  (without childtries)
      
      * Implement prefixed storage
      
      * impl cache in client_storage_cache (needs test)
      
      * switch overlay change to btreemap
      
      * Revert "impl cache in client_storage_cache"
      
      This reverts commit c91a4848.
      
      the storage cache cannot be used this way
      
      * Revert "Implement prefixed storage"
      
      This reverts commit 49310881.
      
      * Impl StoragePrefixedMap for all map storages
      
      * remove comment
      
      * Move all overlays to BTreeMap
      
      * btreemap iteration improvment
      
      * impl for child tries
      
      * impl tests for childs
      
      * fix
      
      * remove cache comment
      
      * Fix grumble
      6b70f127
  22. Dec 02, 2019
    • Benjamin Kampmann's avatar
      The crate rename (#4223) · 28c329e0
      Benjamin Kampmann authored
      * Adding script for rename, could be applicable for nodes on top of it, too
      
      * add stderr and gitlab ci features
      
      * apply script
      
      * fix now minor details in expected stderr
      
      * Update the Cargo.lock
      
      * fix name: sc-transaction -> sc-tracing
      
      * fix rename in script, too
      28c329e0
  23. Nov 28, 2019
  24. Nov 26, 2019
    • Benjamin Kampmann's avatar
      Remove all (non-dev) `client` references from `frame`, activate dependency enforcer (#4184) · b3a7c8e4
      Benjamin Kampmann authored
      * Move transaction pool to primitives
      
      * move backend, errors into primitives
      
      * remove unused client depencies
      
      * Move rpc-api into primitives
      
      * Move peerset back to client
      
      * Move rpc/api back to client, move palette/support/rpc into utils
      
      * move support-rpc into subfolder
      
      * move system-rpc into utils
      
      * move transaction-pool  and -graph back into client
      
      * fix broken imports
      
      * Clean up test primitives
      
      * Make support test utils independent of frame
      
      * remove unnecessary node dependencies from service
      
      * Reactivate dependency script:
       - only enforce the now achieved status quo will remain
       - allow for primitives to depend on /client for now without failing
       - more discriptive error message so people understand, what it wants
       - minor fix to differentiative between ../client and /client (which may be a subfolder)
       - don't allow this to fail anylonger.
      
      * fix doc comment
      
      * 'Should not' rather than 'must not'.
      
      * Revert unwanted dependency changes
      
      * fix faulty import
      
      * fixup derive_more version
      
      * fix wrong import path
      b3a7c8e4
    • Bastian Köcher's avatar
      Give `state_col` 90% of memory budget and fix other col calculation (#4208) · 2b716b5a
      Bastian Köcher authored and asynchronous rob's avatar asynchronous rob committed
      * Give `state_col` 90% of memory budget and fix other col calculation
      
      * Set default db cache size to 1024
      2b716b5a
  25. Nov 25, 2019
  26. Nov 23, 2019
    • Bastian Köcher's avatar
      Switch to new kvdb-rocksdb (#4186) · eef00ea7
      Bastian Köcher authored
      
      
      * Switch to new rocksdb with some hacks to resolve linking errors
      
      Rocksdb and `wasmtime-environ` both link `zstd`. In the final link step,
      this leads to linking errors because of duplicate symbols. The linked
      Rocksdb fixes this by using `zstd-sys` as well. However, this currently
      also requires modifications in `zstd-sys`. Someone will need to come up
      with a better implementation.
      
      * Switch to new version of kvdb-rocksdb
      
      * Update client/db/src/utils.rs
      
      Co-Authored-By: default avatarShawn Tabrizi <[email protected]>
      eef00ea7
  27. Nov 22, 2019
    • Tomasz Drwięga's avatar
      Offchain execution extensions (#4145) · 06f6daab
      Tomasz Drwięga authored
      * Pass Extensions instead of individual objects.
      
      * Move TransactionPool to a separate ExternalitiesExtension.
      
      * Fix compilation.?
      
      * Clean up.
      
      * Refactor testing utilities.
      
      * Add docs, fix tests.
      
      * Fix doctest.
      
      * Fix formatting and add some logs.
      
      * Add some docs.
      
      * Remove unused files.
      06f6daab
  28. Nov 14, 2019
    • Benjamin Kampmann's avatar
      Reorganising the repository - external renames and moves (#4074) · f44873dc
      Benjamin Kampmann authored
      * Adding first rough ouline of the repository structure
      
      * Remove old CI stuff
      
      * add title
      
      * formatting fixes
      
      * move node-exits job's script to scripts dir
      
      * Move docs into subdir
      
      * move to bin
      
      * move maintainence scripts, configs and helpers into its own dir
      
      * add .local to ignore
      
      * move core->client
      
      * start up 'test' area
      
      * move test client
      
      * move test runtime
      
      * make test move compile
      
      * Add dependencies rule enforcement.
      
      * Fix indexing.
      
      * Update docs to reflect latest changes
      
      * Moving /srml->/paint
      
      * update docs
      
      * move client/sr-* -> primitives/
      
      * clean old readme
      
      * remove old broken code in rhd
      
      * update lock
      
      * Step 1.
      
      * starting to untangle client
      
      * Fix after merge.
      
      * start splitting out client interfaces
      
      * move children and blockchain interfaces
      
      * Move trie and state-machine to primitives.
      
      * Fix WASM builds.
      
      * fixing broken imports
      
      * more interfac...
      f44873dc