diff --git a/readthedocs/projects/models.py b/readthedocs/projects/models.py index 3cbba2315a4..a40556df350 100644 --- a/readthedocs/projects/models.py +++ b/readthedocs/projects/models.py @@ -1983,7 +1983,6 @@ def add_features(sender, **kwargs): SCALE_IN_PROTECTION = "scale_in_prtection" USE_S3_SCOPED_CREDENTIALS_ON_BUILDERS = "use_s3_scoped_credentials_on_builders" BUILD_FULL_CLEAN = "build_full_clean" - DONT_CLEAN_BUILD = "dont_clean_build" BUILD_HEALTHCHECK = "build_healthcheck" BUILD_NO_ACKS_LATE = "build_no_acks_late" @@ -2039,12 +2038,6 @@ def add_features(sender, **kwargs): USE_S3_SCOPED_CREDENTIALS_ON_BUILDERS, _("Build: Use S3 scoped credentials for uploading build artifacts."), ), - ( - DONT_CLEAN_BUILD, - _( - "Build: Don't clean the build directory. Only for Enterprise users with dedicated builders." - ), - ), ( BUILD_FULL_CLEAN, _("Build: Clean all build directories to avoid leftovers from other projects."), diff --git a/readthedocs/projects/tasks/utils.py b/readthedocs/projects/tasks/utils.py index b78bd010f9d..b51f6a29fd2 100644 --- a/readthedocs/projects/tasks/utils.py +++ b/readthedocs/projects/tasks/utils.py @@ -27,17 +27,6 @@ def clean_build(version=None): """Clean the files used in the build of the given version.""" - - if version and version.project.has_feature( - Feature.DONT_CLEAN_BUILD, - ): - log.info( - "Skipping cleaning build files for project with DONT_CLEAN_BUILD feature.", - project_slug=version.project.slug, - version_slug=version.slug, - ) - return - if version: del_dirs = [ os.path.join(version.project.doc_path, dir_, version.slug) diff --git a/readthedocs/vcs_support/backends/git.py b/readthedocs/vcs_support/backends/git.py index 3c994d96b28..f11953da043 100644 --- a/readthedocs/vcs_support/backends/git.py +++ b/readthedocs/vcs_support/backends/git.py @@ -53,14 +53,6 @@ def update(self): code, stdout, stderr = self.run(*cmd.split(), escape_command=False) return - # Check for existing checkout and skip clone if it exists. - from readthedocs.projects.models import Feature - - if self.project.has_feature(Feature.DONT_CLEAN_BUILD) and os.path.exists( - os.path.join(self.working_dir, ".git") - ): - return self.fetch() - self.clone() # TODO: We are still using return values in this function that are legacy. # This should be either explained or removed.