Drush tries to export config for modules I deleted months ago
When you removed the modules I would guess you didn't uninstall them first. The simplest approach is probably going to be to put the code back by whatever means you originally installed them, in the same location, then uninstall them via the admin panel or drush before removing the code again. That way the core code will fire that deletes the config.

It is possible that a module may break the uninstall process, in which case this is a trickier problem but best to go down the simplest route first.