Bitcoin Forum
September 24, 2018, 12:46:25 AM *
News: ♦♦ New info! Bitcoin Core users absolutely must upgrade to previously-announced 0.16.3 [Torrent]. All Bitcoin users should temporarily trust confirmations slightly less. More info.
 
   Home   Help Search Donate Login Register  
Pages: [1]
  Print  
Author Topic: Veteran programmer - Newbie BitCoin dev - questions  (Read 80 times)
roschler
Newbie
*
Offline Offline

Activity: 4
Merit: 0


View Profile
December 24, 2017, 04:38:22 PM
 #1

Hey all.  Happy Holidays.  I'm a veteran software developer, but brand new to BitCoin coding.  I'm reading Mastering BitCoin at the moment and I have a few questions:

- The book seems to favor Python, but the book is over 2 years old, a lifetime in this industry.  What is the "most favored" dev environment for BitCoin dev right now?
    + IDE? (E.g. - PyCharm for Python, or WebStorm for JS/TS, or whatever.  Doesn't have to be JetBrains, I just happen to like their stuff)
    + Programming language?  Python, JS (or TS)?, etc.

- How does the blockchain network prevent errors in the miner's calculations from corrupting the transactions?  For example, suppose a bunch of miners are using the same CPU or GPU that has a known defect in, for example, the overflow/underflow handling in the arithmetic logic units or perhaps a flaw in the transcendental functions on a GPU card, etc.?  I know a lot of miners use ASICs but I don't see why that architecture would be immune to such problems?

- Regarding smart contracts directly on the BitCoin network (i.e. - not Ethereum based), I see two projects in the field: Ivy and Rootstock.  How does Ivy relate to Rootstock if at all?

- Please list your favorite tools and tutorials.

Thanks in advance.
Advertised sites are not endorsed by the Bitcoin Forum. They may be unsafe, untrustworthy, or illegal in your jurisdiction. Advertise here.
1537749985
Hero Member
*
Offline Offline

Posts: 1537749985

View Profile Personal Message (Offline)

Ignore
1537749985
Reply with quote  #2

1537749985
Report to moderator
Coding Enthusiast
Sr. Member
****
Offline Offline

Activity: 503
Merit: 320


Novice C♯ Coder


View Profile WWW
December 24, 2017, 04:54:47 PM
 #2

the book is over 2 years old, a lifetime in this industry.

There is Mastering Bitcoin: Unlocking Digital Cryptocurrencies which is from 2014.
There is also a second edition Mastering Bitcoin: Programming the Open Blockchain which is from 2017.

Sorry the rest of your questions are out of the scope of my knowledge!

Projects List+Suggestion box
Donation link using BIP21
Bech32 Donation link!
BitcoinTransactionTool (0.9.2):  Ann - Source Code
Watch Only Bitcoin Wallet (supporting SegWit) (3.1.0):  Ann - Source Code
SharpPusher (broadcast transactions) (0.10.0): Ann - Source Code

roschler
Newbie
*
Offline Offline

Activity: 4
Merit: 0


View Profile
December 24, 2017, 04:58:33 PM
 #3

Thanks!  Need my morning coffee.  Fortunately I do have the 2017 book you mentioned, not the older 2014.  The 2014 year stuck in my head from the first search I did on Amazon for Anton's book.
nullius
Copper Member
Full Member
***
Offline Offline

Activity: 168
Merit: 757


Help! I’ve got the Pleurodelinaemia! @nym.zone


View Profile WWW
December 26, 2017, 05:25:55 AM
 #4

- The book seems to favor Python, but the book is over 2 years old, a lifetime in this industry.  What is the "most favored" dev environment for BitCoin dev right now?
    + IDE? (E.g. - PyCharm for Python, or WebStorm for JS/TS, or whatever.  Doesn't have to be JetBrains, I just happen to like their stuff)
    + Programming language?  Python, JS (or TS)?, etc.

I have no idea.  I’m a C programmer; and I prefer to write code in vi(1).  Not “Vim”.  nvi.

The best language for writing Bitcoin-related code is C the language at which you yourself most excel.  Well, as long as it’s not COBOL, MUMPS, or BF, I suppose.

- How does the blockchain network prevent errors in the miner's calculations from corrupting the transactions?  For example, suppose a bunch of miners are using the same CPU or GPU that has a known defect in, for example, the overflow/underflow handling in the arithmetic logic units or perhaps a flaw in the transcendental functions on a GPU card, etc.?  I know a lot of miners use ASICs but I don't see why that architecture would be immune to such problems?

There is a common misconception that miners provide the security of the network.  This is patently false.  Miners have exactly one job:  To provide Byzantine fault-tolerant ordering of transactions, thus preventing double-spends.  It is a valuable and resource-intensive job; and that is why they get paid for it.  But it is still only one function in a machine with many moving parts.

This ACM Queue article provides an excellent overview of how Bitcoin fits together against the backdrop of decades of academic research.  As its centre, it explains how Satoshi Nakamoto repurposed Adam Back’s HashCash to create the first-ever practical implementation of a Byzantine fault-tolerant decentralized database with excellent Sybil resistance.  That is the purpose of mining, and its only purpose.

Validation security is provided by full nodes.  Each individual full node provides validation security for its owner; and all full nodes collectively enforce the consensus rule validation security of the entire network.  Thus here as everywhere else, Bitcoin aligns the individual’s selfish interest with the common good:  People who want the highest security will run a full node to secure themselves, and thus help secure everybody else, also.

In the scenario you describe, I do expect that hashing and signature validation would catch the errors; and the block containing corrupted transactions would be discarded by full nodes as if it had never existed.  A full node does not blindly follow “the longest chain”, as you may have heard:  Rather, a full node follows the independently validated and fully valid chain with the highest total proof-of-work.

This also applies to malicious mining of deliberately corrupted transactions, attempted thefts, ridiculously huge blocks, etc.  Sometimes you may see nonsensical FUD claiming that miners could seize money by planting theft transactions in blocks, e.g. by ignoring Segwit validation rules; no, they would get exactly the same result as if they filled blocks with the output of /dev/random.

- Regarding smart contracts directly on the BitCoin network (i.e. - not Ethereum based), I see two projects in the field: Ivy and Rootstock.  How does Ivy relate to Rootstock if at all?

I have not been following development of those lately, so I can’t say.

If you are interested in smart contracts, you may appreciate a peek at current R&D which may potentially someday become the future of Bitcoin smart contracts:  Simplicity (PDF).  Powerfully expressive smart contracts written with in a formally verifiable DSL, running on a formally verified VM, would have none of the exploding clown car disasters inevitably resulting from the stupidity of bolting a Turing-complete VM onto a blockchain.

- Please list your favorite tools and tutorials.

Tools depend on what job you need done; and I don’t really know any good tutorials off the top of my head.  But here are some educational links:


HTH.

roschler
Newbie
*
Offline Offline

Activity: 4
Merit: 0


View Profile
December 26, 2017, 10:07:47 AM
 #5

Thanks nullius.  I hope somebody soon clarifies the non-Ethereum smart contract choices like Simplicity, Ivy, and Rootstock soon.  It's hard to know where to put your programming effort these days.  I'll read the Simplicity PDF and see what it offers.

roschler
Pages: [1]
  Print  
 
Jump to:  

Sponsored by , a Bitcoin-accepting VPN.
Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2006-2009, Simple Machines Valid XHTML 1.0! Valid CSS!