Skip to content

Return an error type rather than a tuple of string and int #6

@lpil

Description

@lpil

Hello!

Currently the error value for the command function is very unrefined:

  • The fields are unnamed, so it's unclear what they are without experimentation.
  • The error design states there is a status code, but one may not exist if the program was never run.
  • The error is represented as a string, so the user has to parse this string in order to determine what the error was.

I think it'd be a lot nicer to use if there was an error type. It could have variants for the different kinds of reasons why the process failed to run.

Thanks,
Louis

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions