Skip to main content

Questions tagged [transactions]

Questions about transactions, including signed and unsigned extrinsics, transaction formats, transaction pools and constructing transactions.

Filter by
Sorted by
Tagged with
4 votes
1 answer
406 views

How the transaction payment pallet handles transaction fee of every extrinsic?

I was doing some experiments with Substrate Node Template. I found that for every extrinsic, user is charged with some fee. I explored https://github.com/paritytech/substrate/blob/master/frame/...
Boleng's user avatar
  • 523
1 vote
1 answer
75 views

Why does ImOnline use ValidateUnsigned over SignedExtension?

From ValidateUnsigned: Note that any checks done here are only used for determining the validity of the transaction for the transaction pool. During block execution phase one need to perform the same ...
Purple_Turtle's user avatar
1 vote
1 answer
94 views

Is it possible to gossip inherents?

Inherent transactions can only be inserted into a block by the block authoring node that calls them. Typically, this type of transaction is not gossiped to other nodes or stored in the transaction ...
Purple_Turtle's user avatar
2 votes
1 answer
87 views

collect tx fees from a pallet

Is there a way to send tx fees of a pallet to an account? Like transactions fees of pallet X is send to an account. We can split the global tx fees between treasury and other but we want to do it as a ...
Dubs's user avatar
  • 294
0 votes
2 answers
319 views

Create a signed transaction using a signature and unsigned_transaction

I have two functions. The first function: Generates payload of unsigned_transaction: The second function: Needs to generate a signed transaction, using unsigned_transaction and signature. Process: ...
Rusty Pythonic Script's user avatar
1 vote
1 answer
1k views

How i implement Debug for trait object [closed]

I find out 1 piece of code in substrate pub struct IsValidator(Box<dyn Fn() -> bool + Send + Sync>); How can I implement Debug for IsValidator Struct
CocDap's user avatar
  • 678
1 vote
1 answer
60 views

why does pre-dispatch in SignedExtension require you to call validate?

I am trying to understand how to develop an attack vector for when the pre-dispatch function leaves out the same checks in the validate function. Can you please help me understand what the attack ...
Yatusabes's user avatar
  • 776
0 votes
1 answer
117 views

How can I check origin in a SignedExtension?

How can I check the origin in a SignedExtension?
Yatusabes's user avatar
  • 776
0 votes
2 answers
116 views

what happens if I leave out ensure_signed from extrinsic?

What are the attack vectors of leaving out ensured_signed in one of my extrinsic? It seems that SignedExtensions already checks if the transactions are signed. When I try to submit an unsigned ...
Yatusabes's user avatar
  • 776
2 votes
1 answer
155 views

No Extrinsics/Transactions are validating and getting added to the block successfully

Extrinsic transactions are sent to the validation pool, set to ready state and then broadcasted. After this, they are re-submitted to the validation pool until it reaches its validity period (...
Jinesh Doshi's user avatar
1 vote
2 answers
86 views

Monitoring transfers and keep transfer alive

we are trying to integrate polkadot support for our exchange. Currently we want to monitor the blockchain and see if any of our address receive deposits, I am currently doing this by checking the ...
Sven's user avatar
  • 51
-1 votes
1 answer
40 views

Staking:How to build and send a staking transaction? can you give me a example?

How to build and send a staking transaction? What steps and rpc should be used ? which steps is difference between building a balance thansfer ?
Rose's user avatar
  • 305
1 vote
1 answer
62 views

How to use as_derivative function found in the Utility pallet?

I found the as_derivative() function call in the FRAME Utility pallet which suggests that I can use it to call a function from address_A on behalf of address_B, provided that address_B was made as a ...
Jorrin Bruns's user avatar
0 votes
2 answers
117 views

Collect some transfer fees before any transaction

I want to collect some transfer fee besides base, weight, length fee before user makes a transaction. Like if the base + weight + length fee = 0.1 And For every transaction I want to add additional 0....
Lovish Arora's user avatar
1 vote
1 answer
292 views

RPC-CORE: queryInfo(extrinsic: Bytes, at?: BlockHash) ... failed on weight: u64

Recently when I want to submit a transaction I receive the following failure alert, I had similar issue while getting a tx paymentInfo, which is resolved by upgrading apis, but while submitting a tx ...
Kami's user avatar
  • 537
3 votes
1 answer
77 views

How to query the max extrinsic weight over rpc?

How do i query over rpc the maximum weight for normal extrinsics as defined in frame_system here: https://github.com/paritytech/substrate/blob/master/frame/system/src/limits.rs#L99-L122
Web3 Philosopher's user avatar
1 vote
1 answer
91 views

How to preflight / preview a transaction?

Is there a way to preflight/preview a transaction before the actual signAndSend? I would like to know if a transaction would fail before letting user submit the transaction and prevent user losing gas....
KaiKang.eth's user avatar
2 votes
1 answer
209 views

Questions on transaction mortality

In the source code where transaction mortality is defined, the comments say: Create a new era based on a period (which should be a power of two between 4 and 65536 inclusive) and a block number on ...
Iker's user avatar
  • 1,356
1 vote
1 answer
91 views

Signed Extensions AdditionalSigned associated type

When reading about Signed Extensions in the transaction-format post it states that AdditionalSigned can be used to to handle any additional data to go into the signed payload. This makes it possible ...
Yatusabes's user avatar
  • 776
4 votes
1 answer
197 views

Substrate weight limits and block production

Block weight is divided between 3 different types of transaction classes: mandatory operation normal Each type has a max_total. The max_total is used so that any one type does not dominate the block....
Yatusabes's user avatar
  • 776
1 vote
1 answer
346 views

Polkadot transaction fees weight based vs. gas model e.g. Ethereum

I have been reading about Polkadot transaction fees (https://wiki.polkadot.network/docs/learn-transaction-fees) and understand at a high level the weight-based model, and that this is calculated prior ...
Ref1829's user avatar
  • 13
3 votes
2 answers
153 views

Testing transaction fee movements

I am attempting to build some tests that initiate and validate transaction fee movements. The problem is that I seem unable to initiate transaction fees in a mock runtime at all. I suspect I am ...
K. Lane's user avatar
  • 61
1 vote
0 answers
65 views

Transactions in a one-way synhronized node

Assume you submit a transaction to a Full Node which is configured incorrectly such that it can forward transactions but does not receive back results, e.g. it is working one-way Full Node x-> ...
0x5hmoo's user avatar
  • 189
1 vote
1 answer
338 views

How to query transaction details by using the transaction hash on polkadot by using python

Is there something equivalent to w3.eth.getTransaction(txHash), for Substrate based chains using python?
Shahbaz Ali's user avatar
5 votes
1 answer
346 views

How do you burn transaction fees?

For a transaction fee implementation, i would like to burn 40% of transaction fees, send 30% to treasury and 30% to collators. Which pallet do can i use to do this?
Ramsey - Decentration's user avatar
1 vote
1 answer
136 views

Substrate call raw transaction

I created a custom function in a custom RPC call to send a raw transaction : fn send_raw_transaction(&self, bytes: Bytes) -> FutureResult<TxHash<P>> { let slice = &bytes....
cibou's user avatar
  • 131
0 votes
1 answer
110 views

EVM transaction gas fees not added to the treasury

I've implemented a POA EVM-Compatible chain using the Frontier node template on branch polkadot-v0.9.22. I've Implemented a DealWithFees struct and let some part of fees be added to a treasury i've ...
Muhammad Talha Dar's user avatar
2 votes
0 answers
41 views

How do pallet and consensus model/algorithm/infrastructure work together?

Hi guys I am new to blockchain and susbtrate, so these questions would be stupid to you...But I really need some help here... How does substrate ensure anything has been done inside the pallet will ...
eggachecat's user avatar
2 votes
1 answer
73 views

How to make TransferAll transaction with txwrapper?

We want transfer the entire transferable balance with txwrapper-core. Is there a guide for this? (ex. The value needs to be empty). We make the transaction with txwrapper-core and broadcast it with ...
PaperFrog's user avatar
  • 495
0 votes
2 answers
88 views

SignedExtension Transaction Pool Deduplication

How do I remove duplications of transactions from the transaction pool? I noticed some return a tag in a signed SignedExtension TransactionValidity provides field. However, it is not clear to me how ...
Yatusabes's user avatar
  • 776
2 votes
2 answers
180 views

feeless transactions unsigned vs signed extension

I also notice that implementing feeless transaction are recommended on stack-exchange using an unsigned transactions. Why is it better to implement feeless transactions with an unsigned transaction ...
Yatusabes's user avatar
  • 776
1 vote
1 answer
148 views

Unsigned Transactions vs Signed Extensions

It seems that I can use a signed extension anywhere I can use an unsigned transaction. Can you please explain why I would implement one over the other? How does the transaction lifecycle differ? The ...
Yatusabes's user avatar
  • 776
0 votes
1 answer
123 views

"system:ExtrinsicFailed" error when submitting transactions

I'm trying to call the setName method of nicks pallet: However, when I run click "Signed" I get the error on the right, which is: system:ExtrinsicFailed [{"Module":{"index&...
Darian Foulds's user avatar
1 vote
0 answers
13 views

How do i know that from which parachain/app, a particular transaction belongs/coming from? (based on below informatino)

Looking at transaction information i want to know from which parachain it's coming ex : app.parallel.finance, astar, kapex etc etc. { specVersion: "", transactionVersion: "", ...
Jay Patel's user avatar
  • 111
2 votes
3 answers
200 views

Is it possible to make a transaction with my own account?

I'm currently trying to make a transaction using subxt tool. I could generate tx with test sr25519 keyring (Alice, Bob, ...), but I'm not sure I can do this with my account on rococo testnet. I made ...
Lewis's user avatar
  • 51
4 votes
1 answer
96 views

How many transactions with equal priority can be imported in one block?

I've been having the problem of transactions not being imported at the same block in a local network. When submitting one transaction from three nodes in a local network at the same time, those ...
Oleksandr Mykhailenko's user avatar
5 votes
1 answer
127 views

Are transaction always submitted to non-validator nodes?

Reading the Polkadot docs, I've run into the following statement: Validators should only run the Polkadot binary, and they should not listen on any port other than the configured p2p port. So far, ...
andresvsm's user avatar
  • 1,114
0 votes
1 answer
59 views

GSRPC: Check transaction failed?

Context: We are using GSRPC for interacting with a Polkadot Node. We are sending transactions using SubmitAndWatchExtrinsic. Question: How can I detect if the transaction failed? Note: I am aware ...
mpn's user avatar
  • 1
1 vote
1 answer
88 views

Cannot map Enum JSON, unable to find 'aUSD' in token in api.tx.currencies.transfer

I'm trying to transfer aUSD test token from one wallet to another on my dapp using Polkadot.js wallet. Sender's wallet is connected to Mandala TC7 test. I read this at Acala's site and I'm trying to ...
ratib90486's user avatar
4 votes
1 answer
224 views

Can't get transaction hash from signAndSend of Polkadot.js

I'm new and I'm trying to get the transaction hash but I'm only getting undefined. I used this tutorial and this and below is my code. const txHash = await polkadot.tx.balances .transfer('5F1pZe........
ratib90486's user avatar
3 votes
0 answers
103 views

Using Custom assets for transaction fees [duplicate]

I am trying to create some custom assets using pallet_assets and I want to pay the transaction fees for some extrinsics using the created custom asset. How can I achieve so ?
Eric Segall's user avatar
0 votes
1 answer
138 views

Get Transactions from wallet address in polkadot.js/api

I want to know how I can get list of transactions and transactions info for specific wallet address in polkadot.js/api, especially for kusama. const provider = new WsProvider("wss://kusama-rpc....
Heindrick's user avatar
  • 183
1 vote
2 answers
269 views

How can i set fix gas fee for all transaction in substrate?

I want to set a single fee for every transaction happening in substrate either its transfer or any other transaction I want the transfer fee to be 1 unit. Thanks
Unknown Helper's user avatar
2 votes
1 answer
65 views

How does the `TaggedTransactionQueue` runtime API know what parts of the encoded call to check?

The transaction pool regularly calls the validate_unsigned function of the SignedExtension trait to check transaction validity against current state. This trait then gets used to implement custom ...
Sacha Lansky's user avatar
  • 2,640
0 votes
1 answer
133 views

Function to see whether transaction is finalized

I am currently trying to use the javascript api to send dot between accounts and I was wondering if there was a function/way to find out whether a transaction is finalized just based off the ...
cooper jones's user avatar
1 vote
1 answer
197 views

Pre-dispatch Error

I took a look at the check-weight SignedExtention to see what happens when a block is full. It appears that it returns an error InvalidTransaction::ExhaustsResources. It think it puts it back into the ...
Yatusabes's user avatar
  • 776
1 vote
1 answer
116 views

Transaction pool and Signed Extension Pre dispatch

My understanding is that when a transaction arrives it gets validated against all signed extensions. If the transaction is valid it then moves into the ready queue or future queue depending on the ...
Yatusabes's user avatar
  • 776
0 votes
1 answer
82 views

Getting from addresses by passing transaction id or hash [duplicate]

I have few transactions and I'd like to get the from addresses of these transactions. I couldn't found anything like an API or RPC endpoint which returns from addresses. Any advice or help appreciated,...
korimusk's user avatar
1 vote
2 answers
497 views

How to send transactions using RPC?

I'm developing a client library for Dart. I wonder how can I send transactions using RPC. If I wanted to send a balance transfer only using RPC how could I do it? What are the steps? I know that I ...
Burak's user avatar
  • 903
3 votes
2 answers
77 views

get object's state after a potential transaction

Is there a way in polkadot js api to be able to get the state of an object after a transaction if it is applied in the future? Is there a way in Substrate to apply a transaction(or its past ...
cocokick's user avatar
  • 165