Comments (2)
The root of the empty trie is a 0_256 (i.e. a 32-byte 'hash' of zeros).
From the YP:
The empty trie is defined as being a 256-bit hash of zeroes,
Trie roots are allowed to be deep (and there are several real examples of
this), but the empty trie has, since
ethereum/aleth@4aa0c71
been
defined as the zeroed hash.
This means all nodes are either 2 or 17 items; never zero.
Never put down to incompetence that which can be adequately explained by
self-interest.
On 13 May 2014 14:04, heikoheiko [email protected] wrote:
currently we don't get compatibility with the cpp client. the state.roots
after adding the premine accounts differ. I tried to isolate the problem:
https://github.com/ethereum/pyethereum/blob/master/tests/test_chain.py#L88from the YP it looks like empty trie roots would be represented as
'\x00'*32 in the cpp client. if so it would not match the empty string
that we use.
- Comment by Vitalik Buterin: that's wrong, trie roots are allowed to
be either empty or even deep arrays (though that should never happen in
practice)YP: https://raw.githubusercontent.com/ethereum/latexpaper/master/Paper.tex
0256 , SHA3RLP(), 0160 , stateRoot, 0256 , 2**22 , 0, 0, 1000000, 0, 0,
(), SHA3(42), (), ()Where 0256 refers to the parent and state and transaction root hashes, a
256-bit hash which is all zeroes; and the implementation looks like it
would implement it just like this:
https://github.com/ethereum/cpp-ethereum/libethereum/BlockInfo.cpp#L64h256() << sha3EmptyList << h160() << stateRoot << h256() <<
c_genesisDifficulty << 0 << 0 << 1000000 << 0 << (uint)0 << string() <<
sha3(bytes(1, 42));also the default for an account looks different in cpp
['', '', h256(), sha3('')] rather than ['', '', '', ''] currently in
pyethereum.—
Reply to this email directly or view it on GitHubhttps://github.com//issues/91
.
from pyethereum.
thanks. see #92
from pyethereum.
Related Issues (20)
- pyethereum depends on some python3-only packages HOT 5
- indicate ValueError: No matching functions found when call function contained in abi json file
- ImportError: cannot import name 'ALL_BYTES' HOT 15
- E TypeError: decode_hex() takes 1 positional argument but 2 were given
- pip install ethereum failed HOT 5
- RuntimeError: Format missing, but need one (identified source as text as no file with that name was found). HOT 1
- Broken argument positions cause method to repeat almost infinitely HOT 1
- Question: How do i get the raw txid to broadcast to jsonRPC using "eth_sendRawTransaction" method
- bitcoin import conflicts with python-bitcoinlib HOT 1
- Installing pye on windows
- Create doc section for `Installation`
- pip install ethereum failed on Windows 10 HOT 4
- .
- test_blocks.py throwing many errors
- How to call a function in smart contract by using tester.py
- Cannot install via pipenv HOT 1
- The new opcodes introduced in Constantinople are not supported
- Gonzalez950
- Error on building wheel for pyethash HOT 3
- Technical papers
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from pyethereum.