4 ms·
How to send $ETH in 19 lines of Python
- sorenrood 5y agoI wrote a Replit tutorial on sending Ethererum from wallet to wallet in Python. It takes only 19 lines of code and is super easy to set up!
- iso8859-1 5y agoHow do you test it? I'd like to test without depending on some remote service, which could be unreliable.
- anotha1 5y agoTell me how to do something worth doing with ETH and I'll be impressed. Cue the intellectualization from "investors."
- vmception 5y agoIs there anything you would like to do that you need ETH for? Are you looking for inspiration or are you looking to talk about use cases that you will never be in the market for?
- anotha1 5y agoI mean, I've learned enough to have plenty of ideas for "how to use ETH" but nothing makes the cut. NFTs are **. DAO is too grandiose, especially to be hosted on ETH. And that leads to my comment.
- vmception 5y agookay, there is a robust repurchase agreement (repo) market on the Ethereum network that allows for anyone to enter the repo market to settle trades of practically unlimited sizes. before last year this was exclusively the domain of investments banks given the privilege of using the Federal Reserve's overnight repo market. Where the Federal Reserve would provide hundreds of billions of liquidity and destroy it at the end of the trade, allowing the banks to use credit to finish deals overnight. in the Ethereum network anyone is allowed to use this, it is called "flash loans" in that market, and as always, writing any transaction on the Ethereum network requires the use of ETH, the native fuel necessary to commit transaction to the state machine and save the state. flash loans = repo market the difference being that on the Ethereum network, people borrow from liquidity pools, instead of newly created dollars like when a central bank is involved. this has much greater accountability and confidence. the transactions are executed in one block, if it is not possible for the operation to return capital to the liquidity pool then the transaction fails and it was never executed, but the person that attempted it still pays the transaction fee in ETH as the nodes still did use compute time. Ether is just necessary to access compute nodes on the Ethereum network - specifically to write, as reading is free - no different than dollars are necessary to access compute nodes on the AWS Lambda network. Its not that complicated. If you don't need to write to compute nodes, and you are also not providing collateral to liquidity pools, then you don't need Ether.
- anotha1 5y agoIn this perfect new world do bad decisions also haunt you forever? Like student loan debt, your ETH reputation will follow you through bankruptcy (but obviously crypto-vestors are all too financially savvy to worry about that).
- nootropicat 5y agoMaking insane yield (50%-300% apr, depending on the time) on dollars
- anotha1 5y ago"That's what Bernie Madoff said." But for real, that doesn't make the cut. 1) maybe I don't have capital to invest, 2) your "yield" calculation ignores all risk.
- spellboots 5y agoIt sounds like you have some additional constraints that you didn't make clear in your original question. You said, "Tell me how to do something worth doing with ETH and I'll be impressed." Also, you need things that you can do without capital, and that fit a specific risk profile that you haven't elaborated on. It sounds like you're assuming that making these yields are too risky for you, so are you looking for zero risk, or can you accept some risk? Can you specify up front your constraints? Here are two things you could do with ETH right now: 1. You could use it as the coordination layer for a decentralised git repository, that is fully distributed and censorship resistant. Hopefully you can see how this could easily be adapted to many similar use cases: https://github.com/cardstack/githereum https://github.com/cardstack/githereum 2. You could purchase flight delay insurance that pays out automatically if your flight is delayed: https://etherisc.com/ https://etherisc.com/ > Cue the intellectualization from "investors." Cue the moving of the goalposts
- Shish2k 5y agoThat’s exactly the problem for me: I’m the kind of person who sees money as “a token to be traded for goods and / or services”, and why would any normal person (ie, not counting crypto investment nerds) want to trade their eth if the most profitable thing to do is to hoard it?
- ptudan 5y agoWhy do you buy things when you could only ever save?
- jtsiskin 5y agoDoes programmatic money not sound exciting to you? I see way more skepticism than support on HN but it surprises me. Can you really not picture any uses for a financial system with Turing completeness?
- anotha1 5y agoI've been playing with programmatic money since selling runescape gold for PayPal dollars. I guess I just need more idk
- zionic 5y agoHuh? That's not what "programmatic money" means. You're confusing it with digital currency. Programmatic money means you can define code/program with the money itself. In a trivial case I could easily program the money (called a smart contract) to pay you $1 every day. I could put $1000 in that contract and you could have near-total confidence of that payout schedule. The code itself is a property of that money, and its execution is enforced by the same system that secures the overall ledger.
- anotha1 5y agoIncorrect. You're confusing "enough trust to make the world go around" with "so trustworthy we're neglecting that it's bad for the world." And I mean the latter more in terms of the brain drain than ecologically, which ironically may not get solved because of that brain drain.
- echelon 5y agoThe government needs to be in control of the money supply. Monetary and fiscal policy are important levers for maintaining the health of our economy. The government uses money to bolster trade, issue debt, maintain a high standard of living, etc. Crypto is a bunch of investors and engineers that think that they should be in charge rather than our elected governments. It's not even a geniocracy since it rewards only early investors. It's an oligarchy of the lucky few that think they should have more leverage than governments and the populace. It disenfranchises the government's ability to help the poor, underserved, and disadvantaged. Crypto not from the government is dangerous. I predict that as this plays out more governments will move to shut it down.
- the_local_host 5y agoReceive ETH, and turn it into dollars. Tutorials should focus on getting money, not sending it out, if they want to get people's interest.
- anotha1 5y agoFound one! This right here is worth doing. Thank you.
- aclatuts 5y agoWhen I was buying ethereum at 17 dollars and getting a mortgage. I was buying it hoping sometime in the future I could renew the mortgage with an ethereum contract. It could detail in code the principal, functions to trigger interest rate increases/decreases, functions to cancel, early termination fees, payment addresses, max payments per year, end dates, and whatever else a mortgage contract would need. As a developer I would have felt much more comfortable with that than legal papers, brochures and pamphlets.
- anotha1 5y ago> buying ethereum at 17 dollars Not so humble brag... *Back to reading* Yeah, recently bought a place and yes, the process is hostile to the consumer (200 pages of legal sized dense contract, give me a break). However, did you ever think that there could be a, you know, simpler solution than, say, CRYPTOGRAPHY LOL PS: cash-out now if you want to humble brag after ******* happens!
- zionic 5y agoWhat do you define as "worth doing"? DeFi alone has tons of potential answers to that question. Then there's decentralized exchanges... or do you not think decentralized currency exchange is "worth doing"?
- anotha1 5y agoYes, please screw the rich guys taking tolls on exchanges. This can be done way simpler and more efficiently without ETH.
- ptudan 5y agoYes trustless and distributed things have no value, crypto is stupid, BTC is a waste of energy, yada yada yada.
- anotha1 5y agoI never said no-value. And my opinion on the valuation is no better than yours. I'm seriously wondering how many things you did this year where you were like "damn, I sure wish this were decentralized and cryptographically secure, yeah, that would make this 10X better for sure, yeah!"
- ptudan 5y agoI'm not looking for a 10x improvement, I'm thinking of getting closer to the ideal. So many things are hidden behind layers of obfuscation and forced trust (authority). If society as a whole put many of these functions on chain, at least the hiding would go away. Long term, I'd love to see fully open implementations of the justice system, education, political donations, property/ip rights, DNS, adtech, on the chain. I don't care if they make money, I'm not saying there are riches here. But I for one would have loved blind grading that is verifiably blind, when I was in school. Teachers had too much arbitrary power. I also would love to earn from my own advertising data, and willingly be able to give it to sites. I could keep going. Blockchains are obviously a buzzword, and the current crypto hype isn't without plenty of scams. But revolutions don't occur in days or weeks. The push towards trustless and decentralized systems is happening right now, and in my opinion, benefits society. It could take decades to replace systems currently in place.
- teawrecks 5y agoMore like, cue the crypto critics. There are a million and one places to talk about the veracity of cryptocurrency. This thread doesn't seem like one of those places.
- anotha1 5y agoToo late, and those other places are not where I am so
- xadhominemx 5y agoIt’s useful as a means to trade even scammier coins. Not so much beyond that.
- anotha1 5y agoI guess that's "worth it" for some people here. The joke is, those people already missed out. "Crypto", no way that moniker lasts, is already in the greedy phase. Stay back, especially if those crypto dreams include money you shouldn't gamble with (student loans, seriously, don't do it).
- sbassi 5y agoThis is misleading, the code doesn't send the $ETH, it's calling a third party API (infura) to do it
- ofek 5y agoPretty neat! I wrote and now co-maintain a library that has similar ease-of-use for Bitcoin: https://github.com/ofek/bit https://github.com/ofek/bit Even fewer LoC :)
- RKearney 5y agoI wish the software engineering community would stop with the click-bait headlines. Write a game in 2 lines of Python: import MonolithicGameSDK MonolithicGameSDK.run()
- f38zf5vdt 5y ago201X+ headlines in general. Title should be changed to "I imported a python library and used it without throwing an Exception, and so can you!"
- secondcoming 5y agoClick-bait Headlines Considered Harmful
- mjfl 5y agoWith geth you can do it in 2 lines
- agumonkey 5y agowait, replit doesn't have memberless repls ? how much did it change since the last year..
- willio58 5y agoIs there any word on if browsers (chrome, firefox, or safari) will support crypocurrency transactions so I don't have to download a 3rd party plugin?
- sickygnar 5y agobrave is bundled with metamask. its not technically native, but it works very nicely.
- deleted 5y ago[deleted]
- zionic 5y agoIs there a good replacement for hackernews? The crypto-skepticism that derails every single thread even tangentially related to crypto currency has totally undermined my desire to participate in this community. It appears the "hackers" have moved on.
- deleted 5y ago[deleted]
- zenlot 5y agoYes, it's called lobste.rs. Yet they started suffering from the same 'too sensitive SF crowd lenses', where they see the world with their very narrow view and anything that's not in their narrow space - will be of course downvoted. I kinda miss old groups where you would be able to read "not so popular" comments, without damaging your eyes due to them being greyed out, or without a need to select it to see the text. HN crowd is very specific, in a bad way.
- ASalazarMX 5y agoLobste.rs is a club where the bouncers are extremely selective over who is allowed to come in and partake, only to find most tables are empty.
- dang 5y agoIf you click on the timestamp of a downvoted comment, it should go to a page where the text is fully readable. Yes it's an extra hop, but that's a small price to pay for an immune system.
- ASalazarMX 5y agoThat's because many of us are skeptical of the current cryptohype. I'm sure many innovative things will come out of all these experiments, but right now, it feels like many people are taking the opportunity to con other people into using real money to buy their virtual money brand. If you want a cryptocurrency-friendly forum, the r/CryptoCurrency subreddit would be ideal.
- reph2097 5y agoYeah, right. Sending my private key straight to $thirdparty.
- vmception 5y agoThis doesn't do that, but okay, there are other criticisms to be had of this article
- joshsyn 5y agoStupid