Fix log display
Fix network bug by flushing the socket so that data are sent right away. Add a bunch of logging, and add disconnection method, still not working