S
The bug is in the code which logs the tuner being used.Andy looks like a bug .......... will report it.
tuner_info = tn is not None and chr(ord('A') + tn) or "?"
tuner_info = type(tn) is int and chr(ord('A') + tn) or "?"
https://github.com/OpenViX/enigma2/pull/277
This is just masking the problem. You really need to be looking at why the underlying code is not returning int or None.The fix is to change line 440 in RecordTimer.py from:
to:Code:tuner_info = tn is not None and chr(ord('A') + tn) or "?"
I'll submit a PR.Code:tuner_info = type(tn) is int and chr(ord('A') + tn) or "?"
EDIT:Code:https://github.com/OpenViX/enigma2/pull/277
The code change means that it will only ever be used when it contains an int - this makes the code more robust should anyone change what it does contain.fedata["tuner_number"] should only ever contain an int, or not exist.
That is not how it works. Before any changes are made for bugs there has to be a recipe to reproduce the bug and the bug has to be confirmed by a team member. And then a proper fix, not a fix to hide the problem so it pops up elsewhere.Looking at the underyling oddity can then be done at leisure by someone who can reproduce it (I can't, as when I added the original logging I did test it with an IP stream in as far as I could set on up, but it didn't show this issue).
So you're happy to ignore the fact that there is a debug log reporting the error?That is not how it works. Before any changes are made for bugs there has to be a recipe to reproduce the bug and the bug has to be confirmed by a team member.
As I've noted, the code change is to more robust code. We are about to use an item as an int, so check that it is one before doing so.And then a proper fix, not a fix to hide the problem so it pops up elsewhere.
Surely in this case, if the problem pops up elsewhere, it is nothing to do with the original change to add tuner details?That is not how it works. Before any changes are made for bugs there has to be a recipe to reproduce the bug and the bug has to be confirmed by a team member. And then a proper fix, not a fix to hide the problem so it pops up elsewhere.
This is exactly why enigma code is in such a mess.
@Birdman @ HuevosThe code change means that it will only ever be used when it contains an int - this makes the code more robust should anyone change what it does contain.
I'm interested in fixing the current problem now. Looking at the underyling oddity can then be done at leisure by someone who can reproduce it (I can't, as when I added the original logging I did test it with an IP stream in as far as I could set on up, but it didn't show this issue).