gq uses formatexpr over formatprg if both are set, and even with the config mentioned in the title, both are set.
Thus if you really want to use the dangerous formatprg, you have to also setup an ftplugin to unset formatexpr. (Should vim-ledger do this automatically? I'm not sure, hence this issue as a discussion forum.)