When I designed this script, I purposely chose to ignore channel numbers and only look at channel names.
The main reason being that I noticed that some channels are duplicated within the same source.
As a matter of fact, I first noticed it with Pluto TV.
These 17 channels probably appear twice each.
For the other issue, I don't have a HDHR, unfortunately.
What I could do is create a test version of this script for the purpose of logging more information when it processes a HDHR source.
Would you be willing to test it if I did that?