Workshop

Learn asyncio by writing the fastest crypto-miner!

LanguageEnglish
Audience levelIntermediate
Elevator pitch

Learn asynchronous programming by implementing Bitcoin’s mining algorithm from scratch. This hands-on workshop will teach you how to write an IRC mining bot using Python’s asyncio. You will then compete with other attendees for the fun and glory of making it the fastest in the room!

Abstract

Dive into asynchronous programming with Python’s asyncio by building a simple Bitcoin mining bot. this hands on workshop will guide you through implementing the core principles of Bitcoin’s mining algorithm. Alone or pair programming, you will create a bot that connects to a local and private IRC server and competes with others in a friendly competition to mine the most crypto-coins. The prize is eternal glory!

You’ll learn how to handle concurrency and asynchronous tasks in Python and understand to build efficient, scalable applications using Python’s asyncio. You’ll also gain insight into Bitcoin’s proof-of-work system, a fascinating concept in distributed systems that is well worth learning.

Outline:

  1. Theory: a quick introduction to Bitcoin and its mining protocol
  2. Theory: IRC networks in 5 minutes
  3. Theory: how asyncio works in Python
  4. Practice: build an IRC bot step-by-step
  5. Practice: implement Bitcoin’s mining procotol in plain Python
  6. Practice: putting it all together in a test run
  7. Competition: find ways to make computation more efficient and scalable in order to mine the most coins

Note: no real Bitcoins will be mined, of course. This workshop is about enriching our knowledge, not our wallets. You will learn how to write better and more efficient Python code while building a practical understanding of trustless systems. By the end, you’ll have a deeper understanding of how to use asynchronous programming to solve real-world problems and the skills to build your own concurrent applications. Plus, there’s a bit of fun and friendly competition to see who can make their miner the fastest!

TagsDistributed Systems, Performance and scalability techniques, Algorithms and Data Structures
Participant

Rigel Di Scala

Head of Development @ Vedrai. Very bad chess player.