Catch OSError (if read-only file system)

This commit is contained in:
Joir-dan Gumbs 2020-11-17 23:28:00 -08:00
parent f5dff84476
commit b229c30558

View File

@ -65,7 +65,7 @@ class Migrate:
def remove_old_model_file(cls, app: str, location: str): def remove_old_model_file(cls, app: str, location: str):
try: try:
os.unlink(cls.get_old_model_file(app, location)) os.unlink(cls.get_old_model_file(app, location))
except FileNotFoundError: except (OSError, FileNotFoundError):
pass pass
@classmethod @classmethod