Better errors for ID resolving