[20170216230221] General improvements and bug fixes