Skip to content

Include path to files in Loader error messages #61

@Sharpie

Description

@Sharpie

When config_builder fails to load a file, a cryptic parsing error can occur. This happens most often with YAML files:

Vagrant failed to initialize at a very early stage:

There was an error loading a Vagrantfile. The file being loaded
and the error message are shown below. This is usually caused by
a syntax error.

Path: /Users/sharpie/Source/debug-utils/Vagrantfile
Line number: 0
Message: Psych::SyntaxError: (<unknown>): control characters are not allowed at line 1 column 1

We should throw a nicer error that includes a path to the malformed file.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions