fix: normalize global rel paths for win compat

main^2
rrr-marble 4 years ago
parent 3e7ef81102
commit 9620458977

@ -266,8 +266,8 @@ def unpack_pictures_zip(file: UploadFile, time):
iph.run( iph.run(
db_location=DB_LOCATION, db_location=DB_LOCATION,
source=os.path.join(dir), source=os.path.join(dir),
dest_shrunk=os.path.join(DATA_LOCATION, DEST_SHRUNK), dest_shrunk=os.path.join(DATA_LOCATION, os.path.normcase(DEST_SHRUNK)),
dest_original=os.path.join(DATA_LOCATION, DEST_ORIGINAL), dest_original=os.path.join(DATA_LOCATION, os.path.normcase(DEST_ORIGINAL)),
) )
rmtree(processing_path) rmtree(processing_path)

@ -190,7 +190,12 @@ def main():
sys.path.append(os.path.dirname(__file__) + "/..") sys.path.append(os.path.dirname(__file__) + "/..")
import config as cfg import config as cfg
run(cfg.DB_LOCATION, argv[1], cfg.DEST_SHRUNK, cfg.DEST_ORIGINAL) run(
cfg.DB_LOCATION,
argv[1],
path.normcase(cfg.DEST_SHRUNK),
path.normcase(cfg.DEST_ORIGINAL),
)
if __name__ == "__main__": if __name__ == "__main__":

Loading…
Cancel
Save