diff options
| author | Joerg Hofrichter <joerg.hofrichter@ni.com> | 2020-07-10 19:36:40 +0200 | 
|---|---|---|
| committer | Aaron Rossetto <aaron.rossetto@ni.com> | 2020-07-13 15:22:59 -0500 | 
| commit | b2527716000284eaaaeff9d6c51241c5392e92f6 (patch) | |
| tree | 459dc87af586ba475bba0a52162e0e8004fa1744 /mpm/python/usrp_mpm | |
| parent | 3c8d8dea1e1e89faa81507845c8d0eebf501f94d (diff) | |
| download | uhd-b2527716000284eaaaeff9d6c51241c5392e92f6.tar.gz uhd-b2527716000284eaaaeff9d6c51241c5392e92f6.tar.bz2 uhd-b2527716000284eaaaeff9d6c51241c5392e92f6.zip | |
mpm: utils: print error on minor compat number mismatch conditionally
If the minor compat number does not match (older than expected), then
generate an error message only if argument fail_on_old_minor is True;
generate a warning otherwise.
Diffstat (limited to 'mpm/python/usrp_mpm')
| -rw-r--r-- | mpm/python/usrp_mpm/mpmutils.py | 3 | 
1 files changed, 2 insertions, 1 deletions
| diff --git a/mpm/python/usrp_mpm/mpmutils.py b/mpm/python/usrp_mpm/mpmutils.py index f7e4e3be1..5da81ecfe 100644 --- a/mpm/python/usrp_mpm/mpmutils.py +++ b/mpm/python/usrp_mpm/mpmutils.py @@ -135,9 +135,10 @@ def assert_compat_number(          err_msg = "Minor compat number mismatch{}: {}".format(              component_str, expected_actual_str          ) -        log_err(err_msg)          if fail_on_old_minor: +            log_err(err_msg)              raise RuntimeError(err_msg) +        log_warn(err_msg)      return  def str2bool(value): | 
