markdown_formatter returns 'common_mark' only when text_formatting is common_mark, and 'markdown' otherwise. For example, when you attach an markdown.md file and preview it in an environment where text_formatting is Textile, the contents of the file are converted to HTML by RedCarpet('markdown').
Since RedCarpet('markdown') was deprecated in #36807, why not change markdown_formatter to return 'markdown' only when text_formatting is markdown and 'cmmon_mark' otherwise?
Subject changed from Change the default for markdown_formatter from markdown to common_mark to Use Commonmarker instead of Redcarpet by default when rendering Markdown attachments