Skip to content
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

Remove global pip cache #6437

Merged
merged 1 commit into from
Dec 5, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
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
11 changes: 0 additions & 11 deletions readthedocs/doc_builder/environments.py
Original file line number Diff line number Diff line change
Expand Up @@ -945,9 +945,6 @@ def _get_binds(self):

It uses Docker Volume if running on a docker-compose. Otherwise, it
returns just a regular mountpoint path.

Besides, it binds the ``GLOBAL_PIP_CACHE`` if it's set and we are under
``DEBUG`` mode.
"""
if getattr(settings, 'RTD_DOCKER_COMPOSE', False):
from pathlib import Path
Expand All @@ -965,14 +962,6 @@ def _get_binds(self):
},
}

if settings.GLOBAL_PIP_CACHE and settings.DEBUG:
binds.update({
self.project.pip_cache_path: {
'bind': self.project.pip_cache_path,
'mode': 'rw',
},
})

return binds

def get_container_host_config(self):
Expand Down
2 changes: 0 additions & 2 deletions readthedocs/projects/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -663,8 +663,6 @@ def checkout_path(self, version=LATEST):
@property
def pip_cache_path(self):
"""Path to pip cache."""
if settings.GLOBAL_PIP_CACHE and settings.DEBUG:
return settings.GLOBAL_PIP_CACHE
return os.path.join(self.doc_path, '.cache', 'pip')

#
Expand Down
1 change: 0 additions & 1 deletion readthedocs/settings/base.py
Original file line number Diff line number Diff line change
Expand Up @@ -275,7 +275,6 @@ def USE_PROMOS(self): # noqa
}
}
CACHE_MIDDLEWARE_SECONDS = 60
GLOBAL_PIP_CACHE = False

# I18n
TIME_ZONE = 'UTC'
Expand Down