implement stat/lstat. fix downloads
raise oserror. code formatting