Capturing output of IJulia cell

I recently switched from running an optimization problem in Python to Julia, and am really enjoying the change! However, I’ve noticed that when I run a long optimization problem and close a notebook:

  1. I lose the output once it is completed - in Python I could run a cell magic (ie. %%capture output) to keep the printed output either in a file or below the cell, but the same magic does not apply to Julia. Is there an equivalent solution?
  2. I also don’t see any results during the optimization process (ie. progress bar/iteration step). How do people who use JuMP monitor progress in an IJulia notebook?

Generally I’m curious about people’s workflows and I’d love to pick up some best practices from the Julia community. Thank you for your input!

  1. If you save the notebook after the output has run, the printed output should be saved with the notebook.

  2. I think there was an issue flushing io from external solvers to the notebook. I haven’t kept up on recent developments. I use vs-code instead: https://www.julia-vscode.org