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

fix: correctly parse various numeric forms #10923

Merged
merged 4 commits into from
Apr 19, 2022

Commits on Mar 31, 2022

  1. fix: correctly parse various numeric forms

    The smartctl output can vary based on the localization set in Windows.
    This means that some numbers can show up comma-seperated (english),
    space seperated, or even apostrophe seperated. There are probably
    others.
    
    This updates one function that was always assuming comma seperated to
    remove any non-numeric value and no longer split on white space, which
    could be used as a seperator.
    
    Fixes: influxdata#10907
    powersj committed Mar 31, 2022
    Configuration menu
    Copy the full SHA
    a2b7f18 View commit details
    Browse the repository at this point in the history
  2. add error message too

    powersj committed Mar 31, 2022
    Configuration menu
    Copy the full SHA
    31e3e06 View commit details
    Browse the repository at this point in the history

Commits on Apr 11, 2022

  1. Correctly parse variety of numeric string formats

    This removes any non-utf8 values in strings, like whitespace charachters
    (e.g. \x92 or \xa0) as well as removes whitespace or commas that are
    sometimes used in the parsing of values.
    powersj committed Apr 11, 2022
    Configuration menu
    Copy the full SHA
    3431d0c View commit details
    Browse the repository at this point in the history
  2. remove debug

    powersj committed Apr 11, 2022
    Configuration menu
    Copy the full SHA
    5ffdaec View commit details
    Browse the repository at this point in the history