clean up of get_os_path and its tests

work with @Zsailer
session restructuring, add database for session