Skip to content

Validation of upload data should happen later in the programm #841

@BioPhoton

Description

@BioPhoton

User story

As a developer I want to have a a tool that handles miss configuration or miss usage as graceful as possible while still helping me to understand the problem and gat some actionable feedback.

When it comes to configuration of the CLI I ran into cases where I feel hindered by the strictness of the upload options.

The validation requires the fields project, server, organization, apyKey to be set or non of them.

Cases where it is hindering:

  • it throws when running any command also collect
  • env variables for .env file or the process it self can cause those errors
  • it adds complexity to the code as we have to consider this case internally now to get good Dx

How it could work instead:

  • the upload config is all optional in CoreConfig
  • it gets evaluated with the uploadConfig.parse helper inside the autorun and upload command right before calling the functionality from core

Acceptance criteria

  • All CLI commands but upload should work with partially configured upload data
  • The nx-plugin should work for all commands but upload should work with partially configured upload data

Implementation details

No response

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions