Document that files must be emptied rather than removed

Created on 11 July 2016, about 8 years ago
Updated 19 July 2024, about 2 months ago

Problem/Motivation

#2761865: Update from 8.1.3 to 8.1.4 breaks site seemingly permanently showed that:

1. Lots of people don't follow the instructions strictly when updating core versions (not really a surprise) which leaves cruft in /core and /vendor

2. 'Cruft' classes in a Drupal 8 install can lead to a broken site (more of a surprise).

In this case, the file that caused the damage was a service modifier - just by existing on the filesystem, it's picked up by core, so if not removed properly when doing the upgrade, the site would fatal because the crufty file was making assumptions about the code base which were no longer true. Importantly, even if this particular change had not caused a fatal error, assuming the file would have stayed around in some people's installs, it could have affected things in 8.3.x or 8.4.x too (and been harder to track down after time passing).

Proposed resolution

Document that rather than deleting files, we should make them blank files (opening <?php + a comment), so that even if people don't clear out /core and /vendor the files will be replaced with ones that won't have code to execute, rather than being left as-is - this is what we did to resolve that issue with the release of 8.1.6

Remaining tasks

Figure out exactly where to document it, the bc policy or @internal page doesn't feel like quite the right place, but might be the closest.

User interface changes

API changes

Data model changes

📌 Task
Status

Closed: outdated

Version

11.0 🔥

Component
Documentation 

Last updated 1 minute ago

No maintainer
Created by

🇬🇧United Kingdom catch

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

Production build 0.71.5 2024