How do I debug a Flask application running in a Docker containe?

I’ve tried everything that is relatively simple … using the std.flush() to flush the print statements…importing logging library and using "logger.info()"…nothing works…nothing.

The thing is, I’m dealing with legacy code and the person before added "logger.info()" statements that successfully print to the host console, but when I try to add my own, they don’t print! I have no idea what is going on…anyone have any answers? Any answer you can provide will be met with much appreciation, and thank you very much in advance!

Source: Docker Questions