You can run the program multiple time as different code runs with random, but they all leads to the same error, and you can find out the error is related to the function ‘process’.
Well the odd place is that in line 171 and 172 in LogicGate.py I checked if the function is NoneType or not, which is no as the print is not triggered, and during the if clauses below there is nothing that changes the variable ‘process’.
Also with the try except, I can print the type of variables in the error line of code, which you can see none of them is a NoneType
I am trying to read you code, but honestly it is unreadable with all line breaks and alike.
I agree with @dragonhunter1 that there are tons of ternary operators and return else, this is bound to have a typo somewhere.
Ok so after some researches and having the entire repl died for days, I think I found out the problem and fixed it. Thanks for all the help
(It seems that the problem is after I found the continuation problem for and gate and or gate, I tried to return a tuple with output and commands left behind, replacing the old output-only return, for potential and/or gates appeared previously.
AND I FORGOT THE ENTIRE THING IN MANY IF ELSE STATEMENTS LOL
Which made the second element in the tuple lost to the garbage system and crash those statements that did the ‘update’)