Open 990201 opened 2 years ago
In the newer versions of cobrapy this indeed would not work. You need to add '.id' to 'reacts'. In this case, it should be:
if (e in reacts.id and ex in reacts.id):
Thank you very much for your answer, but after I corrected it according to what you said, I still encountered the problem
“ if (e in reacts and ex in reacts.id): #identify exchange reactions (if you removed reactions by setting fluxes to zero, then you should add this condition here) TypeError: argument of type 'Reaction' is not iterable”
My bad, it should be 'e in reacts.id'. I fixed it above as well.
thank you very much! my problem solved!
I encountered such an error in the process of operation. Why?
”File "bottom_up_ecology.pyx", line 26, in bottom_up_ecology.starting_environment if (e in reacts and ex in reacts): #identify exchange reactions (if you removed reactions by setting fluxes to zero, then you should add this condition here) TypeError: argument of type 'Reaction' is not iterable“