gi_frame may be none (generator stopped)