I created this script to send logs by email, similar to the example on https://developers.google.com/apps-script/reference/base/logger# A \"Report problem\" menu item is availab
The log is for debugging purposes. The idea is that once you run the function you are already in the script editor and you can just look at what went wrong.
To get around this, you can have the script that you are logging use getLog()
to retrieve it as string and output the string into a file on the users Google Drive. YOur "Report Problem" script then takes that file and sends it over.
This is the way logs work in every programming language that I know. It is discarded and started from scratch when you start the program again unless you write it to a file. That is exactly what you have to do here as well.
EDIT: you can also view historical logs here: https://console.cloud.google.com under StackDriver → Logging → Logs