Skip to content
This repository has been archived by the owner on Apr 26, 2024. It is now read-only.

Commit

Permalink
Merge pull request #4214 from matrix-org/rav/ignore_pycache
Browse files Browse the repository at this point in the history
Ignore __pycache__ directories in schema delta dir
  • Loading branch information
hawkowl authored Nov 21, 2018
2 parents 78ba0e7 + 6c18cc4 commit e8690de
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
1 change: 1 addition & 0 deletions changelog.d/4214.misc
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Ignore __pycache__ directories in the database schema folder
2 changes: 1 addition & 1 deletion synapse/storage/prepare_database.py
Original file line number Diff line number Diff line change
Expand Up @@ -257,7 +257,7 @@ def _upgrade_existing_database(cur, current_version, applied_delta_files,
module.run_create(cur, database_engine)
if not is_empty:
module.run_upgrade(cur, database_engine, config=config)
elif ext == ".pyc":
elif ext == ".pyc" or file_name == "__pycache__":
# Sometimes .pyc files turn up anyway even though we've
# disabled their generation; e.g. from distribution package
# installers. Silently skip it
Expand Down

0 comments on commit e8690de

Please sign in to comment.