I'm currently running a Magento 2 (2.2.7) site and I've been getting the following error in the CLI when I enter certain commands (usually to do with enabling/disabling modules).
The directory "/var/www/vhosts/websitename.com/httpdocs/generated/code/Magento/Framework" cannot be deleted Warning!rmdir(/var/www/vhosts/websitename.com/httpdocs/generated/code/Magento/Framework): Directory not empty
I've also had some errors relating to Framework when certain modules are enabled.
I wondered what this error was and how to stop if from happening as I'm sure it's having some impact on my site.