Problem

  • During initial site development, the excessive amount of caching + PHP file dumping in Drupal can get very well in your way.
  • Figuring out how to disable all this stuff can be insanely hard.

Proposed solution

  1. Add to the end of default.settings.php:
    /**
     * Cache control.
     */
    // @todo We do not have a non-dumping implementation. :(
    # $conf['php_storage']['default']['class'] = 'Drupal\Component\PhpStorage\FileStorage';
    # $conf['cache_classes']['cache'] = 'Drupal\Core\Cache\NullBackend';
    

Comments

sun’s picture

Issue tags: +Sunrise Sanity Cruise
sun’s picture

btw, both of these should be $settings instead of $conf, but I guess/hope we have separate issues for that already.

sun’s picture

oh d.o...

sun’s picture

Turned that @todo into a separate follow-up: #1933726: How do I prevent DrupalKernel from dumping?

sun’s picture

Status: Active » Needs review
StatusFileSize
new1.13 KB

Kick-starting this to get the ball rolling. Prematurely including a setting for #1933726: How do I prevent DrupalKernel from dumping?

There are apparently some other new sections for similar developer-mode settings with regard to Twig scattered throughout settings.php.

Furthermore, it would make sense to move/mention the CSS/JS aggregation settings here, too.

sun’s picture

And here's an alternative proposal:

A radical clean-up of default.settings.php and compact listing of all the settings you typically need to touch/override for development environments.

I'd really love to see this, as I find it quite annoying to have to dig out the proper lines from other existing installs each time. However, also happy to go with just #5, if people think that this is too much or too radical. ;)

sun’s picture

Issue summary: View changes

Updated issue summary.

mgifford’s picture

Issue summary: View changes

This is a great idea @sun. Would be great to be able to set this in a settings.local.php file so that developers are less frustrated running into caching issues when developing the site.

Testing would just include reviewing the help text and then un-commenting the variables.

$conf['system.logging']['error_level'] = ERROR_REPORTING_DISPLAY_VERBOSE;
$conf['system.performance']['css']['preprocess'] = FALSE;
$conf['system.performance']['js']['preprocess'] = FALSE;
$conf['cache_classes'] = array('cache' => 'Drupal\Core\Cache\NullBackend');
$settings['kernel.dump'] = FALSE;
$conf['php_storage']['default']['class'] = 'Drupal\Component\PhpStorage\FileStorage';
$settings['twig_debug'] = TRUE;
$settings['twig_auto_reload'] = TRUE;
$settings['twig_cache'] = FALSE;

What else would be needed?

mgifford’s picture

patch no longer applied.

scor’s picture

straight reroll.

also adding a patch with all options enabled to see if some tests are failing.

Status: Needs review » Needs work
wim leers’s picture

#2226761: Change all default settings and config to fast/safe production values landed. I think this might need a reroll to apply the changes to sites/example.settings.local.php instead.

Version: 8.0.x-dev » 8.1.x-dev

Drupal 8.0.6 was released on April 6 and is the final bugfix release for the Drupal 8.0.x series. Drupal 8.0.x will not receive any further development aside from security fixes. Drupal 8.1.0-rc1 is now available and sites should prepare to update to 8.1.0.

Bug reports should be targeted against the 8.1.x-dev branch from now on, and new development or disruptive changes should be targeted against the 8.2.x-dev branch. For more information see the Drupal 8 minor version schedule and the Allowed changes during the Drupal 8 release cycle.

Version: 8.1.x-dev » 8.2.x-dev

Drupal 8.1.9 was released on September 7 and is the final bugfix release for the Drupal 8.1.x series. Drupal 8.1.x will not receive any further development aside from security fixes. Drupal 8.2.0-rc1 is now available and sites should prepare to upgrade to 8.2.0.

Bug reports should be targeted against the 8.2.x-dev branch from now on, and new development or disruptive changes should be targeted against the 8.3.x-dev branch. For more information see the Drupal 8 minor version schedule and the Allowed changes during the Drupal 8 release cycle.

Version: 8.2.x-dev » 8.3.x-dev

Drupal 8.2.6 was released on February 1, 2017 and is the final full bugfix release for the Drupal 8.2.x series. Drupal 8.2.x will not receive any further development aside from critical and security fixes. Sites should prepare to update to 8.3.0 on April 5, 2017. (Drupal 8.3.0-alpha1 is available for testing.)

Bug reports should be targeted against the 8.3.x-dev branch from now on, and new development or disruptive changes should be targeted against the 8.4.x-dev branch. For more information see the Drupal 8 minor version schedule and the Allowed changes during the Drupal 8 release cycle.

Version: 8.3.x-dev » 8.4.x-dev

Drupal 8.3.6 was released on August 2, 2017 and is the final full bugfix release for the Drupal 8.3.x series. Drupal 8.3.x will not receive any further development aside from critical and security fixes. Sites should prepare to update to 8.4.0 on October 4, 2017. (Drupal 8.4.0-alpha1 is available for testing.)

Bug reports should be targeted against the 8.4.x-dev branch from now on, and new development or disruptive changes should be targeted against the 8.5.x-dev branch. For more information see the Drupal 8 minor version schedule and the Allowed changes during the Drupal 8 release cycle.

Version: 8.4.x-dev » 8.5.x-dev

Drupal 8.4.4 was released on January 3, 2018 and is the final full bugfix release for the Drupal 8.4.x series. Drupal 8.4.x will not receive any further development aside from critical and security fixes. Sites should prepare to update to 8.5.0 on March 7, 2018. (Drupal 8.5.0-alpha1 is available for testing.)

Bug reports should be targeted against the 8.5.x-dev branch from now on, and new development or disruptive changes should be targeted against the 8.6.x-dev branch. For more information see the Drupal 8 minor version schedule and the Allowed changes during the Drupal 8 release cycle.

Version: 8.5.x-dev » 8.6.x-dev

Drupal 8.5.6 was released on August 1, 2018 and is the final bugfix release for the Drupal 8.5.x series. Drupal 8.5.x will not receive any further development aside from security fixes. Sites should prepare to update to 8.6.0 on September 5, 2018. (Drupal 8.6.0-rc1 is available for testing.)

Bug reports should be targeted against the 8.6.x-dev branch from now on, and new development or disruptive changes should be targeted against the 8.7.x-dev branch. For more information see the Drupal 8 minor version schedule and the Allowed changes during the Drupal 8 release cycle.

Version: 8.6.x-dev » 8.8.x-dev

Drupal 8.6.x will not receive any further development aside from security fixes. Bug reports should be targeted against the 8.8.x-dev branch from now on, and new development or disruptive changes should be targeted against the 8.9.x-dev branch. For more information see the Drupal 8 and 9 minor version schedule and the Allowed changes during the Drupal 8 and 9 release cycles.

Version: 8.8.x-dev » 8.9.x-dev

Drupal 8.8.7 was released on June 3, 2020 and is the final full bugfix release for the Drupal 8.8.x series. Drupal 8.8.x will not receive any further development aside from security fixes. Sites should prepare to update to Drupal 8.9.0 or Drupal 9.0.0 for ongoing support.

Bug reports should be targeted against the 8.9.x-dev branch from now on, and new development or disruptive changes should be targeted against the 9.1.x-dev branch. For more information see the Drupal 8 and 9 minor version schedule and the Allowed changes during the Drupal 8 and 9 release cycles.

Version: 8.9.x-dev » 9.2.x-dev

Drupal 8 is end-of-life as of November 17, 2021. There will not be further changes made to Drupal 8. Bugfixes are now made to the 9.3.x and higher branches only. For more information see the Drupal core minor version schedule and the Allowed changes during the Drupal core release cycle.

Version: 9.2.x-dev » 9.3.x-dev

Version: 9.3.x-dev » 9.4.x-dev

Drupal 9.3.15 was released on June 1st, 2022 and is the final full bugfix release for the Drupal 9.3.x series. Drupal 9.3.x will not receive any further development aside from security fixes. Drupal 9 bug reports should be targeted for the 9.4.x-dev branch from now on, and new development or disruptive changes should be targeted for the 9.5.x-dev branch. For more information see the Drupal core minor version schedule and the Allowed changes during the Drupal core release cycle.

quietone credited darvanen.

quietone’s picture

Status: Needs work » Closed (outdated)
Issue tags: +Bug Smash Initiative

This issue was discussed at a Bug Smash Initiative group triage meeting. darvanen stated that this is ourdated, explaining that "example.settings.local.php has good instructions for disabling caches and the twig stuff has moved to example.services.yml".

Therefore, closing as outdated. If this is incorrect reopen the issue, by setting the status to 'Active', and add a comment explaining what still needs to be done.

Thanks!