Python script crashes when select board type different that default value. Changing action from append to store for -board argument should fix this issue.
pi@raspberrypi:~/pico/my-apps $ python ../../pico-project-generator/pico_project.py freertos-demo -d 0 -p vscode --overwrite -board pico_w
Traceback (most recent call last):
File "/home/pi/pico/my-apps/../../pico-project-generator/pico_project.py", line 1369, in <module>
args = ParseCommandLine()
File "/home/pi/pico/my-apps/../../pico-project-generator/pico_project.py", line 915, in ParseCommandLine
return parser.parse_args()
File "/usr/lib/python3.9/argparse.py", line 1830, in parse_args
args, argv = self.parse_known_args(args, namespace)
File "/usr/lib/python3.9/argparse.py", line 1863, in parse_known_args
namespace, args = self._parse_known_args(args, namespace)
File "/usr/lib/python3.9/argparse.py", line 2072, in _parse_known_args
start_index = consume_optional(start_index)
File "/usr/lib/python3.9/argparse.py", line 2012, in consume_optional
take_action(action, args, option_string)
File "/usr/lib/python3.9/argparse.py", line 1940, in take_action
action(self, namespace, argument_values, option_string)
File "/usr/lib/python3.9/argparse.py", line 1035, in __call__
items.append(values)
AttributeError: 'str' object has no attribute 'append'
Python script crashes when select board type different that default value. Changing action from
append
tostore
for-board
argument should fix this issue.