Questions tagged [block-interval]

Questions concerned with the expected or actual time between the discovery of two blocks.

Filter by
Sorted by
Tagged with
0
votes
2answers
19 views

Rinkeby not producing blocks

transactions are not getting mined on rinkeby testnet and last block time is almost 2 hours ago. How did such things happen in a decentralised network?
0
votes
1answer
22 views

Are the timestamps of blocks for Ethereum only accepted when they are monotonically increasing?

Are the timestamps of blocks for Ethereum only accepted when they are monotonically increasing? If yes, why? And why other blockchains like Bitcoin and other blockchains with shorter block time can ...
0
votes
0answers
27 views

How can I use bitcoin block stamp as seed for random number generation?

I am trying to create an ethereum based smart contract that shall generate random number. After searching around, I get to know that ethereum block stamp is vulnerable to miners hacks and false ...
1
vote
2answers
32 views

Decentralized Time server to get time in Dapps? [closed]

So basically i want to ask that how can we programmatically get the accurate, exact and current time in a DApp, without relying on the system's time or a centralized time server ? Is there a ...
2
votes
2answers
82 views

Avoid using “now”

I am using "now" to save the block timestamp details. But there is a warning to avoid its usage. If we need to avoid it what is the best alternative to it.
2
votes
1answer
39 views

What happens to immutable contracts when Ethereum 2.0 will likely change the 15s block time?

Immutable contracts that need to have a time system for handling their functions process are mostly based on block.number system. They assume there is about 15seconds between each block and thus ...
0
votes
1answer
28 views

How can I wait if it's not possible in smart contracts? [duplicate]

From my understanding, waiting in a solidity smart contract would create a total disaster for the whole Ethereum's blockchain. I can see in some circumstances that solidity offers block.timestamp ...
0
votes
1answer
20 views

Is there any library to estimate timestamp of future block?

I am in need of a library that estimates a date or some sort of timestamp when fed with a future block number (on mainnet or any major testnet). For instance, https://etherscan.io/block/countdown/...
1
vote
3answers
125 views

Increase block number on Ganache

How can we increase block.number on Ganache for testing purpose ? If not possible do you know an alternative like passing X fake transactions to artificially increase block.number. Or if we have to ...
2
votes
1answer
29 views

Known cases of miners withholding blocks when used as randomness?

There are some applications that use the blockhash as a source of randomness, often with a payout similar to a lottery. I've heard of attacks where it would be more profitable for a miner to withhold ...
1
vote
0answers
25 views

How is the block interval constrained in Ethereum 2.0

Sorry if i get any of the terminology wrong here, i'm no expert when it comes to PoS protocols. How does Ethereum 2.0 control for blocktime, typically we have the idea of a function that can be ...
0
votes
1answer
45 views

Can we freeze amount of token, amount of time with smart contract code?

Is there a smart contract code to freeze amount of token amount of time. For example i have 20 ether, with a smart contract code can i freeze it 1 year, even i can not touch it? With that code our ...
1
vote
1answer
44 views

How to test time-dependent contracts on the mainnet?

In Ganache, I use evm_mine to simulate the passage of time. Assuming block times are accurate enough, what are the best practices to test some contracts on the mainnet or a testnet which depend on ...
2
votes
1answer
18 views

Are there any EIP to speed up block times to stay competitive with other blockchains like EOS with .5 second block times?

Doing some research on EOS and it "seems" impressive or its just hyped up marketing. They have .5 second block times which I can see to be very beneficial for dapp development response times. Are ...
0
votes
1answer
32 views

Sharding: Shards with different properties?

I am currently trying to get more into sharding but there's one question I haven't found any answer to yet. Could sharding introduce shards with different properties? For example could Shard A have ...
0
votes
3answers
123 views

How to allow an account to withdraw from another one?

The goal is to create a contract which allows party B to withdraw from party A's account according to some formula. I don't want to use an escrow model, rather just to: Let A attest that they are ...
2
votes
3answers
560 views

How to get the block number which is the closest to a given timestamp?

Is there any method(ology) in web3 which allows to get the block number at a given date? In particular, I have two dates as an input and I want to effectively get all events between those two dates. ...
6
votes
1answer
47 views

What happened to the average blocktime during this period?

What happened to Ethereums blocktime from April to October last year (2017)? In the whitepaper, Vitalik said the difficulty should adjust at a maximum rate of 0.1% per block (around 100% per 12 ...
0
votes
1answer
375 views

Ethereum's block times are under 10 seconds compared to most other coins which are in minutes. Why and How?

Ethereum's blocktimes is under 10 seconds but other coins like BTC, LTC, and others are usually in minutes. How does ethereum solve the problems to why those other blocktimes are in minutes? Basically ...
1
vote
0answers
151 views

How can i increase the block number in testrpc?

I have the contract which has the dependencies on the block.number so in my javascript test cases I want block number jump. I know about the eth_mine but it will mine only the current block or work ...
2
votes
1answer
221 views

Can we just increase block gas limit and decrease block time to raise TPS? [duplicate]

Given transaction gas limit (TGL), TPS = block gas limit (BGL) / TGL / block time (BT). But we don't increase TPS by simply raising BGL and decreasing BT. What's the downside exactly? Bigger BGL leads ...
1
vote
2answers
85 views

See how long a transaction took to confirm

Given a finalized transaction, is there a way to see how long it took? Perhaps using blocks to calculate an estimate? Take this one for instance. I have been trying to calculate transaction times ...
0
votes
1answer
1k views

How can I get current time?

My project is fully based on time. Is there any way to get current time without using NOW? NOW is just returns time when block was mined and always shows "transaction will fail" when I do require(now &...
1
vote
1answer
1k views

Speed of Ethereum for real time DApp

Currently the block time is around 17s but the confirmation time is even longer around 2-3 minutes. Moreover, as I understand even if the transactions-per-second are 7 we still need to wait the ...
10
votes
2answers
2k views

What is the safest minimum block time to use without having any problem on Proof-of-Authority consensus?

On the following blog, at very last paragraph, Vitalik Buterin mentioned that: Hence, a 3-second target block time (and 5s actual block time) may be quite viable. As usual, we’ll be more ...
0
votes
1answer
48 views

Which is going to be the very last block of 2017?

I know that the last moment of the year depends in which time zone you are. But lets assume that we want the very last moment, so let's consider the last time zone (+12), I believe is Fiji or New ...
0
votes
2answers
395 views

Transactions and contract state

Imagine I have a contract that allows people to buy tokens. After some time, only one token left, but two persons try to buy this token at nearly the exact same time from the same node (a web server)....
2
votes
2answers
387 views

Why can't a blockchain process more transactions then a single node can?

I'm reading about the on-chain scalability solutions. At the moment I'm looking at sharding. Currently, in all blockchain protocols each node stores all states (account balances, contract code ...
1
vote
1answer
464 views

How reliable is it to use Block number to calculate Time in Smart contract?

I have seen contracts use block numbers to manage when the crowdsale should start and stop. How reliable is this? I understand the average time in ethereum is 17secs between blocks, but can this be ...
2
votes
1answer
894 views

Why is avg. block time growing so much latley [duplicate]

how come average block time is growing this much latley? In March it was around 14.5 and today is around 24. I know that hash rate is growing fast, but shouldn't every difficulty adjustment reset avg. ...
1
vote
0answers
58 views

Can we assume an average time to mine a block?

How safe is the assumption that, 10 years from now, it will take a certain amount of time (say, ~16s) to mine a block? If we cannot safely assume future block solving times, how else can we measure ...
0
votes
2answers
2k views

How to estimate block number at future date/time?

I am creating a smart contract that will allow actions to be taken during a specific time period. Ideally, I would like to let users know in advance the start block/end block that the contract will ...
0
votes
1answer
5k views

What is the transaction confirmation time for ERC20 based token? [duplicate]

In case of Bitcoin, it is 10 min. What is the case for ETH or ERC20 based token? And what's the confirmation time change after Casper update?
0
votes
2answers
388 views

What happens if no (unique) longest chain of blocks exists, so that the current state of Ethereum is ambigious? [duplicate]

What happens if no (unique) longest chain of blocks exists, so that the current state of Ethereum is ambigious? I know that the longest chain of blocks are always taken to be the current state of ...
1
vote
1answer
153 views

Can someone download and run a local version of my contract?

Say I have a smart contract the preforms a specific function and is used in a decryption process off-chain. Would it be possible for Molly to download the entire contract and run it on their own local ...
0
votes
2answers
81 views

Estimating days with block solving frequency: sanity check

The current block is 710908. If 212 blocks are solved per hour, then 30 days from now, we should roughly be at block 863548: 710908 + (30 * 24 * 212) = 863548 But... that's a lot bigger than 710908! ...
1
vote
2answers
1k views

How time difference can be calculated by block.number and how it is different from block.timestamp?

I have been looking into the code recently done by some developers, they are using block.number + numbers to calculate the time difference. For example if I want to lock fund for some 6 months or 180 ...
2
votes
1answer
489 views

Does block difficulty adjust with different gas limits?

Ethereum has a dynamic gas limit, a market governed by the miners. Does the block difficulty change if the gas limit is changed? For example with an increased gas limit from 3 million GAS to 6 million ...
3
votes
1answer
1k views

Once PoS and Casper is reached, what stops block times from dropping into the millisecond range?

After reading through Vlad's Casper Post, I am under the impression that Casper consensus will be reached when the validators all agree on a bit (more or less). If this is the case, why can the '...
8
votes
1answer
1k views

Ethereum's definition of difficulty and hash rate

I'm trying to make sense of geth's hashrate and Ethereum's difficulty setting. I'm running a private test net and set the difficulty to a fixed value (to big.NewInt(250)) as described by https://...
3
votes
1answer
258 views

Could I give higher priority to transactions to mined right away?

For example on Linux we can give higher priority to processes for Linux Kernel to schedule. I am the owner of my Private Ethereum Network. As an owner, could I give higher priority to deploy or mine ...
16
votes
1answer
3k views

Is Solidity block.number more secure than timestamp?

In Solidity, some properties such as block.timestamp are attackable by miners and are not (strongly) protected by the protocol. How about block.number, could a miner introduce a randomly high number? ...
3
votes
1answer
562 views

fast blocktime in private net

I need a long-running private Ethereum net (at least for 2 weeks) with fast block times. I have a single machine which is mining. When setting the difficulty very low, the block-time is very fast in ...
1
vote
0answers
35 views

Geth 1.5 Extreamly Slow to Sync on Ubuntu 16.04 LTS (Will Never Catch Up) [duplicate]

I set out to do a full geth chaindata sync on a new Ubuntu 16.04 LTS machine, and after the first 80-90% of the blockchain downloaded quite fast, the sync speed dropped considerably, to the point ...
2
votes
2answers
395 views

Why doesn't ethereum have a fast relay network like Bitcoin?

I'm talking about nodes that miners connect to that help relay blocks fast, to reduce hash power wastage and forks: http://bitcoinrelaynetwork.org/ and http://www.falcon-net.org/
5
votes
1answer
2k views

Ensuring a transaction is included in a specific block

I have been sending myself transactions back and forward between MEW and Parity trying to get a transaction included in a specific block number however I seem to be always 3 - 6 blocks behind where I ...
2
votes
1answer
97 views

Timely block times on private network

I've been working on building and testing a private ethereum network using geth and commodity AWS hardware. I'm curious if it's realistic to expect 14s block times in this case? What I see is very ...
4
votes
1answer
6k views

How to speed up transaction confirmation time?

I recently ran some tests on one of my testnet nodes and found out that my average transaction takes between 30 seconds to 2 minutes to confirm, despite the block times being at around 15 seconds. I ...
5
votes
1answer
719 views

How can we reduce the transaction time in ethereum?

I created a single node using geth --dev and tried transacting between two personal accounts using: eth.sendTransaction({from: 'first_acc', to: 'second_acc', value:web3.toWei(1, "ether")}) This ...
1
vote
1answer
845 views

What happens if the block time changes to 5 seconds?

Related to this and this. The difficulty adjustment algorithm is: block_diff = parent_diff + parent_diff // 2048 * max(1 - (block_timestamp - parent_timestamp) // 10, -99) + int(...