It's normally death for a company initiative. The problem is that it takes time for the rewrite to happen. While it's tempting to believe that since you wrote it once that it will be quick to write it again, usually it takes about the same amount of time to rewrite. This leads to vastly underestimating the time scale required. At the same time, the business tends to look about 6 weeks out. For those 6 weeks they are fine, but usually a "disaster" happens and you are required to make a "quick fix" to the original. "Disaster" after "disaster" happens and normally the rewrite is abandoned. Sometimes it continues, and when you finish you discover that nobody remembered about a really crucial set of requirements that are all but impossible to implement in the new system.
However, in an open source project rewrites are often successful. Sometimes it frustrates the users in the process (see GTK/Gnome/KDE rewrites) but often there is not enough pressure to kill the rewrite so it succeeds. Whether or not you'd be better off with the original is often an open question, though.
I don't know enough about Matrix/Riot to comment about whether their rewrite was a good idea. I hope they are happy with it.
I was involved in a rewrite of a ~10 year old vb app to C#. A lot of it involved rewriting the code almost line for line in C# then adding unit tests and refactoring. It took a team of 4 about 6 months for most of the work. At the end we had a solid and now much easier to maintain app that was consistent with the rest of our application suite.
Highly successful project. Sometimes a rewrite is the right choice.
However, in an open source project rewrites are often successful. Sometimes it frustrates the users in the process (see GTK/Gnome/KDE rewrites) but often there is not enough pressure to kill the rewrite so it succeeds. Whether or not you'd be better off with the original is often an open question, though.
I don't know enough about Matrix/Riot to comment about whether their rewrite was a good idea. I hope they are happy with it.