Fixes for error reporting and better error state management (no refs)

The path schema can be a plain variable, and is actually reported in
errors now, which are cleaner (no nil components).