Settle positions between two mutually non cooperating parties. Your github solution doesn't consider that many non cooperating parties may want to do conflicting things on chain and you need a trustless way to resolve those conflicts. First writer wins to a centralized database at github is not an acceptable settlement method for billion dollar transactions.
EDIT: A blockchain is not just about keeping a history, it's also about maintaining liveness of the chain and preventing censorship even when many non cooperating parties are involved with conflicting incentives.
you don't need a trustless way - the two mutually non cooperating parties could fork the repo, reconcile separately using traditional git tools and then have the new commit(s), representing the conflict, merged into the main branch.
this is literally already what happens with software development now.
This is how I view the handling of the "well what about complex transactions..." game. You can create a totally separate branch to process that complex beast and then attempt to merge it back into the main. If there is a merge conflict (someone debited/credited the account line between branch & merge operation), the transaction would be aborted. Rebasing of transactions on top of the main branch would be possible and the semantics of this even make sense for real world use cases - "We attempted to reconcile your transaction into the main flow, but there was a change in the circumstances of the various basis accounts. Can you rebase your transactions on these circumstances and resubmit?" As part of that rebase operation, you would re-run your biz constraints on the complex transaction and then resubmit if you could still satisfy them all.
Depending on how you use and understand git for software, it is either a hauntingly-similar facsimile of any arbitrary blockchain tech today, or a completely alien technology with no practical relationship to blockchain whatsoever.
There also seems to be some notion that the time domain must flow in a continuous way. The time domain in git is discrete, but this does not violate any of the semantics. Just hypothetical processes around them.
these are transactions with extremely high value and often extremely urgent and not possible to merge together - e.g. the both liquidate the same unhealthy loan position (could be worth ~$10m+)
the whole point is it's not remotely easy to just "reconcile separately" when you have two mutually exclusive financial operations - these are not code changes made by mutually cooperating developers happy to change their code to resolve merge conflicts, they are actively fighting against each other
edit: this also point out how having a centralized entity decide the ordering of transactions is a horrible idea - sequencing is worth enormous amounts of money and you could not be trusted to resolve transactions in a way that is sometimes against your interests but in the interest of other participants in the network
outside of trivial transfer transactions there are much more complicated things you can do with smart contracts such as decentralized lending and decentralized exchange of assets
these are more like arbitrary atomic changes to on chain state that can affect many wallets and different contracts (and depend on the existing state) rather than just a transfer from my wallet to another address, which can be reordered freely
see protocols such as uniswap, compound, aave, synthetix, sushiswap, liquity, etc.
Yeah I'm confused here. I think the "clicking" in previous posts refers to using the mouse to position the cursor within a group of spaces/tabs. I don't use a mouse in my text editor so it took me a while to grasp.
The time-value still comes into play in the form of eth transaction fee. If you're flash loaning to take advantage of an open arbitrage opportunity there will be other parties trying to take advantage of it, so you will pay more to get your transaction in before theirs.
For a lot of transactions like this its actually miners who can detect and rewrite these transactions to take advantage of the arbitrage opportunities first, for this reason this cost is called "miner extractable value" or MEV.
However, note this fee doesn't accrue to the lender!
Personally, I've developed a strong preference for putting this type of information as close to the affected code as possible. Immediately next to the affected code is the only place these types of comments have a prayer of being kept up to date. Keeping them in another document, a commit message, or anything similar just results in the content of the message instantly going out of date.
People who bother to complain are those who actually care about your thing. People who do not care simply leave without ever telling you why. Your complainers are often your most dedicated and invested users.
Though in this specific case, my sense has been that your complainers are often your most dedicated and invested users of a version of the language that was officially retired 38 days ago.
Python is just bizarrely political. I suspect that it's now cursed for all time to have every future PEP become a battle in a proxy war over PEP 3000.
Thunk is not a proper solution to the problem - it's a totally open escape hatch! You lose ALL the nice guarantees and behavior of redux when "action" no longer means "immutable, serializable event" and starts meaning "completely arbitrary function call with unbounded async effects."
There's no functional difference between using redux-thunk and just calling a "global" `dispatch` in random callbacks; both are equally unmaintainable in the face of interacting effects.
EDIT: Having a bunch of complex async logic all modifying your store in overlapping ways without careful coordination is like having concurrent operations on your database without any transactions or locking.
Actions are _still_ always an "immutable serializable event". The async logic is going to live _somewhere_, either in your components, or outside of them. Thunks are a way to move that logic outside of your components. The end result of the async logic is still dispatching plain object actions.
One of the many difference is that there is no inheritance, and implementations of traits can be added for types long after they are defined. Traits in rust are not like java interfaces.
It wasn't my example, but it's just disproving the notion that FP somehow means you need to write big if statements to dispatch your functions.
Traits are not functional-language specific except in that they are often used in FP to solve problems similar to those one might use inheritance to solve in OOP.
I still don't know how to get it to do exactly what I want. There is far too much magic involved, and experience has long demonstrated that magic is bad (Webpack confirms that belief).
That being said, the concept of defining a function in, essentially, a config file seems like a step in the right direction. I don't think I'd trust that functionality outside of builds or infra-as-code, though.
What's magic about webpack? The online documentation provides quite a lot of insight into how it all fits together.
It probably only seems like magic because you didn't build a fundamental understanding of how it works before using it. I use some massive webpack configurations and I understand them all quite thoroughly thanks to well-written, modularized configuration files.
Javascript is a scripting language without native module support. That isn't Webpack's fault.
Webpack also handles much, much more than just Javascript. It handles CSS, HTML, images, files, pretty much any kind of asset. Java/Scala doesn't have anything like that. Asset management is completely different due to the nature of how assets are transferred to the client.
And Android? Give me a break. The moment you stray from the strict layout of an Android app you run into a wall and have to learn how Gradle operates. This strict layout is good for some but others hate when an environment forces particular constraints upon them.
Webpack is completely configurable at every stage, works with plugins (which compilers don't do) and again, isn't magic. Not knowing how something works doesn't make it magic. That's not what magic means with respect to code.
Besides... Maybe if you just like getting by, you can program in C/Java/etc without learning about compilers. Web dev is fucked and transpiler knowledge is basically required, but sure you can get by in other domains without it. But if you want to be a good programmer, an expert at what you do, someone who lives and breathes and understands computer science, someone who will excel in his career and not remain a code monkey forever... You have to learn about how your compilers work just like you should know how the silicon in your computer is doing its own "magic".
It was very successful. Complicated projects require complicated build config. Parcel does fine for simple projects, but lacks the raw power & configurability of webpack.
Webpack now does simple config as well with the 'mode: "production"' and 'mode: "development"' presets.
This approach necessitates an ever growing number of increasingly specific APIs, or an ever growing set of flags and options which will inevitably approximate a poorly implemented version of GraphQL.
EDIT: A blockchain is not just about keeping a history, it's also about maintaining liveness of the chain and preventing censorship even when many non cooperating parties are involved with conflicting incentives.