The problem - there was a tuple:t = ("abc", "def")
Somwhere inside the program was an instruction:something = t[0]
and thensomething
returned "abc".
Some time later it turned out that "def" was not necessary
in
t so was modified:t = ("abc")and sowhere inside the program instruction
something = t[0]
made that something returned "a".It was Bad.
Why that happened?
Beacuse t was not a tuple anymore, it became a string. Instruction
t[0] returns first item in iterable so it returned "a" for us.What was ommited?
A coma.
After the change it was (bad):
t = ("abc")instead (good):
t = ("abc",)The coma creates a tuple. In our case consisting of one item, but still the tuple.
