Skip to content

When using CLI in windows, invalid path exception is always thrown #1158

@LuisDiezLaso

Description

@LuisDiezLaso

Bug report

The GTFS Validator IN WINDOWS 10(this probably doesn´t happen for linux) seems to always throw an InvalidPathException for the input file path.
This didn´t happen in release 3.0.1

Describe the bug
The GTFS Validator throws InvalidPathException in Windows no matter what the path of the input file is.

How we reproduce the bug
All of these steps are being reproduced in the jar for windows and java 11 from one of your latest pushes to master

  1. Try to execute the jar with any input file.
    image

  2. U should get an error like this.
    image

  3. As you can see in the error, there is one extra "/" character in the beginning of the path which throws the exception, maybe you are trying to build a path from the CLI arguments, from that path take the URI, and then from the URI build the path back again and that just leaves a special character in windows systems.

Expected behaviour
It shouldn´t throw an exception when the given path is fine.
Observed behaviour
There´s an exception thrown.

Screenshots:
The ones above explain the issue(if they don´t, just let me know).

Environment versions

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working (crash, a rule has a problem)

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions