> There have been various attempts to replace general purpose text-based languages (such as C++ or Python) with visual programming. I don't think any of them have been very successful.
Their lack of success can have many reasons other than their general umfitness. IMO, their lack of success has much more to do with the ubiquity of text oriented tools. The breadth of tools and platforms a new programming paradigm would habe to support to truly be a replacement technology for text is staggering.
> You end up with massive spaghetti diagrams.
That's a matter of code quality which is a problem in text code too. Who hasn't encounter a codebase of many multi-thousand line C++ files. Who hasn't encountered an inheritance tree where various levels of the tree partially implement the interface and therefore results in code which bounces up and down the tree executing at all levels of the inheritance.
Generally, I find that most arguments favoring Text over visual programming are cart before the horse type arguments of the form "this feature is better in text". Usually that thing is better in text because we've had the time to make it better. The tools and platforms are mature not intrinsically superior. Text code is "clean" because we have used it long enough to understand what is "good" code quality. Text code is "durable" because we've made text standards and rendering ubiquitous across all platforms. And so on.