Bug #433
closedQuery/Import RepeaterBook fails uncleanly if no repeaters found in specified filters
100%
Description
Open Chirp
Menu/Radio/Query Data Source
RepeaterBook
Specify (example): Tennessee, William County, 2 Meters.
You will get the "busy" "blue ring" - and it never goes away.
This is due to the fact that no repeaters are returned.
-- Exception: --
Traceback (most recent call last):
File "E:\Dev\Chirp\chirp.hg\chirpui\mainapp.py", line 856, in do_repeaterbook
radio = RBRadio(filename)
File "E:\Dev\Chirp\chirp.hg\chirp\generic_csv.py", line 84, in init
self.load()
File "E:\Dev\Chirp\chirp.hg\chirp\generic_csv.py", line 178, in load
raise errors.InvalidDataError("No channels found")
InvalidDataError: No channels found¶
Traceback (most recent call last):
File "E:\Dev\Chirp\chirp.hg\chirpui\mainapp.py", line 1247, in mh
self.do_repeaterbook(action[0] == "i")
File "E:\Dev\Chirp\chirp.hg\chirpui\mainapp.py", line 865, in do_repeaterbook
reporting.report_model_usage(radio, "import", True)
UnboundLocalError: local variable 'radio' referenced before assignment
IF the line at chirp.hg\chirpui\mainapp.py 865:
reporting.report_model_usage(radio, "import", True)
is moved up two lines to just before the exception, so that it is like this:
try:
# Validate CSV
radio = RBRadio(filename)
if radio.errors:
reporting.report_misc_error("repeaterbook",
("query=%s\n" % query) +
("\n") +
("\n".join(radio.errors)))
reporting.report_model_usage(radio, "import", True)
except Exception, e:
common.log_exception()
Then the circle disappears as appropriate after the failure.
I am totally new to this project and did not know the "procedure" for making changes or whether I even could.
I just installed an hour ago and traced down the issue.
It should also display a message indicating nothing found, and I will work on that next.
www.swclogic.com W4SWC Baufeng UV5R latest firmware BFB297 (I think latest)
Files