Weird line #s on 3.2.2?

I’m using 3.2.2 on Win10. I just noticed that the line number in the following error message just can’t be true. Am I missing something? Getting ready for posting tutorials onto YT and a preso at CSTA and don’t want to confuse people.

Yes there are several problems with error line numbers at present. reported in issue #2334 and others. Several users on the case, so hopefully a resolution soon.

for example if you generate a deliberate error in line 4 for example it is reported as being in line 3.

1 Like

So, it turns out that correct line numbers in error messages are simple as long as the code that fails is not indirectly executed by commands such as run_file, run_code, and eval_code etc. So far, in those cases, I have yet to find a way to reliably report the correct line number. I was tempted to leave line numbers out in those situations, but may see if anyone else might have any ideas first.
Will hopefully get that code up for review soon.

1 Like

Thanks! Hopefully it’s fixed by July when I have to do my preso in front of actual CS teachers! They’ll notice for sure… Otherwise, I’m loving the new version.

If we don’t manage to get things fixed by then you can always use this as an example of a real world bug and how no software is ever perfect :slight_smile: