Questions tagged [substrate]

Substrate is a framework for blockchain prototyping and development written in Rust. General questions about Substrate should be asked on https://substrate.stackexchange.com

Substrate is a framework for prototyping and development written in . At its heart, Substrate is a combination of three technologies: , and AfG Consensus. It is both a library for building new blockchains and a skeleton key of a blockchain client, able to synchronize to any Substrate-based chain.

Substrate chains have three distinct features that make them next-generation: a dynamic, self-defining state-transition function (STF), light-client functionality from day one and a progressive consensus algorithm with fast block production and adaptive, definite finality.

The STF, encoded in WebAssembly, is known as the runtime. This defines the execute_block function and can specify everything from the staking algorithm, transaction semantics, logging mechanisms and procedures for replacing any aspect of itself or of the blockchain’s state (governance). Because the runtime is entirely dynamic, all of these can be switched out or upgraded at any time. A Substrate chain is very much a living organism.

587 questions
-1
votes
1 answer

Collecting transaction fees and store it in pot

Want to collect a higher transaction fee (5%) during the use of transfer and store it in a pot account? How can I do that? Will I have to modify the transfer function of balance…
Amiya Behera
  • 2,210
  • 19
  • 32
-1
votes
1 answer

when use docker-compose to launch mysql, I met the problem "Unable to load '/usr/share/zoneinfo/****** as time zone"

https://i.stack.imgur.com/8E8fX.png (this is the link to the screenshot). I want to use https://github.com/polkascan/polkascan-os.git to launch a block exploer. But As the picture shows, I met the warnning "Unable to load '/usr/share/zoneinfo/******…
peilin
  • 23
  • 5
-1
votes
2 answers

multiple applicable items in scope

I'm using Ubuntu 20.04.2.0-desktop-amd64 , Substrate 3.0.0 Version: gh@ubuntu:~$ rustup show Default host: x86_64-unknown-linux-gnu rustup home: /home/gh/.rustup installed toolchains -------------------- stable-x86_64-unknown-linux-gnu…
ggghhh
  • 31
  • 1
  • 4
-1
votes
2 answers

How to create a substraste chain?

I need HELP I have two major errors in creating my first substraste chain (cf. https://substrate.dev/docs/en/tutorials/create-your-first-substrate-chain/setup) Error in Installing the Front-End…
-1
votes
1 answer

What is the right way to use ink3 | self.env().block_timestamp() | Test Error :: 'uninitialized execution context: UninitializedBlocks'

What is the right way to use ink3 "self.env().block_timestamp()" Reference code snippet ( full code is @ https://gist.github.com/shamb0/a1f24cd7981e169cc5b7d1e1b3ec4dd4 ) pub fn get_bts(&self) -> u64 { let bts =…
shamb0
  • 21
  • 3
-1
votes
3 answers

Substrate Blockchain - Create First Blockchain FrontEnd doesn´t open

I am on the first tutorial of Substrate, running substrate on Windows Subsystem for Linux. The substrate network is running correctly, but when I open the frontend on the browser i get this erros:
Mvrocha
  • 393
  • 3
  • 14
-1
votes
2 answers

mismatched types in Pallet

The error is shown when i follow step to expose the contracts pallet api. https://substrate.dev/docs/en/tutorials/add-a-pallet-to-your-runtime/#install-the-node-template I followed the steps all the way and fixed another error that was associating…
-1
votes
1 answer

Substrate Kitties: Module not showing as extrinsic

I am following the Substrate Kitties tutorial. I added a map & compiled. no errors. but when I look for the module in extrinsic app, I don't see it. I am running the build.sh, then cargo build release, then starting the node after using…
Mahesh
  • 1
-1
votes
1 answer

How do one store data in a block?

My use case is very simple. I want to create a chain where peers can store some public data. What is the best way to accomplish that in Substrate? I think I should implement a custom run time for that, but I'm not sure how to create a transaction…
user7699384
-1
votes
1 answer

Unable to compile node-runtime

I am unable to compile node-runtime on the substrate v1.0 branch (as part of running ./scripts/build.sh from the substrate git repo base directory as per the installation instructions). The error I get is: error: cannot find macro proc_macro_call!…
hbakkum
  • 73
  • 2
  • 6
-2
votes
1 answer

Error while compiling the substrate-node-template on windows vscode

error: failed to write bytecode to…
Kifal
  • 5
  • 2
-2
votes
3 answers

Fatal cannot lock ref / Permission denied in Git

Reviewed related articles on SO with no success. I'm on macOS: Installed Rust OK: rustup update nightly rustup update stable rustup target add wasm32-unknown-unknown --toolchain nightly Then installed this: XX-MacBook-Air-2 substrate-node-template…
Mountaineer
  • 7
  • 1
  • 2
-2
votes
1 answer

build substrate pallet get the following fault, how to resolve it?

error[E0282]: type annotations needed --> /Users/apple/.cargo/registry/src/github.com-1ecc6299db9ec823/sp-arithmetic-2.0.0/src/fixed_point.rs:541:9 | 541 | let accuracy = P::ACCURACY.saturated_into(); | …
huanghe73
  • 7
  • 1
-3
votes
1 answer

Could not convert parameter `tx` between node and runtime: Could not decode `Call::Assets.0`:Could not decode

Execution failed: ApiError("Could not convert parameter `tx` between node and runtime: Could not decode `Call::Assets.0`:\n\tCould not decode `Call::create.3`:\n\t\tNot enough data to fill buffer\n") Runtime Implementation In Substrate node…
-3
votes
1 answer

Is there any module in substrate framework to add native code to pallet

I am new to substrate and I am working on a project (in substrate) and as per the requirement I have to store the map key and value on a external database and to do so I chosen mongodb but I don't know how to implement it in runtime. or there are…
1 2 3
39
40