Attempting to add a subscription by channel number does not work (results in RuntimeError: coroutine raised StopIteration).
I think this is because it's attempting to match channel.number (which is an int) against self.option('rx-channel-number') (which is a str). I added a line of debugging to commands/subscription/_add.py as follows:
# ...
elif self.option("rx-channel-number"):
for ch in rx_device.rx_channels.values():
print('Considering', ch.number, type(ch.number), type(self.option('rx-channel-number')), ch.number == self.option('rx-channel-number'))
# ...
Attempting to add a subscription by channel number does not work (results in
RuntimeError: coroutine raised StopIteration
).I think this is because it's attempting to match
channel.number
(which is anint
) againstself.option('rx-channel-number')
(which is astr
). I added a line of debugging tocommands/subscription/_add.py
as follows:resulting in:
In case it makes a difference, this is on both Python 3.8 and 3.9, using v0.0.10 of
netaudio
.