Crează un cont nou
This is an alpha release for the next feature release of Drupal 8. Alphas are good testing targets for developers and site builders who are comfortable reporting (and where possible, fixing) their own bugs. Alpha releases are not recommended for non-technical users, nor for production websites. More information on alpha and beta releases.
This minor release provides new improvements and functionality without breaking backward compatibility (BC) for public APIs. there may be changes in internal APIs and experimental modules that require updates to contributed and custom modules and themes per Drupal core's backwards compatibility and experimental module policies. Also see the change records for the 8.4.x branch.
Drush users: Update to Drush 8.1.12
Versions of Drush earlier than 8.1.12 will not work with Drupal 8.4.x. Update Drush to 8.1.12 before using it to update to Drupal core 8.4.x or you will encounter fatal errors.
Updated browser requirements: Internet Explorer 9 and 10 no longer supported
In April 2017, Microsoft discontinued all support for Internet Explorer 9 and 10. Therefore, Drupal 8.4 has as well. Drupal 8.4 still mostly works in these browser versions, but bugs that affect them only will no longer be fixed, and existing workarounds for them will be removed beginning in Drupal 8.5.
Additionally, Drupal 8's browser requirements documentation page currently lists incorrect information regarding very outdated browser versions such as Safari 5 and Firefox 5. Clarifications to the browser policy and documentation are underway and we hope to finalize it before 8.4.0-rc1.
- Drupal 8.4.0-alpha1 includes major version updates for two dependencies: Symfony 3.2 and jQuery 3. Both updates may introduce backwards compatibility issues for some sites or modules, so test carefully. For more information, see the "Third-party library updates" section below.
- Modal tour tips provided by the Tour module are not displayed correctly because the third-party Joyride library has an incompatibility with jQuery 3. Tour tips are no longer centered and may be displayed entirely off-screen for many screen sizes. Work is underway on an upstream bug fix.
- Some sites that have files with 0 recorded usages may encounter validation errors when saving content referencing these files. If your site's users report errors when saving content, you can set the
true, but make sure you also set "Delete orphaned files" to "Never" on
/admin/config/media/file-systemto avoid permanent deletion of the affected files.
Important fixes since 8.3.x
Translators should take note of several string additions and changes since the last release.
File usage tracking
Drupal 8 has several longstanding file usage tracking bugs. To prevent further data loss, Drupal 8.4 has disabled the automatic deletion of files with no known remaining usages. This will result of the accumulation of unused files on sites, but ensures that files erroneously reporting 0 usages are not deleted while in use. The change record explains how sites can opt back into marking files temporary. If you choose to enable the setting, you can also set "Delete orphaned files" to "Never" on
/admin/config/media/file-system to avoid permanent deletion of the affected files.
While the files will no longer be deleted by default, file usage is still not tracked correctly in several scenarios, regardless of the setting. Discussion on how to evolve the file usage tracking system is underway.
Configuration export sorting
- #2361539: Config export key order is not predictable for sequences, add orderby property to config schema resolves an issue where sequences in configuration were not sorted unless the code responsible for saving configuration explicitly performed a sort. This resulted in unpredictable changes in configuration ordering and confusing diffs even when nothing had changed. To resolve this issue, we've added an
orderbykey to the config schema that allows it to be sorted either by key or by value. Adding a preferred sort is strongly recommended.
- Two related issues remain open:
- #2860531: Add orderby key to third party settings relates to unsorted sequences which result in unexpected discrepancies in configuration during a configuration import.
- #2885368: Config export key order for sequences: "orderedby" does not support cases where the order actually matters relates to various sequences in core and contributed modules in which the source order is important.
Revision data integrity fixes
- Previously, data from draft revisions for path aliases, menus, and books could leak into the live site. Drupal 8.4.0-alpha1 hotfixes all three issues by preventing changes to this data from being saved on any revision that is not the default revision. These fixes improve revision support for both stable features and the experimental Content Moderation module.
- Correspondingly, Content Moderation now avoids such scenarios with non-default revisions by setting the 'default revision' flag earlier.
- Previously, saving a revision of an entity translation could cause draft revisions to go "missing". Drupal 8.4. prevents this by preventing the moderation state from being set to anything that would make the revision go "missing". A similar but unrelated bug in Content Moderation has also been fixed in this release.
New stable modules
The following modules, previously considered experimental, are now stable and safe for use on production sites, with full backwards compatibility and upgrade paths from 8.4.0 to future releases:
The Datetime Range module provides a field type that allows end dates to support contributed modules like Calendar. This stable release is backwards-compatible with the 8.3.x experimental version and shares a consistent API with other Datetime fields.
Future releases may improve Views support, usability, Datetime Range field validation, and REST support. For bugs or feature requests for this module, see the core Datetime issue queue.
The Layout Discovery module provides an API for modules or themes to register layouts as well as five common layouts. Providing this API in core enables core and contributed layout solutions to be compatible with each other. This stable release is backwards-compatible with the 8.3.x experimental version and introduces support for per-region attributes.
Since there is a rich ecosystem of Drupal contributed modules built on Media Entity, the top priority for this release is to provide a stable core API and data model for a smoother transition for these modules. Developers and expert site builders can now add Media as a dependency. Work is underway to provide an update path for existing sites' Media Entity data and to port existing contributed modules to the refined core API.
Note that the core Media module is currently marked hidden and will not appear on the 'Extend' (module administration) page. (Enabling a contributed module that depends on the core Media module will also enable Media automatically.) The module will be displayed to site builders normally once user experience issues with it are resolved in a future release.
Similarly, the REST API and normalizations for Media is not final and support for decoupled applications will be improved in a future release.
Inline Form Errors
The Inline Form Errors module provides a summary of any validation errors at the top of a form and places the individual error messages next to the form elements themselves. This helps users understand which entries need to be fixed, and how. Inline Form Errors was provided as an experimental module from Drupal 8.0.0 on, but it is now stable and polished enough for production use. See the core Inline Form Errors module issue queue for outstanding issues.
Content authoring and site administration improvements
- The "Save and keep (un)published" dropbutton has been replaced with a "Published" checkbox and single "Save" button. The "Save and..." dropbutton was a new design in Drupal 8, but users found it confusing, so we have restored a design that is more similar to the user interface for Drupal 7 and earlier.
- Previously, deleting a field on a content type would also delete any views depending on the field. While the confirmation form did indicate that the view would be deleted, users did not expect the behavior and often missed the message, leading to data loss. Now, the view is disabled instead. In the future, we intend to notify users that configuration has been disabled (as in this fix) as well as give users clearer warnings for other highly destructive operations.
- The Drupal toolbar no longer flickers during page rendering, thus improving perceived front-end performance.
- Options in timezones selector are now grouped by regions and labeled by cities instead of timezone names, making it much easier for users to find and select the specific timezone they need.
- Both the "Comments" administration page at
/admin/content/commentand the "Recent log messages" report provided by dblog are now configurable views.
- Useful meta information about a node's status is typically displayed at the top of the node sidebar. Previously, this meta information was provided by the Seven theme, so it was not available in other administrative themes. This meta information is now provided by node.module itself so other administration themes can access it.
REST and API-first improvements
- Authenticated REST API performance increased by 15% by utilizing the Dynamic Page Cache.
- POSTing entities can now happen at
/taxonomy/termand so on, instead of
/entity/taxonomy_term. Instead of confusingly different URLs, they therefore now use the URLs you'd expect. Backwards compatibility is maintained.
- There is now a dedicated resource for resetting a user's password.
- Time fields now are normalized to RFC3339 timestamps by default, fixing time ambiguity. Existing sites continue to receive UNIX timestamps, but can opt in. See the change record for more information about backwards compatibility and on how to opt in.
- Path alias fields now are normalized too. See the change record for information about how this impacts API-first modules and other features relying on serialized entities.
- When denormalization fails, a 422 response is now returned instead of a 400, per the HTTP specification.
- With CORS enabled to allow origins besides the site's own host, submitting forms was broken unless the site's own host was also explicitly allowed.
- Fatal errors and exceptions now show a backtrace for all non-HTML requests as well as HTML requests, which makes for easier debugging and better bug reports.
- Massive expansion of test coverage.
Performance and scalability improvements
- The internal page cache now has a dedicated cache bin distinct from the rest of the render cache (a significant scalability improvement).
- The service collector pattern instantiates all services it collects, which is expensive, and unnecessary for some use cases. For those use cases, a new service ID collector pattern was added. The theme negotiator was updated to use it. See the change record for information about how to use the service ID collector for improved performance.
- The maximum time in-progress forms are cached is now customizable rather than being limited to a default cache lifetime of 6 hours. Sites can decrease the lifetime to reduce cache footprint, or increase it if needed for a particular site's usecase. See the change record to learn how to access this new setting.
- If there are no status messages, the corresponding rendering is now skipped. On simple sites, this can result in a 10% improvement when there are no messages!
- Optimized the early Drupal installer to check whether any themes are installed first before invoking an unnecessary function, which improves Drupal install time measurably for both sites and automated tests.
Developer experience improvements
- Field type definitions can now enforce the cardinality of the field. See the change record for information about how to specify a cardinality via the annotation.
- Added new methods to make getting typed configuration entity representations easier. See the change record for more information about how to invoke these methods.
html_tagrender element now supports nested render arrays, enabling the creation of dynamic SVGs. See the change record for information about how you can use this in your theme.
- Added more helpful errors when CSS is not properly nested under an existing category in asset libraries.
- Also see the change records for the 8.4.x branch for other changes for developers.
Automated testing improvements
- PHPUnit has been updated from 4.8.28 to 4.8.35 in order to incorporate a forward compatibility layer for PHPUnit 4.8, useful during a future migration to PHPUnit 5 or PHPUnit 6.
- Many former WebTestBase tests were converted to BrowserTestBase. Track current progress.
- The default approach for testing deprecated code has changed to require use of the Drupal core deprecation policy (
@trigger_error()) to mark code deprecated; otherwise a test error will be thrown. See the change record for information about how to update
phpunit.xmland how to test deprecated code.
- Resolved random test failures due to ResourceTestBase's HTTP client timeout of 30 seconds.
Third-party library updates
- Drupal's Symfony dependency has been updated from Symfony 2.8 to Symfony 3.2. This major version update is necessary because Symfony 2.8 support will end around the release of Drupal 8.6.0 next year. See the change record for information about Symfony 3 backwards compatibility breaks that affected Drupal core. Drupal 8 also requires Symfony 3.2.8 because of a bug in Symfony 3.2.7.
- zendframework/zend-diactoros has been updated from 1.3.10 to 1.4.0.
- jQuery UI has been updated from 1.11.4 to 1.12.1.
- CKEditor has been updated from 4.6.2 to 4.7.1.
- asm89/stack-cors has been updated from 1.0 to 1.1.
Migrate (beta stability)
Migrate provides a general API for migrations. It will be considered completely stable once all issues tagged Migrate critical are resolved.
migrationprocess plugin to
iteratorprocess plugin to
sub_processto better capture their purposes. (Backwards compatibility is provided for both process plugins since Migrate is in beta.)
Migrate Drupal and Migrate Drupal UI (alpha stability)
Migrate Drupal module provides API support for Drupal-to-Drupal migrations, and Migrate Drupal UI offers a simple user interface to run migrations from older Drupal versions.
- This release adds date and node reference support for Drupal 6 to 8 migrations.
- Core provides migrations for most Drupal 6 data and can be used for migrating Drupal 6 sites to Drupal 8, and the Drupal 6 to 8 migration path is nearing beta stability. Some gaps remain, such as for some internationalization data. (Outstanding issues for the Drupal 6 to Drupal 8 migration)
- The Drupal 7 to Drupal 8 migration is incomplete but is suitable for developers who would like to help improve the migration and can be used to test upgrades especially for simple Drupal 7 sites. Most high-priority migrations are available. (Outstanding issues for the Drupal 7 to Drupal 8 migration)
- Drush support for Migrate is currently only available in the Drupal Upgrade contributed module. (See the pull request to add support to Drush.)
- Added field plugin to handle migration of node reference field values from Drupal 6 to Drupal 8.
- Added date field plugin to handle migration of CCK date fields in Drupal 6 to Drupal 8.
- Renamed migration field plugins and classes referring to custom fields provided by the Drupal 6 module CCK, which was replaced in Drupal 7 by the core Field API. See the change record for more information about how this impacts your migration plugins.
Workflows (beta stability)
The Workflows module provides an abstract system of states (like Draft, Archived, and Published) and transitions between them. Workflows can be used by modules that implement non-publishing workflows (such as for users or products) as well as content publishing workflows.
Drupal 8.4 introduces a final significant backwards compatibility and data model break for this module, moving responsibility for workflow states and transitions from the Workflow entity to the Workflow type plugin. Read Workflow type plugins are now responsible for state and transition schema for full details on the API and data model changes related to this fix. Now that this change is complete, the Workflows module has reached beta stability, and it may furthermore be marked stable in time for Drupal 8.4.0!
Content Moderation (beta stability)
Content Moderation allows workflows from the Workflows module to be applied to content. Content Moderation has beta stability in 8.4.0-alpha1, but may become stable in time for 8.4.0! Notable improvements in this release:
- Workflow states are now selected from a select list, rather than under a drop-button, which represents a significant usability improvement.
- Now that workflows can be applied to any revisionable entity type, Content Moderation adds entity type checkboxes to the workflow form. This allows site administrators to configure which entity types should have the workflow at the same time as they configure the workflow itself, for a more intuitive user experience.
- Content Moderation now prevents the deletion of workflows that are currently in use to prevent fatal errors and data integrity problems.
- The confusing terminology of "forward revisions" has been replaced with that of "pending revisions". If your contributed module refers to revisions that are not yet published, it should use this new term.
Field Layout (alpha stability)
This module provides the ability for site builders to rearrange fields on content types, block types, etc. into new regions, for both the form and display, on the same forms provided by the normal field user interface. Field Layout has had several bugfixes since 8.3.0, but no significant changes. See the entity display layout roadmap for the next steps for this module, which needs to become stable by 8.5.0 to remain in Drupal core.
Settings Tray (alpha stability)
The Settings Tray module allows configuring page elements such as blocks and menus from the frontend of your site. Settings Tray has improved significantly since Drupal 8.3.0. The goal for this release is to get Settings Tray to beta stability. Only two issues remain before that milestone: to move the off-canvas dialog renderer into a core component, and to rename the machine name of the module to settings_tray, to match its user-facing name. We hope to make Settings Tray stable by 8.5.0. To track progress, see the "outside in" roadmap issue.
- A CSS reset has been added to the Settings Tray to improve the themer experience.
- Form validation messages now appear in the Settings Tray instead of main page.
- The toolbar background in Edit mode now matches the edit button, instead of the white background that many users found distracting or misunderstood to be an indication that something was broken.
- The block title field in the tray is now labeled more clearly and only shown when the block title itself is shown.
- In the contextual links, "Quick edit" is now listed before "Configure", and the custom blocks instead have a "Quick edit settings" link (to distinguish them from the links provided by the Quick Edit module, which allow editing the content of the custom block itself).
- Edit mode now behaves the same way whether accessed by clicking "Quick edit" or clicking through the toolbar
- Users can now escape from Edit mode with the ESC key, for better accessibility.
Place Blocks (alpha stability)
This feature allows the user to place a block on any page and see the region where it will be displayed, without having to navigate to a backend administration form. 8.4.0-alpha1 was the deadline for Place Blocks to stabilize, but the module's roadmap was not completed. Furthermore, the module is not intended as a standalone feature and should instead be a built-in part of the Block system. For these reasons, Place Blocks module has been marked hidden in this release (it can still be enabled with Drush). The Place Blocks module itself will be turned into an empty module in Drupal 8.5.x, since ideally the core Block system will offer the same functionality in 8.5.0 (though this depends on completion of a core patch for the feature.)