Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adding a better error message for download mode #1492

Open
wants to merge 25 commits into
base: main
Choose a base branch
from

Commits on Dec 12, 2019

  1. Adding a better error message for download mode

    When it's missing, we write a short message saying so, and when it's invalid, we do approximately the same thing. Athens has a lot of configuration options, so it's naturally easy to get them wrong or forget something. Nicer error messages should help.
    
    If this code is acceptable, I'd like to apply it to a few other config values (in a follow-up PR) that are easy to get wrong.
    
    ref gomods#1491, since this checks existence and validates values for download mode, and also reports errors in a more human-friendly way
    
    cc/ @bluekeyes
    arschles committed Dec 12, 2019
    Configuration menu
    Copy the full SHA
    0224e53 View commit details
    Browse the repository at this point in the history
  2. Fixing test

    arschles committed Dec 12, 2019
    Configuration menu
    Copy the full SHA
    fa2631c View commit details
    Browse the repository at this point in the history

Commits on Dec 13, 2019

  1. Making some progress toward removing the specific config error

    cc/ @marwan-at-work, I think I've addressed almost all of your comments here, but let me know if this overall design is what you had in mind. Tests are still failing, I'm fixing those shortly
    arschles committed Dec 13, 2019
    Configuration menu
    Copy the full SHA
    834eba4 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    f45a03b View commit details
    Browse the repository at this point in the history

Commits on Dec 19, 2019

  1. Configuration menu
    Copy the full SHA
    4715103 View commit details
    Browse the repository at this point in the history

Commits on Feb 14, 2020

  1. Configuration menu
    Copy the full SHA
    e928a0f View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    32e7c28 View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    a846557 View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    25b5860 View commit details
    Browse the repository at this point in the history
  5. making the DownloadMode field required

    and setting a default
    arschles committed Feb 14, 2020
    Configuration menu
    Copy the full SHA
    36b6d62 View commit details
    Browse the repository at this point in the history
  6. Configuration menu
    Copy the full SHA
    2c6b90b View commit details
    Browse the repository at this point in the history

Commits on Feb 21, 2020

  1. Configuration menu
    Copy the full SHA
    5b85142 View commit details
    Browse the repository at this point in the history
  2. Not passing an op to Validate functions

    Also removing the op from DownloadFile.Validate
    arschles committed Feb 21, 2020
    Configuration menu
    Copy the full SHA
    65662f5 View commit details
    Browse the repository at this point in the history
  3. Not checking for error strings in mode test

    Just checking to see if there's an error. Also adding tests for valid modes
    arschles committed Feb 21, 2020
    Configuration menu
    Copy the full SHA
    e962a4d View commit details
    Browse the repository at this point in the history
  4. more doc for Validator

    arschles committed Feb 21, 2020
    Configuration menu
    Copy the full SHA
    1b29dcf View commit details
    Browse the repository at this point in the history
  5. removing struct tag for config port validation

    Looks like validate tags don't have a prefix checker. This seems easier than building a custom validator
    arschles committed Feb 21, 2020
    Configuration menu
    Copy the full SHA
    d6a7cbd View commit details
    Browse the repository at this point in the history

Commits on Mar 10, 2020

  1. Configuration menu
    Copy the full SHA
    de71cb7 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    cc70e12 View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    a5eda16 View commit details
    Browse the repository at this point in the history
  4. s/retFile/df

    arschles committed Mar 10, 2020
    Configuration menu
    Copy the full SHA
    198d574 View commit details
    Browse the repository at this point in the history
  5. Configuration menu
    Copy the full SHA
    ee8f4d1 View commit details
    Browse the repository at this point in the history
  6. Configuration menu
    Copy the full SHA
    2cc9f84 View commit details
    Browse the repository at this point in the history
  7. Configuration menu
    Copy the full SHA
    9695c36 View commit details
    Browse the repository at this point in the history
  8. Configuration menu
    Copy the full SHA
    726b77c View commit details
    Browse the repository at this point in the history
  9. Configuration menu
    Copy the full SHA
    4320101 View commit details
    Browse the repository at this point in the history