8000 Always write the cache (unless cache_dir is /dev/null) by gvanrossum · Pull Request #3133 · python/mypy · GitHub
[go: up one dir, main page]

Skip to content

Always write the cache (unless cache_dir is /dev/null) #3133

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 6 commits into from
Apr 19, 2017
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Better fix for makedirs() race
  • Loading branch information
Guido van Rossum committed Apr 19, 2017
commit c836125800f311a49c553f19a871d4eb417e0c74
5 changes: 1 addition & 4 deletions mypy/build.py
Original file line number Diff line number Diff line change
Expand Up @@ -860,10 +860,7 @@ def write_cache(id: str, path: str, tree: MypyFile,

# Make sure directory for cache files exists
parent = os.path.dirname(data_json)
try:
os.makedirs(parent)
except os.error:
pass # Assume it already exists.
os.makedirs(parent, exist_ok=True)
assert os.path.dirname(meta_json) == parent

# Construct temp file names
Expand Down
0