still buggy but reading/writing log works in most basic form