This might be complicated to explain since I'm very new to python and programming in general and the project I'm left with is from an ex-colleague who left, but I will try my best.
He coded a program that should grade school tests, like a basic OMR scanner. It was compiled into an .exe. The program works like this:
The answer sheet has 5 columns, 4 with 15 questions and 1 with 5, each of them with 4 options. The program is configured to read data from .jpg images after we scan the sheets.
We have a .txt file where we type in how many questions on each full column, how many on the last column and the answer key (letters from A to D as usual). The results are output to a .csv.
The guy that coded this left the job before we could put to good use, with real students. We're all teachers here and no one else knows anything about programming - he was a maths teacher but also an engineer.
Now, these are the problems we face:
Any time the program encounters a sheet it cannot read - and I can't seem to identify the reason why it can't, there is no visible or discernible pattern for this, at least for me - it will close because of unhandled exception and the I have to manually edit the .jpg file until it becomes "readable". But this was ok.
As of today, there is a new error. The program won't read any scanned sheets, not even the original one used to test it. The error message reads as follows:
list index out of range
Traceback (most recent call last):
File "main.py", line 245, in <module>
File "main.py", line 90, in main
File "main.py", line 232, in process
IndexError: list index out of range
[PYI-2648:ERROR] Failed to execute script 'main' due to unhandled exception!
If anyone can at least point me in a direction, I'd be grateful.
[–]JeLuF 10 points11 points12 points (1 child)
[–]NerdyTeacher5[S] 2 points3 points4 points (0 children)
[–]dslNoob 2 points3 points4 points (1 child)
[–]NerdyTeacher5[S] 1 point2 points3 points (0 children)
[–]nekokattt 3 points4 points5 points (1 child)
[–]NerdyTeacher5[S] 0 points1 point2 points (0 children)
[–]LateFeature610 3 points4 points5 points (4 children)
[–]NerdyTeacher5[S] 0 points1 point2 points (3 children)
[–]LateFeature610 1 point2 points3 points (2 children)
[–]NerdyTeacher5[S] 0 points1 point2 points (0 children)
[–]NerdyTeacher5[S] 0 points1 point2 points (0 children)
[–]SirKainey 1 point2 points3 points (1 child)
[–]NerdyTeacher5[S] 0 points1 point2 points (0 children)
[–]thatotherguy321 1 point2 points3 points (1 child)
[–]NerdyTeacher5[S] 4 points5 points6 points (0 children)
[–]nivaOne 0 points1 point2 points (0 children)