Project

General

Profile

Actions

Bug #9423

closed

Broken chirpc setter commands

Added by Martin Cooper over 2 years ago. Updated over 2 years ago.

Status:
Closed
Priority:
Normal
Assignee:
Category:
-
Target version:
-
Start date:
10/05/2021
Due date:
% Done:

100%

Estimated time:
Chirp Version:
daily
Model affected:
(All models)
Platform:
All
Debug Log:
I read the instructions above:

Description

Setter commands in chirpc that use custom actions are broken. It looks like the breakage happened when optparse was replaced with argparse. There are several issues.

Common Issues

  • The value passed to 'call' is always a list, even when nargs is 1, but these are being treated as if they are a single value.
  • ArgumentError requires 'self' to be passed as the first argument. The second argument should be the message, but this is the only argument being passed.

Specific Issues

  • The check for a valid value in ToneAction is inverted, so that valid values are rejected and invalid ones passed.
  • Minor typo in the ToneAction error message.
  • Obsolete optparse code remains in DTCSPolarityAction, both in the exception being raised and the arguments being passed to setattr.
Actions #1

Updated by Anonymous over 2 years ago

  • Status changed from New to Closed
  • % Done changed from 0 to 100

Applied in changeset commit:111a0c6d0892.

Actions

Also available in: Atom PDF