First reported here by haylem.
Steps to reproduce:
Construct a post consisting of exactly 30,000 non-markup characters (no HTML or Markdown formatting). Here's one for you: Formatting Sandbox
Edit it to add some more non-markup text. For instance, a period at the end.
Try to submit the edit. Note the error:
Reverting your previous edit, make a new one consisting only of markup. Bold a word, or add a link:
Submit this edit, and note that while the text submitted is now even longer than in #3, the edit is accepted. But the post is truncated at 30000 characters:
This is really the worst of both worlds: the editor isn't forced to limit his text, but the text itself is cut or mangled to some degree (chopping off the link table found at the end of long, well-referenced posts is particularly cruel).
I suspect this behavior was introduced with the recent change to validate minimum length after first stripping markup. That behavior is good - it ensures the spirit of the minimum length check is preserved by disallowing markup tricks and excessive linking to subvert it.
Recommended solution
For ease of use, the maximum length check should be done prior to stripping HTML, thus preserving the (relatively) friendly warnings instead of the (extremely) unfriendly truncation.
Alternately, the truncation behavior could be removed entirely, allowing 30000 displayed characters and however much markup is desired.