Upgrade VIE, improve error handling.