Author

Topic: [ABEE] AltSheets Block Explorer Extension - Ethereum based coins - v0.2.7 (Read 3280 times)

legendary
Activity: 902
Merit: 1001
Free trial of #AltFolio = save time, react faster
ABEESOIL 0.2.7
AltSheets Block Explorer Extension for SOILcurrency
version 0.2.7 - January 2017

http://178.62.133.174:9001

New

v0.2.7 (January 21st, 2017)
* "download as addpeers.js" on http://178.62.133.174:9001/#/util/peers
* link to (also updated) ethjsre altsheets helper tools

v0.2.6 (October 21st, 2016)
* correct block rewards after hardfork3 = 1 SOIL per block
* tests/config.html for testing the new function  mined(blockNumber)





Please send money, to support the development of this software. Every bit counts!

                       [SOIL] 0x8da4fc05ca343e6a41646194e91931d9f413a40c
                              BTC 1M4EaZVprZEmtrS3G78fMFy8yGVgdUJMXv  
legendary
Activity: 902
Merit: 1001
Free trial of #AltFolio = save time, react faster
ABEESOIL 0.2.5
AltSheets Block Explorer Extension for SOILcurrency
version 0.2.5 - August 2016

http://178.62.133.174:9001

New in v0.2.5

* Block explorer autogenerates addPeer() commands!
* New innovative function.
* Solves an old-and-frequent problem: how to add which peer nodes.
* explanations, and discussion.



Please send money, to support the development of this software. Every bit counts!

                       [SOIL] 0x8da4fc05ca343e6a41646194e91931d9f413a40c
                              BTC 1M4EaZVprZEmtrS3G78fMFy8yGVgdUJMXv  
legendary
Activity: 902
Merit: 1001
Free trial of #AltFolio = save time, react faster
ABEESOIL 0.2.4
AltSheets Block Explorer Extension for SOILcurrency
version 0.2.4 - July 2016

http://178.62.133.174:9001

New in v0.2.4

* address:
  * now also recognized if capital letters in address
  * code comments changed:
     TXs of account would need proprietary backend with all blocks database

* address of contract
  * often code is long, so now table width limited, code is wrapped
  * code length shown
  * code is shown as ASCII too
  * code is disassembled into bytecode, with ASCII conversion of PUSH bytes

* block:
  * timestamp now also shown as UTC time
  * seconds since previous block
  * gasUsed and percent of gasLimit

* transaction:
  * timestamp now also shown as UTC time
  * now also the real gasUsed
  * and correct multiplication to tx price
  * pending tx not showing unused fields anymore
  * if tx has input data, show ASCII converted
  * if tx fired log events, show number of events

* chain
  * better async for the 6 past blocks calls
  * + block time averages for the past 10 blocks


In the following examples & screenshots, I am using the SOIL FAUCET CONTRACT,
see ANN post
(there is money in that faucet, by the way). By executing
the command SOILfaucet.getSOIL.sendTransaction({from:"0x..."})
you get 0.5 SOIL sent to you.

Code at contract address
Example here is the SOIL FAUCET CONTRACT.
That contract lives at address 0xdac49860bee0e6d0775f69721459c411d62fd1bc



Note the TransactionCount 0.
In ETH, internal transactions within contracts (here `msg.sender.send(sendAmount)`
inside the `getSOIL()` function) are not registered as transactions of that account.

You can expand the 3 triangles, first to see the code as hex, and ASCII:



And also disassembled into bytecode:



Because PUSH commands sometimes contain readable strings,
for all PUSH commands I am also showing the ASCII representation
of the bytes, behind the // as comments.


Simple address

As example, the donation address for ABEESOIL (please give more, thanks)
at address 0x8da4fc05ca343e6a41646194e91931d9f413a40c



Here, the 4 outgoing transactions are accounted for.

As it is a simple address, not a contract address,
there is no code, and all other fields are suppressed.



Transaction

As example, a recent transaction to that FAUCET CONTRACT
SOILfaucet.getSOIL.sendTransaction({from:"0x..."})
0x0abd2244db18d94db716e3eedbc37ef62e65c64cca86a5f9eeb2960dd3c494f7

PENDING


While the TX was pending, only the provided default gas (90000),
and the offered gas price (50,000,000,000 Wei) can be known.
The `SOILfaucet.getSOIL()`transaction has some data input.

MINED



When the TX is mined, we can know the real gasUsed (48763),
and the transaction fee (48763 * 50gigawei = 0.00243815 SOIL).

The block time is now also shown as UTC time.

That transaction was mined in:


Block

897619



We see the gasUsed (48763), and the percentage of the limit (1.55%).

The block time is now also shown as UTC time,
and additionally, the seconds since the previous block.




Chain, Node, Blockexplorer
By clicking on the 0.2.4 at the top, you get to http://178.62.133.174:9001/#/chain/
with a lot of information. For details see older post about 0.2.3 and post about 0.2.2



Invisible changes: Worked on the asynchroneous past-blocks-queries, to make it faster.
Visible changes: Past 10 blocks.





If you like this, show it:  
                       [SOIL] 0x8da4fc05ca343e6a41646194e91931d9f413a40c
                              BTC 1M4EaZVprZEmtrS3G78fMFy8yGVgdUJMXv  

Thanks.

legendary
Activity: 902
Merit: 1001
Free trial of #AltFolio = save time, react faster


... extracts from a PM, then slightly edited ...



But the EthExplorer can not show the account balance.
Yes.

And when I started I thought: Oh that is easy. ... But in the end, I managed :-)


Quote
... to update the EthExplorer ...

It would not be an update, because by now I have changed much too many things.

It would be a completely new thing. Porting my ABEE to your clone.

Please read this whole thread to learn everything about ABEE and ABEESOIL.
TL;DR: What is on the screenshots ... is working.


PM me if you are interested that I port ABEE to your ETH clone.




Enjoy whatever you do

 Wink
legendary
Activity: 902
Merit: 1001
Free trial of #AltFolio = save time, react faster
ABEESOIL 0.2.3
AltSheets Block Explorer Extension for SOILcurrency
version 0.2.3 - December 2015

History:

v0.2.3
* /transaction/ page says "Tx Hash" now
* show transaction only if dataAvailable, otherwise
  "html: Transaction does not exist in chain up to current block", incl link to chain info
* /block/ page: show number of uncles
* block page says "Block Hash" now
* show block only if dataAvailable, otherwise
  "future block, please wait", incl link to /chain/ info
* automation improvements: getNewSource.sh (no npm restart)
* all automation .sh moved to /how-to/ folder
* copyright ABEE into every footer (by now I have modified almost all files)

v0.2.2d
* correct supply calculations for soil
* different CSS order: own stylesheet main.css overwrites bootstrap.css
* automation improvements: restartWithNewSource.sh
* average block time also for last 100,000 blocks
* link to http://altsheets.ddns.net/abee/

v0.2.2a - v0.2.2c
* December restart
* fixed error in blockInfos when future block height
* automation improvements: ipsetter.sh
* transactions in block (see above)
* ported to SOIL

Screenshots:
All screenshots are clickable and lead to larger images.


Transactions

Proper error page when transaction does not exist (yet):




Blocks

Proper error page when non-existent blocknumber:



Each block can have 0, 1, or 2 uncles included:


Try blocks 320174, 320003, 32, 58, 72, ... or find them yourself:
Code:
for (i=320000; i<330000; i++) { U=web3.eth.getBlock(i).uncles; if (U.length>0) {console.log(i, U);}; if (i%500==0) {console.log(i);}; };


Show transactions in each block:




Chain

Chain-info fully ported to soil; also show average of past 100k blocks:



The mined, and suppy numbers are identical to http://explorer.soilcoin.xyz - Calculated like this:
Code:
var	REWARD_CHANGED_AT_BLOCK = 263707,
COINS_PER_BLOCK_PHASE1 = 8,
COINS_PER_BLOCK_PHASE2 = 4,
PREMINE = 1000000;

var mined  = function(blockNumber){
var coins = 0;
if (blockNumber < REWARD_CHANGED_AT_BLOCK) {
coins = COINS_PER_BLOCK_PHASE1 * blockNumber;
}
else {
coins =  COINS_PER_BLOCK_PHASE1 * REWARD_CHANGED_AT_BLOCK;
coins += COINS_PER_BLOCK_PHASE2 * (blockNumber-REWARD_CHANGED_AT_BLOCK);
}
return coins;
}

var supply = function(blockNumber){ return PREMINE + mined(blockNumber); }

Start page

History summary, relevant links, etc:




Everything else

in version v0.2.2 see OP #1 above.


now ...



If you like this, show it:  
[SOIL] 0x8da4fc05ca343e6a41646194e91931d9f413a40c
BTC 1M4EaZVprZEmtrS3G78fMFy8yGVgdUJMXv  Thanks.

legendary
Activity: 902
Merit: 1001
Free trial of #AltFolio = save time, react faster
legendary
Activity: 902
Merit: 1001
Free trial of #AltFolio = save time, react faster
Progress!

  • ABEE will be ported to SOIL ! Together with crowdfunding, finally
    found agreement with soil&abvhiael of soilcurrency. See SOIL thread.
     
  • Upgraded to newest node.js, geth, gsoil, both Win & Linux - whew,
    all this (non-coding) stuff costs so much time ... still syncing chains.
     
  • in nodejs/angularjs I coded a clever transaction list for non-empty blocks.
    See below.



ABEE v0.2.2a

new BLOCK page with transactions!




/#/block page now contains transaction list,
and all linked to each transaction page.

 Smiley

If you like this, show it:  
[SOIL] 0x8da4fc05ca343e6a41646194e91931d9f413a40c
BTC 1M4EaZVprZEmtrS3G78fMFy8yGVgdUJMXv  Thanks.

legendary
Activity: 902
Merit: 1001
Free trial of #AltFolio = save time, react faster
tweet

I made a short url: http://2020.fm/ABEE



retweet please. Thx.

 Smiley
legendary
Activity: 902
Merit: 1001
Free trial of #AltFolio = save time, react faster
New: If you like this ... show it: BTC 1M4EaZVprZEmtrS3G78fMFy8yGVgdUJMXv
You are not into bitcoin? Here are other options: altsheets.ddns.net/give - thanks!

Thanks for supporting independent crypto projects!
legendary
Activity: 902
Merit: 1001
Free trial of #AltFolio = save time, react faster
(New?) Coefficient:
Have a long look at the center 0.6565.
Might only be me - but I had never seen that representation before.
(You know about a table with many coins? --> I do a semiscientific analysis of this coefficient)
The "Total difficulty" is the sum of all difficulties until that block.

Let's call it AltsheetsCoefficient - for now.
(Or please show me a publication/thread where it was mentioned/analyzed before.)


I have contacted people, to get my hands on that data.

From one of my answers:

Quote
I tried to find some explanations for you:

"The main branch is defined as the branch with highest total difficulty, summing the difficulties for each block in the branch."
https://en.bitcoin.it/wiki/Protocol_rules#Blocks

"The higher the total difficulty, the harder it is for an attacker to overwrite the tip of the block chain with his own blocks"
https://en.bitcoin.it/wiki/How_bitcoin_works#Bitcoin_Mining

> Isn't it something linked to ethereum-based coins?
Yes, also. But:

It is part of Satoshi's original concept.
(The above links lead to bitcoin.it)

Bitcoin has it. The 500++ clones have it. In the mining protocol.
And also newly developed coins (e.g. NXT, ETH) have it.

But as the number itself is even larger than the difficulty ... and (until now,)
most people could not really relate to it ... it is not often talked about, I guess.

Let me see...

I have no bitcoin full node (the current blocksize is too large *muahaha*), but
I have started my mintcoin wallet (which inherited the bitcoin RPC API), to try it out:

Code:
> getblockhash 1711901
722fecb384279ae7a9d2f104b98c5ad736e2d27eb5c8fb94522fcb7f78f723a2

> getblock 722fecb384279ae7a9d2f104b98c5ad736e2d27eb5c8fb94522fcb7f78f723a2
{
"hash" : "722fecb384279ae7a9d2f104b98c5ad736e2d27eb5c8fb94522fcb7f78f723a2",
"confirmations" : 722,
"size" : 409,
"height" : 1711901,
"version" : 4,
"merkleroot" : "4dc373824ffa7dde4fdc0c749399ea7f83c54f2cb12aeb156cdbfa3f3d096ae6",
"mint" : 8.49780800,
"time" : 1437260966,
"nonce" : 0,
"bits" : "1d04a8e9",
"difficulty" : 0.21459797,
"previousblockhash" : "0f5f596d77564499ecd812e7b09a3dbbcab1809e579db65f932a6c03ce5280ea",
"nextblockhash" : "1164d53f828390cecacd897537cb421729a06f22f313f35443ca34cd63832b82",
"flags" : "proof-of-stake",
"proofhash" : "0000013640e08e96495112be8117d723214103004e8ccfdd7fe948317a230221",
"entropybit" : 0,
"modifier" : "97aedb6cc43c6333",
"modifierchecksum" : "2ef5594e",
"tx" : [
"7b2b16300071c43462da7a3829133359251d93c10878d3084442896522cc4d05",
"dfa91636e591808abadafdc5395749ad4695fba4f1f0a13a23e252bba2a52532"
],
"signature" : "304402202c33e0b1c91f204e181f4ab4211d4ab8a45e23dba79f7586a77dbbdfdf17a8ce022074c0c68542de2bcbfe1342fc29e02534e8ab0d318775edd3dafca7b8df27a9cc"
}

oops. It is really not in there.

I am surprised.



So then it can only be known by summing up the whole blockchain.
i.e.

Code:
blockheight=1 # not sure if 0 or 1
breakWhenNone="nextblockhash"
printEvery=10000
difficulties={}

try:
    while true:
        blockhash  = coinRPC ("getblockhash", blockheight)
        block      = coinRPC ("getblock", blockhash)
        difficulty = block["difficulty"]
        difficulties[blockheight] = difficulty
        if (not block.has_key(breakWhenNone) or block[breakWhenNone]==""):
            break
        if blockheight % printEvery==0: print blockheight,
        blockheight += 1
except Exception as e:
    print "exception happened: %s" % e
    print "but at least we could save the results unto here:"

Now calculate the sum, show it, and save the results, to send them to me:
Code:
print
lastblock = max(difficulties.keys())
totalDiff = sum(difficulties.values())
print "Total Difficulty of Block %d is %.1f" % ( lastblock, totalDiff )

import pickle
pickle.dump(difficulties, "coinname-difficulties-%s.pickle"%blockheight) # keep, and send to AltSheets, thx !

import json
define coinRPC(command, parameter):
    answer = somehowAskTheCoinWallet ("%s %s" %(command, parameter))
    return json.loads(answer)

Of course, this is only a rough sketch. Quick.

Additionally I would probably
* catch the exception earlier - when the wallet is temporarily unwilling to answer, then wait ... repeat
* implement it threaded, to ask 1000 questions in parallel
* refine it on the way...

TL;DR:
I have had a -possibly clever- idea. For now, I call it "AltsheetsCoefficient". Scroll to the middle of my OP.
To analyze it, I would like to have a table with the "Total Difficulty" of 200+ coins:
{coin acronym: "ETH", block number: 238999, difficulty: 6405772712069, total difficulty: 1005033336244056811}

I have an instinct, that it might help us all ... to see this analysis & comparison of coins.

Anyone running many different wallets? Let's build this together!

And publish an article together about it on arxiv.org - will be interesting to see what they do with pseudonyms.

 Wink

New: If you like this ... show it: BTC 1Cn2GMp71h3Vyv8LPSTjY3RF2HekJUcmTo
You are not into bitcoin? Many other options: altsheets.ddns.net/give - thanks!
legendary
Activity: 902
Merit: 1001
Free trial of #AltFolio = save time, react faster
Version v01 of the above - ready.
Version v02 added the 50%, and full refund condition, and paid coding price.
Version v03 TOC
legendary
Activity: 902
Merit: 1001
Free trial of #AltFolio = save time, react faster
new: jump to TOC

a fork of of etherparty explorer 0.1.0:

[ABEE]


AltSheets Block Explorer Extension v0.2.2

 - for Ethereum based coins -





Most important at the beginning: This is not all my own work.
It is a fork of the new "EthExplorer (In Progress)"
(etherparty / explorer 0.1.0)

Then however much extended by AltSheets.

Portable to your Ethereum based coin.
Make a crowd funding session in your thread.
Involve your devs. Then send me a fair offer.




TOC
Part 1: New pages & functions = code created by me
           New? AltSheetsCoefficient for Total Difficulty
Part 2: Pages existing in v0.1.0 = original,
           or extended by me.
Part 3: Work in progress - simple address lookup works.
           ERFC #0001: Ethereum request for code
           My other projects.
           What's next?
You can get involved.
           Why is this useful?
           How to buy it.
"Crowd Bounty" - how to emancipate yourself from premines!!!
Funding of further development - if you like this, show it.

plus added postings
           versions of this text.
           coefficient analysis needs many coins to iterate their block chains

thx to LaudaM and ndnhc for showing me the way how to do this



What you see is what you get = study the images:


Part 1: My work

Types of pages



actually the most important message - to your community, and to coinmarketcap.
You will stay below rank 605 until you report a /supply/ function.

---



Quizz: How many times has the "on which block are we?"
question been asked in all of bitcointalk?

---



No wonder we let our computers do the work if expressing the
difficulty of last block's lottery needs such a large number.

---



Total number of coins rewarded for producing all that hot air since genesis.

---



All money there is.

---



Quote
... if the total gas consumed in the block up until this point exceeds the GASLIMIT, return an error.
(https://github.com/ethereum/wiki/wiki/White-Paper#blockchain-and-mining)

---



More information than most of you might ever want to see.
Still ... this pic is clickable.

---

(New?) Coefficient:
Have a long look at the center 0.6565.
Might only be me - but I had never seen that representation before.
(You know about a table with many coins? --> I do a semiscientific analysis of this coefficient)

The "Total difficulty" is the sum of all difficulties until that block.

The lower part queries the ethereum node about its version, and status.

Footer:

This footer is shown on all new pages contributed by AltSheets.
The links are going to /ABEE/ and /give/.

And the very bottom footer on all pages ... is the original one, and goes to fork me on github.

v0.1.0 is under MIT license, while my 0.2.2 must first generate some money now.
What kind of license is good for that?



Part 2:
Pages existing in v0.1.0


The following pages were ~ ready. I had to understand them all,
to learn how to port this to other Ethereum based-coins.

Then I made a few additions, but not many.

My main work here is the service for you - to port it.


(pic is clickable)

I added:

(previous) (next)
and
Number of Transactions.

NO: The transactions are NOT visible, nor clickable - yet.

YES: Miner's address (see below, part 3), and block number are clickable.


---


(pic is clickable)

Nothing added to the v0.1.0 original.



Part 3:
Work in progress




From what I forked had no address information at all.


As everything here (I am new to node.js) it took me long today,
to code the framework for this page - but now the beginning is done.

And you can see your balance - anyone's balance actually. That's better than nothing.

To continue might be easy, or non-trivial. Of course possible - but more eth learning necessary.
I have not yet found an easy way to just ask web3.eth for the last 10 transactions of an account -->

ERFC #0001

ERFC =ethereum-request-for-code  *lol*
The Ethereum team could please build (for all of us) an easy
web3.eth.Get_Account_Transactions(account) and
web3.eth.Get_Account_Transaction_Ids(account)
(like in NXT or HZ).

But also: Might only be me. It sure exists,
and I have simply not found out about it yet.
Only my first week with Ethereum ...


It really doesn't exist. Ethereum coders must be funny people,
to launch a coin without that function. The only API function for
addresses & transactions is getTransactionCount,
which I have included into my new address page.

---


Who?

See my beautiful

other projects

(AssetGraphs NxtHacks2015 new ready version v2,
ChainCountDown, Shareholders.py,
AssetParser, and B.E.E.f.A, and bamm.py, ...
and most of all: AltFolio, my first and most ready one.
Buy my AAsset if you believe in one of the above.)

Superbusy guy - perhaps that makes it better understandable,
that I am offering you a ported block explorer "as is",
exactly how shown in the pictures here.

Yet uncoded stuff is not part of the ABEE offer - it might or might not happen.

But of course, for 15 dollars per hour, I can code anything for you.
In my known perfectionism - precision, code comments, documentation.

What's next?
Much is possible.
A full blockexplorer like the celebrity ones ... is not done in 2 days.
Not my scope even. I might have to discontinue to work on this - IF no coin buys it.

The original goal was mainly picture #1 at the very top, plus learning how to port it.
But then my enthusiasm got the better part of me - and this is what came out.



You
can get involved:

Help to refinance my immense amount of work to get here
(which will very probably never really pay off, no illusion) ...

... and allow me to extend it further ... by launching this in your
favorite ethclone thread. Do not expect coin devs to solve all
questions for you, and at once. Get active, get some people
together - and spontaneously crowdfund (*) what you wish for:

    ... blockexplorer ... blockexplorer ... blockexplorer ...

was the one repeated outcry when I skimmed through the EXP thread.

Why and How to buy it:

And here is where my ABEE comes in. [ABEE] is NOT a replacement
of a full-fledged block explorer - that can be added in week 3, and
needs deliberation, shopping around, comparing, etc. ...

However, while the devs are superbusy in the first days, my above
ABEE can already help you a lot. And later it can be useful as a
backup block explorer. No, it is not answering all questions,
I am not promising pink unicorns. Transparency honesty fairness trust!

It is CSSed - so your designer can go wild on it :-)

To secure me, I take 50% upfront. Me failing with porting it to your coin is
VERY improbable (~ 1% probability) - in that case, I'll give the money back!

TL;DR: You get what I show above, not more. But ported to your coin NOW.

Of course, for a reasonable time, you also get extensions that
I might or might not write. All conditioned on ... earning money
with this -I feel beautiful- piece of work.

If anything is ambiguous, please ask! Really welcoming your opinion on this.






(*) crowdbounty:
= "How to emancipate yourself from premines, and still get development done --> collectively."

     (1) Mention it: "Let us buy a block explorer together."
     (2) "I pledge _.__ BTC for a block explorer, who else?"
     (3) repeat 1-2-1-2-1-2-1 ... :-) Needs a bit of holding the energy for it, but often works.
     (4) Someone says "why not also our coin?". Yes! (Now the devs might pledge some too)
     (5) The most trusted person(s) become escrows, one BTC one CLONE.
     (6) By now, you have found several options already. Vote, choose one.
     (7) And hopefully, you make me an offer, too. For ABEE. Thanks!

If deal happens, I share 5% each with the two people who had done (1) and (2) first.



How does all this sound?
Thanks a lot for your patience, and attention.


New: If you like this ... show it: BTC 1M4EaZVprZEmtrS3G78fMFy8yGVgdUJMXv
You are not into bitcoin? Here are other options: altsheets.ddns.net/give - thanks!
Jump to: