If database output logging is enabled, this saves all the outputs from the indicated prompt number to the database. It's called by run_cell after code has been executed. Parameters ---------- line_num : int The line number from which to save outputs
(self, line_num)
| 739 | self.shell.push(to_main, interactive=False) |
| 740 | |
| 741 | def store_output(self, line_num): |
| 742 | """If database output logging is enabled, this saves all the |
| 743 | outputs from the indicated prompt number to the database. It's |
| 744 | called by run_cell after code has been executed. |
| 745 | |
| 746 | Parameters |
| 747 | ---------- |
| 748 | line_num : int |
| 749 | The line number from which to save outputs |
| 750 | """ |
| 751 | if (not self.db_log_output) or (line_num not in self.output_hist_reprs): |
| 752 | return |
| 753 | output = self.output_hist_reprs[line_num] |
| 754 | |
| 755 | with self.db_output_cache_lock: |
| 756 | self.db_output_cache.append((line_num, output)) |
| 757 | if self.db_cache_size <= 1: |
| 758 | self.save_flag.set() |
| 759 | |
| 760 | def _writeout_input_cache(self, conn): |
| 761 | with conn: |