This is a followup to T78537.
Consider the attached script. It creates an image and a texture node. Image.source = SINGLE IMAGE but behind the scenes Image.image_user.frame_duration = 100, which apparently causes memory problems according to the other bug report. You can see that by switching the source to MOVIE.
It is easy to avoid this problem by adding the line
node.image_user.frame_duration = 1
whenever a texture node is created. But then you need to know that you should do that.