Drupal Release: 9.0.0-beta3
Pre Release
Tag Name: 9.0.0-beta3
Release Date: 5/15/2020
DrupalHighly flexible, open-source content management system known for complex, scalable web applications. Preferred by government, educational, and large enterprise websites requiring advanced customization and security features. Robust module ecosystem.
TL;DR
Drupal 9.0.0-beta3 represents a significant step toward the stable release of Drupal 9, focusing primarily on code modernization, test improvements, and compatibility with newer dependencies like Symfony 5 and Composer 2. This beta includes numerous deprecation fixes, PHPUnit test improvements, and code quality enhancements to ensure Drupal 9 meets modern PHP standards. While there are no major new features, the release includes important bug fixes, security improvements, and performance optimizations that make the platform more robust and future-proof.
Highlight of the Release
- Compatibility with Composer 2
- Updated to jQuery 3.5.1
- Improved PHPUnit test assertions and methods
- Support for Symfony 5 components
- Fixed database driver support with dedicated directories
- Improved error logging for 403 access denied errors
- Better update process handling for sites with missing schema information
Migration Guide
Preparing for Drupal 9.0.0-beta3
PHP Requirements
- Ensure you're running PHP 7.3 or higher
Database Requirements
- MySQL 5.7.8 or higher (now properly checked during upgrades)
- PostgreSQL 9.6 or higher recommended for best performance
JavaScript Requirements
- Node.js 12 is now required for development
Composer 2 Compatibility
Drupal 9.0.0-beta3 is now compatible with Composer 2. If you're using Composer 2, ensure your workflow is updated accordingly.
PHPUnit Test Updates
If you have custom PHPUnit tests, you'll need to update deprecated assertion methods:
- Replace
assertContains()on strings withassertStringContainsString()orassertStringContainsStringIgnoringCase() - Replace
assertAttributeSame(),assertAttributeEquals(),assertAttributeEmpty(), andassertAttributeInstanceOf()with direct property access and standard assertions - Replace
assertArraySubset()with more specific assertions - Add return type hints to
setUp()andtearDown()methods in concrete test classes
Symfony Component Updates
Update any code using deprecated Symfony components:
- Replace
Symfony\Component\Debug\BufferingLoggerwithSymfony\Component\ErrorHandler\BufferingLogger - Replace
Symfony\Component\HttpKernel\Event\GetResponseForExceptionEvent::getException()withgetThrowable() - Update
Symfony\Component\Process\Process::inheritEnvironmentVariables()usage as environment variables are now always inherited - Replace
Symfony\Component\HttpFoundation\Request::isMethodSafe()with appropriate alternatives
Database Driver Changes
If you have custom database drivers, note that they should now be placed in a fixed location within your module.
Upgrade Recommendations
For Drupal 8 Sites
If you're currently running Drupal 8.8.x or 8.9.x, upgrading to Drupal 9.0.0-beta3 is recommended for testing purposes only. This beta release allows you to test your site's compatibility with Drupal 9 before the stable release.
Important steps before upgrading:
- Update to the latest version of Drupal 8.9.x
- Run the Upgrade Status module to identify deprecated code usage
- Update all contributed modules to Drupal 9 compatible versions
- Fix any custom code that uses deprecated APIs
- Ensure your hosting environment meets the new requirements (PHP 7.3+, MySQL 5.7.8+)
For New Sites
For new projects, we recommend waiting for the stable release of Drupal 9.0.0 unless you're specifically testing Drupal 9 compatibility or contributing to Drupal 9 development.
Testing Recommendation
This is a beta release and should not be used on production sites. It's intended for:
- Module developers to test and update their modules for Drupal 9 compatibility
- Site builders to test upgrade paths and identify potential issues
- Contributors to help find and fix bugs before the stable release
The upgrade from Drupal 8.9.x to Drupal 9.0.x is designed to be seamless, but thorough testing in a non-production environment is essential.
Bug Fixes
Core System Fixes
- Fixed issue where sites with missing schema information couldn't update to newer versions
- Fixed update process incorrectly running all historical updates
- Fixed dependency compatibility check not verifying if version is defined
- Fixed issue with config translation listing of fields causing WSOD
- Fixed issue with status report page showing WSOD when finding extensions missing core_version_requirement
Media and Content Fixes
- Fixed Media Library where 'save and insert' was unnecessarily nested in code
- Fixed issue with bulk deletion of already deleted nodes
- Fixed issue where hook_file_download was triggered when no file was requested
- Fixed views query alter for fields stored in dedicated tables
UI and Accessibility Fixes
- Fixed off-canvas elements filling up localStorage's quota causing errors
- Fixed focus styling of WYSIWYG field inputs for consistency with other inputs
- Fixed password confirm field getting the green focus ring cropped
- Fixed Seven theme's details/summary focus style in some browsers
- Fixed duplicate paragraph in Media Library help text
New Features
Enhanced Database Support
- Added support for contrib database driver directories in fixed module locations
- Improved support for PostgreSQL 9.6+ with optimized schema handling
- Added support for enclosing reserved words with brackets in database queries
Improved JavaScript Support
- Updated to jQuery 3.5.1 for better security and performance
- Upgraded to js.cookie 3 for improved cookie handling
- Added support for Node.js 12
Better Layout Management
- Layout plugins can now define default values for column widths
Enhanced Error Handling
- Improved logging for 403 access denied errors with detailed reason information
Security Updates
- Updated to jQuery 3.5.1 which includes important security fixes
- Fixed issue where hook_file_download was triggered when no file was requested, potentially exposing file information
- Improved error logging for 403 access denied errors with detailed reason information
- Fixed node grant access check missing cacheable dependency on node, which could potentially expose protected content
Authentication Improvements
- Fixed ProxyBuilder compatibility with Symfony 5, ensuring proper handling of authentication proxies
Performance Improvements
Database Performance
- Optimized PostgreSQL schema handling for version 9.6 and above
- Improved database query performance with better handling of reserved words
Build System Improvements
- Avoided re-scaffolding unchanged files during builds, reducing unnecessary operations
- Removed wikimedia/composer-merge-plugin for more streamlined dependency management
Cache Improvements
- Fixed node grant access check missing cacheable dependency on node, improving cache efficiency
JavaScript Optimizations
- Updated to jQuery 3.5.1 with performance improvements
- Upgraded js.cookie library to version 3 with better performance characteristics
Impact Summary
Drupal 9.0.0-beta3 represents a significant milestone in the Drupal 9 release cycle, focusing on code modernization, compatibility improvements, and technical debt reduction rather than introducing new features. This release makes Drupal compatible with newer dependencies like Symfony 5 and Composer 2, while also updating JavaScript libraries like jQuery to version 3.5.1.
The most impactful changes for developers include extensive updates to PHPUnit testing methods, improved database driver support, and better JavaScript dependency management. Site administrators will benefit from fixes to the update process, especially for sites with missing schema information, and improved error handling.
This beta release primarily addresses technical foundation issues rather than end-user features, preparing Drupal for a more maintainable and future-proof stable release. The changes ensure better compatibility with modern PHP practices and dependencies, while fixing numerous bugs and improving performance in key areas.
For anyone maintaining Drupal sites, this release signals the importance of preparing for the Drupal 9 upgrade by addressing deprecated code usage and ensuring compatibility with updated dependencies. While this is still a beta release not intended for production use, it provides a valuable opportunity to test upgrade paths and identify potential issues before the stable release.
Statistics:
User Affected:
- Improved compatibility with Composer 2
- Updated PHPUnit test methods to use modern assertions
- Better support for Symfony 5 components
- Improved database driver support with dedicated directories
- Fixed issues with database queries and connection handling
- Updated JavaScript dependencies including jQuery 3.5.1
