I'm not sure whether /usr/share/debconf/frontend is supposed to produce any output or not. This is why I'm no big fans of using all these debconf stuff, as it's hard to debug or even understand what's exactly going on .
dietpi@DietPi:~$ sudo perl -w -d /usr/share/debconf/frontend /var/lib/dpkg/info/mariadb-server-10.1.postinst configure
Loading DB routines from perl5db.pl version 1.49_05
Editor support available.
Enter h or 'h h' for help, or 'man perldebug' for more help.
main::(/usr/share/debconf/frontend:11):
11: Debconf::Db->load;
DB<1>
Okay, zero output but an error, I'm out of ideas what is wrong there. Probably debconf itself is broken, but it cannot be fixed (reinstalled) without fixing MariaDB first. Let's go a more radical approach and simply make that postinst script a no-op: