Problem/Motivation

#2830740: Allow workflow types to lock certain changes to workflows once things are in use introduced workflowHasData and workflowStateHasData in order to ensure users were not able to delete workflows or states that had entity moderation data associated with them. With those methods, two things happened:

  1. workflows.module then uses these methods to alter the UI of delete forms.
  2. content_moderation.module implemented an onConfigImporterValidate event subscriber to ensure these states and workflows would stick around.

The questions here is, why do these two methods belong on the @WorkflowType interface? They don't really do anything beyond what is already possible with the access system.

Proposed resolution

Attempt 1:

The @WorkflowType plugin already has an access method for states and workflows which allow implementers to restrict deletions, checkWorkflowAccess. Instead of adding two new methods which hold very similar responsibilities to the access method, lets just use the access system for restricting what users have access to.

From an API perspective, users would no longer have to check $workflow->access(...) as well as $workflow->getTypePlugin()->workflowHasData() in order to check if a user really was allowed to delete something.

  1. Continue to allow users to access the workflow/state delete forms when state/workflow delete "access" is forbidden (as per current behavior in the form of workflowHasData/workflowStateHasData).
  2. Remove workflowHasData/workflowStateHasData from WorkflowTypeInterface.
  3. Leave these methods on the ContentModeration plugin, for it's own use internally in ::checkWorkflowAccess and beyond.

That ensures the UX is completely unchanged, and this issue becomes an API clean-up.

Attempt 2:

Instead of removing the two methods, why not introduce the semantics in content_moderation (the config validator) into workflows as a feature of the @WorkflowType plugin. That is, use these two methods to check if a workflow or state should be protected from deletion, not because of a users access, but because there is other data associated with those things.

Remaining tasks

Agree.

User interface changes

None.

API changes

Two @internal methods to become @api.

Data model changes

None.

Comments

Sam152 created an issue. See original summary.

sam152’s picture

Priority: Normal » Major

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

Drupal 8.4.0-alpha1 will be released the week of July 31, 2017, which means new developments and disruptive changes should now 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.

sam152’s picture

Title: Ensure workflows or states that are locked are done so using the access system » Explore if it makes sense to use the access system for disallowing users to delete "locked" states

Updating the name of the issue for clarity. This was always going to be a "lets see if this makes more sense".

timmillwood’s picture

@Sam152 I really liked your suggestions in #2830740: Allow workflow types to lock certain changes to workflows once things are in use and think this would be good, it should not block stable, and should be fine to go in 8.5.x

sam152’s picture

Assigned: Unassigned » sam152

Having a look at this. Agree, based on the methods being @internal, this isn't a blocker.

sam152’s picture

Status: Active » Needs review
StatusFileSize
new11.86 KB

Here is what I had in mind for this. The UI and behaviour should be exactly the same. Depending on UX implications we could also allow the required states to reach the delete form, with some explanation that they are essential for the workflow etc.

sam152’s picture

Assigned: sam152 » Unassigned

Status: Needs review » Needs work

The last submitted patch, 7: 2897148-access-system-for-ui-delete-7.patch, failed testing. View results
- codesniffer_fixes.patch Interdiff of automated coding standards fixes only.

sam152’s picture

Issue summary: View changes
Status: Needs work » Needs review
StatusFileSize
new3.33 KB
new13.04 KB

Fixed tests and issue summary update. One issue with this approach is the docblock on top of \Drupal\Core\Access\AccessResult::forbidden:

   * @param string|null $reason
   *   (optional) The reason why access is forbidden. Intended for developers,
   *   hence not translatable.

While this is intended for devs, it really nicely fits the use case of displaying a message in the UI. (string) $this->t(...) would probably resolve the issue technically, but would still be considered an abuse?

sam152’s picture

Issue summary: View changes
sam152’s picture

Issue summary: View changes
wim leers’s picture

+++ b/core/modules/workflows/src/WorkflowTypeInterface.php
@@ -46,38 +46,6 @@ public function label();
-  public function workflowHasData(WorkflowInterface $workflow);
...
-  public function workflowStateHasData(WorkflowInterface $workflow, StateInterface $state);

This is an API change, which means this would need to happen before the beta. If it happens post-beta, you'll at most be able to mark this @deprecated.

Does that mean this is WI Critical?

timmillwood’s picture

I think if this doesn't get in before 8.4.0 we update the patch to @deprecate these methods, until then we can assume it will be in 8.4.0 and we can delete these methods.

If that is the direction we want to go, IIRC it was discussed in #2830740: Allow workflow types to lock certain changes to workflows once things are in use that we keep those methods even if we move to an access based solution.

sam152’s picture

+++ b/core/modules/workflows/src/WorkflowTypeInterface.php
@@ -46,38 +46,6 @@ public function label();
-   * @internal
-   *   Marked as internal until it's validated this should form part of the
-   *   public API in https://www.drupal.org/node/2897148.
...
-   * @internal
-   *   Marked as internal until it's validated this should form part of the
-   *   public API in https://www.drupal.org/node/2897148.

We marked these as @internal in the previous issue so we could take enough time to validate/discuss this.

We're also leaving them on the content moderation workflow type, they are used for the config import validator. This patch is purely to change the workflows based UI restrictions to use the access system and to remove the two extra methods from their interface.

timmillwood’s picture

  1. +++ b/core/modules/workflows/src/Form/WorkflowEditForm.php
    @@ -119,7 +119,7 @@ public function form(array $form, FormStateInterface $form_state) {
    +      if (!in_array($state->id(), $workflow_type->getRequiredStates()) && count($states) !== 1) {
    

    This logic is now a duplicate of what is in \Drupal\workflows\WorkflowAccessControlHandler::checkAccess.

  2. +++ b/core/modules/workflows/src/Form/WorkflowEditForm.php
    @@ -264,6 +264,17 @@ public function save(array $form, FormStateInterface $form_state) {
    +    unset($actions['delete']['#access']);
    

    If we had specific a specific "delete workflows" permission I'd question this, but we only have "administer workflows", so I guess it's ok.

  3. +++ b/core/modules/workflows/src/WorkflowTypeInterface.php
    @@ -46,38 +46,6 @@ public function label();
    -  public function workflowHasData(WorkflowInterface $workflow);
    ...
    -  public function workflowStateHasData(WorkflowInterface $workflow, StateInterface $state);
    

    So these are now ContentModeration specific methods?

sam152’s picture

#16.1: The previous issue implemented a UI pattern where you could see the delete links for states which where blocked with hasData but not for the states which were blocked because they were required or if there was one, so this is largely a work-around to say "all these kind of states are blocked from being deleted" and "these special kind of states have their delete button hidden".

I think reasonable follow-up to this would be to make it consistent for all states. Ie, for states which are required or if the state is the last one, you get the same UI pattern that denies people access to those states because they have data. That is, you try to delete it and you are given a message as to why you can't. I wanted to keep the UI discussion out of this issue though, hence implementing the work-around to match it exactly 1 for 1.

I'm still not totally sure about the approach, based on the messages in the access results specifically saying "for developer use only", but I'd be interested in exploring why this is and what the ramifications of exposing them are.

sam152’s picture

Status: Needs review » Needs work

NW based on further investigation from #17.

Also, I think we can safely defer this to 8.5, given the API changes being made are @internal methods. Lets focus on the API breaking changes that can't change after stable.

wim leers’s picture

#15: d'oh, I missed that — but that's great news! :)

#16: great points, thanks for the review! On point 2: note that contrib/custom code could alter the access checking for workflows, which means it could introduce additional permissions, which means your point/concern actually still stands.

#18: You'd be right if this was only potentially removing two @internal methods. But this patch is also removing WorkflowDeleteAccessCheck, which is a service that is not marked @internal. That change would not be allowed in 8.5, unless it'd be marked @internal. I think you could create a separate issue to mark that class @internal, and add a @todo Remove this service and class in https://www.drupal.org/node/2897148, i.e. refer back to this issue. Then this issue can safely remove it, or if it ends up changing direction, it could remove the @internal.

sam152’s picture

wim leers’s picture

Title: Explore if it makes sense to use the access system for disallowing users to delete "locked" states » [PP-1] Explore if it makes sense to use the access system for disallowing users to delete "locked" states
Related issues: +#2900634: Mark WorkflowDeleteAccessCheck @internal until a UI pattern for access-restricted states has been established

👍

RTBC'd.

wim leers’s picture

larowlan’s picture

Title: [PP-1] Explore if it makes sense to use the access system for disallowing users to delete "locked" states » Explore if it makes sense to use the access system for disallowing users to delete "locked" states

Blocker has been resolved

sam152’s picture

Assigned: Unassigned » sam152

Having stewed on this for a few days, I've got some more thoughts. My initial reaction for thinking this was so important was because from the perspective of the workflows module in isolation, implementing these methods doesn't add any guarantees beyond what the state/workflow access checks already give you. They only stop you from deleting the state/workflow from the UI, something access already handles nicely.

The alternative to this is to remove the @internal from these methods but also move \Drupal\content_moderation\EventSubscriber\ConfigImportSubscriber to workflows. That way the methods have some good utility on the WorkflowType interface, they protect the integrity of your content/configuration. In a few of the use-cases I have in my head, this would actually be a kinda useful feature.

I've also just noticed ConfigImportSubscriber in content_moderation doesn't actually check the workflow type, so when enabled it actually provides this level protection to all workflow types (helpful right?). Also, the code in here is really non-trivial, meaning we have more of a reason to support these methods being part of the workflow type plugin, as reproducing the functionality would be a total headache.

Sorry for the total 180 on this issue. I'm going to see what the above looks like in a patch.

amateescu’s picture

@Sam152, I'm glad you changed your mind about the general usefulness of these methods :) Here's another place where we need them: #2904101: Do not allow modules that provide a workflow type plugin with existing data to be uninstalled

wim leers’s picture

wim leers’s picture

I'm not sure I fully understand #24. Is it saying that rather than using the entity access system, it should use a \Drupal\Core\Config\ConfigEvents::IMPORT_VALIDATE event subscriber?

Perhaps it's because I've been out of Drupal for a week, but I'm really having a hard time grokking #24 — I'd appreciate it if you could elaborate. Or perhaps update the IS with your new thinking (while keeping the old thinking mentioned and explaining your reasons for changing — this also helps core committers, see #2824851-107: EntityResource::patch() makes an incorrect assumption about entity keys, hence results in incorrect behavior for example).

sam152’s picture

StatusFileSize
new4.25 KB

Re: #27 maybe some of the understanding is wrapped up in #2830740: Allow workflow types to lock certain changes to workflows once things are in use.

content_moderation already introduced the event subscriber and the workflowStateHasData/workflowHasData methods in order protect states and workflows from being deleted when there was moderated content associated with them. If you look at the patch from the linked issue and only show the workflows.module part (attached), all it does with the additional methods is wrap some of the UI elements to make sure they cannot be deleted. The reason I opened this issue is because the access system already does exactly this, so as an implementor there'd be no real difference between adding some access checks and implementing these hasData methods.

The alternative is provide the same feature content_moderation implements, config validation to ensure these states and workflows cannot be removed, but for all @WorkflowTypes that implement those methods. Hence they become useful beyond what you could accomplish with access control and could form part of the public API with some valid distinction between the access system already in place.

Hope that makes some more sense.

timmillwood’s picture

I think it makes sense to move the config import event subscriber to Workflows, I'm not sure why it was put in Content Moderation in the first place.

sam152’s picture

Status: Needs work » Needs review
Issue tags: +Needs issue summary update
StatusFileSize
new12.5 KB

As per #27, the IS needs some serious finessing. I'll take a look at that in the morning.

Here is the start of a patch. I think ContentModerationWorkflowConfigTest can and should be replaced entirely with a much simpler test that asserts the return values of workflowHasData/workflowStateHasData but for now at least, it's useful to make sure the behaviour didn't change moving this from CM to workflows.

sam152’s picture

StatusFileSize
new12.57 KB

Reroll.

sam152’s picture

Issue summary: View changes
Issue tags: -Needs issue summary update

Here is an IS update which covers the two trains of thought.

sam152’s picture

Assigned: sam152 » Unassigned
sam152’s picture

Title: Explore if it makes sense to use the access system for disallowing users to delete "locked" states » Remove @internal from workflowHasData/workflowStateHasData and use those methods for configuration validation.
wim leers’s picture

Status: Needs review » Needs work

#28: thank you, that helped a lot!

  1. +++ b/core/modules/workflows/src/WorkflowTypeInterface.php
    @@ -31,10 +31,6 @@ public function label();
    -   * @internal
    -   *   Marked as internal until it's validated this should form part of the
    -   *   public API in https://www.drupal.org/node/2897148.
    
    @@ -46,10 +42,6 @@ public function workflowHasData(WorkflowInterface $workflow);
    -   * @internal
    -   *   Marked as internal until it's validated this should form part of the
    -   *   public API in https://www.drupal.org/node/2897148.
    

    So we're officially making these non-internal. Makes sense. But can we then add @see \Drupal\workflows\EventSubscriber\ConfigImportSubscriber, to make it clear what this being used for?

  2. +++ b/core/modules/workflows/tests/modules/workflow_type_test/src/Plugin/WorkflowType/HasDataTestType.php
    @@ -0,0 +1,35 @@
    +    $workflows_with_data = \Drupal::state()->get('workflows.workflows_with_data');
    ...
    +    $states_with_data = \Drupal::state()->get('workflows.workflow_states_with_data');
    

    Let's make these strings constants. Will make the test more robust.

So the patch in #31 is now just moving the config import validation from content_moderation to workflows and adding test coverage.


BUT…

+++ b/core/modules/workflows/src/Form/WorkflowDeleteForm.php
@@ -15,9 +15,10 @@ class WorkflowDeleteForm extends EntityConfirmFormBase {
-    if ($this->entity->getTypePlugin()->workflowHasData($this->entity)) {
+    $access = $this->entity->access('delete', NULL, TRUE);
+    if (!$access->isAllowed()) {
...
-      $form['description'] = ['#markup' => $this->t('This workflow is in use. You cannot remove this workflow until you have removed all content using it.')];

That this error message is still UI/form/render-specific.

Therefore when this action is attempted to be performed via REST in the future, it won't get a similar error message.

This is why it's wrong/problematic from an API-First point of view to have error checking + error messages hardcoded in the UI rather than in the underlying logic.

IOW: in HEAD, business logic is coupled to UI logic, this change is decoupling them, allowing the same logic to also be applied for API-First purposes.

Therefore I think we should also still do what the patches prior to the new approach were doing.


Sorry!

sam152’s picture

Thanks for the review. I'm glad these are @internal and we can take our time to sort it out. It seems like we need some combination of the two, REST support was one of the reasons I was pushing for the original solution, so it only makes sense to include it as well.

wim leers’s picture

I'm glad these are @internal and we can take our time to sort it out.

Exactly! :)

amateescu’s picture

Re #35:

So we're officially making these non-internal. Makes sense. But can we then add @see \Drupal\workflows\EventSubscriber\ConfigImportSubscriber, to make it clear what this being used for?

These methods are also used in </code> and #2904101: Do not allow modules that provide a workflow type plugin with existing data to be uninstalled adds another usage. Do we really need to add <code>@see to every usage of a public method? And if not, how do we determine which usages are more important than others?

Let's make these strings constants. Will make the test more robust.

I don't agree with this.. We use this pattern of state set/get in dozens of test and I've never seen any of them using constants..

As for the patch itself, am I the only one who thinks it's weird that both of these methods receive a workflow entity as their first argument? I would have expected to have that passed-in automatically somehow..

sam152’s picture

These are the only methods which are really concerned about the thing-being-moderated directly, the rest of the methods mostly just provide details around what's possible in the workflow. I suppose if a plugin was instantiated somehow without the workflow entity as the storage, these wouldn't make much sense.

Having a look at the feedback and access controller now.

sam152’s picture

Status: Needs work » Needs review
StatusFileSize
new7.41 KB
new19.59 KB

Adding the access control back in and addressing some of the feedback.

The tests that assert you're allowed to visit the "delete" pages of the state and workflow, even if you aren't allowed to delete them will fail. Not sure how to deal with that yet, revert the UI pattern or emulate it by removing all the access off those routes.

sam152’s picture

StatusFileSize
new1.63 KB
new19.92 KB

Fixing a bug and adding a test case for it.

+++ b/core/modules/content_moderation/tests/src/Functional/ModerationFormTest.php
@@ -451,4 +451,53 @@ public function testContentTranslationNodeForm() {
+    // The workflow is being used, so can't be deleted.
+    $this->drupalGet($paths['editorial_workflow']);
+    $this->assertSession()->buttonNotExists('Delete');
...
+    // Now the archived state is being used so it can not be deleted either.
+    foreach ($paths as $path) {
+      $this->drupalGet($path);
+      $this->assertSession()->buttonNotExists('Delete');
+    }

The reason this test isn't failing is because it doesn't assert the warning message about the state/workflow having data exists for this page. It only asserts there is no button, which is also TRUE for a 403.

sam152’s picture

I wonder if fixing the test should be a seperate issue, so it doesn't look like this patch goes to great lengths to introduce a new UI pattern when it actually already exists?

sam152’s picture

Opened #2910715: The assertions in ModerationFormTest::testWorkflowInUse are inadequate to keep this issue focused. Will retest #41 once that's in.

sam152’s picture

StatusFileSize
new19.92 KB

This should now fail.

Status: Needs review » Needs work

The last submitted patch, 44: 2897148-41.patch, failed testing. View results

sam152’s picture

Issue tags: +Needs change record
sam152’s picture

Status: Needs work » Needs review
StatusFileSize
new4.13 KB
new23.48 KB

Fixing the test.

sam152’s picture

+++ b/core/modules/workflows/tests/src/Kernel/WorkflowAccessControlHandlerTest.php
@@ -212,6 +233,33 @@ public function checkAccessProvider() {
+          ->addCacheContexts([]), // @todo, should these be uncacheable?
...
+          ->addCacheContexts([]), // @todo, should these be uncacheable?
...
+          ->addCacheContexts(['user.permissions']), // @todo, should these be uncacheable?

This is the last thing I'm unsure about. These decisions are based on calls to hasData methods. We don't know what cacheability exists behind the checks in these methods, so unless we were able to return metadata with these methods themselves, the whole access check is uncacheable.

sam152’s picture

Title: Remove @internal from workflowHasData/workflowStateHasData and use those methods for configuration validation. » Remove @internal from workflowHasData/workflowStateHasData and use those methods for access control and configuration validation.

Status: Needs review » Needs work

The last submitted patch, 47: 2897148-47.patch, failed testing. View results

sam152’s picture

Status: Needs work » Needs review
StatusFileSize
new2.85 KB
new26.33 KB

Fixing some more tests. Required states are still access denied, but the page can now be visited just like states with data. We still don't show the "Delete" link on the workflows UI, so from a users perspective the UI is the same before and after this patch.

sam152’s picture

NW for #48.

sam152’s picture

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

#48

+++ b/core/modules/workflows/tests/src/Kernel/WorkflowAccessControlHandlerTest.php
@@ -212,6 +233,33 @@ public function checkAccessProvider() {
+          ->addCacheContexts([]), // @todo, should these be uncacheable?
...
+          ->addCacheContexts([]), // @todo, should these be uncacheable?
...
+          ->addCacheContexts(['user.permissions']), // @todo, should these be uncacheable?

This is the last thing I'm unsure about. These decisions are based on calls to hasData methods. We don't know what cacheability exists behind the checks in these methods, so unless we were able to return metadata with these methods themselves, the whole access check is uncacheable.

\Drupal\content_moderation\Plugin\WorkflowType\ContentModeration::workflowHasData() and \Drupal\content_moderation\Plugin\WorkflowType\ContentModeration::workflowStateHasData() both do entity queries, and then return a boolean. What's missing here, are entity list cache tags — in this case: content_moderation_state_list.

This cache tag is technically associated with the boolean that is returned: the boolean might change whenever the list cache tag is invalidated. Which means that technically, the return value should not be bool but CacheableBool. With:

class CacheableBool implements RefinableCacheableDependencyInterface {

  use RefinableCacheableDependencyTrait;

  …
}

but doing that would change the signature of \Drupal\workflows\WorkflowTypeInterface::workflowHas(State)Data, and hence cause a BC break.

So you have two options:

  1. The strategy used by \Drupal\Core\Access\AccessibleInterface::access(): add an optional $return_as_object = FALSE parameter, which by default returns just the boolean, and if the caller opts in, returns the boolean plus cacheability metadata.
  2. Hardcode the list cache tag in the access control handler.
sam152’s picture

Re: #54, CacheableBool is exactly what we need, thank you! Is this something that already exists or would this be the first usecase for it?

Hard coding the list cache tags is out of the question because workflow(State)HasData methods on a plugin interface and can thus will be based on various other things for different workflow types.

The good news is, these methods are @internal, so we can safely change the signature as required.

sam152’s picture

On alternative I can also see is to pass in some param, which the user could then add stuff to and not have to create an object to return:

public function workflowHasData(WorkflowInterface $workflow, CacheableMetadata $metadata);

I suppose it'd be similar to BubbleableMetadata being passed to hook_tokens for example. I do worry that if this issue introduces CacheableBool which is only required/integrated with these methods, it could be really confusing for the rest of the Drupal. For example why wouldn't a factory on AccessResult support passing a CacheableBool instead of a primitive? What utility is expected out of CacheableBool as a return type for cache-related things.

sam152’s picture

Status: Needs work » Needs review
StatusFileSize
new15.21 KB
new32.92 KB

Implementing #56 to see what that looks like. Reviews very much welcome :)

sam152’s picture

StatusFileSize
new2.48 KB
new35.41 KB

Restoring the links to the workflow/state delete forms so this issue doesn't introduce any UI changes.

timmillwood’s picture

Assigned: Unassigned » sam152

There's a few coding standards issues as mentioned in https://www.drupal.org/pift-ci-job/790541, but once done I think we're ready for RTBC.

Assigning to Sam152 to complete the updates.

sam152’s picture

Assigned: sam152 » Unassigned
StatusFileSize
new3.77 KB
new35.48 KB

Fixing.

timmillwood’s picture

Status: Needs review » Reviewed & tested by the community

Thanks @sam152!

sam152’s picture

Woohoo! Thanks for the review @timmillwood.

larowlan’s picture

Status: Reviewed & tested by the community » Needs work
  1. +++ b/core/modules/workflows/src/Form/WorkflowEditForm.php
    @@ -119,7 +119,10 @@ public function form(array $form, FormStateInterface $form_state) {
    +      if (!in_array($state->id(), $workflow_type->getRequiredStates()) && count($states) !== 1) {
    

    We should use the third arg for in_array here because these are strings

  2. +++ b/core/modules/workflows/src/Plugin/WorkflowTypeBase.php
    @@ -46,14 +47,14 @@ public function label() {
    +  public function workflowHasData(WorkflowInterface $workflow, RefinableCacheableDependencyInterface $cacheability_metadata) {
    ...
    +  public function workflowStateHasData(WorkflowInterface $workflow, StateInterface $state, RefinableCacheableDependencyInterface $cacheability_metadata) {
    

    This is an API break on a non-internal class in a stable module, so we need to support passing NULL unfortunately. And we need tests for that too.

  3. +++ b/core/modules/workflows/src/WorkflowAccessControlHandler.php
    @@ -54,17 +55,25 @@ public function __construct(EntityTypeInterface $entity_type, PluginManagerInter
    +    elseif ($operation === 'delete' && $workflow_type->workflowHasData($entity, $workflow_has_data_cacheability)) {
    ...
    +    else {
    

    I prefer returning early over if/elseif/else.

    I think that will make this tidier and easier to read

larowlan’s picture

Issue tags: +DrupalSouth 2017
sam152’s picture

Status: Needs work » Needs review
StatusFileSize
new3.23 KB
new35.71 KB

1. Fixed.
2. Both the changed methods are currently marked @internal, is that enough here?
3. Refactored into early returns. Added a comment to a part of this that became a little less clear.

larowlan’s picture

2. Ah sorry, I missed that the method was internal, I only checked the class - all good.

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

Drupal 8.5.0-alpha1 will be released the week of January 17, 2018, which means new developments and disruptive changes should now 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.

sam152’s picture

I think I'll try pick this back up as soon as #2896726: Expand the entity access model for workflow states and transitions. is in. The two conflict quite heavily, but I think it would be great integrity features CM adds to all workflow types.

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

Drupal 8.6.0-alpha1 will be released the week of July 16, 2018, which means new developments and disruptive changes should now 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.7.x-dev » 8.8.x-dev

Drupal 8.7.0-alpha1 will be released the week of March 11, 2019, which means new developments and disruptive changes should now be targeted against the 8.8.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.8.x-dev » 8.9.x-dev

Drupal 8.8.0-alpha1 will be released the week of October 14th, 2019, which means new developments and disruptive changes should now be targeted against the 8.9.x-dev branch. (Any changes to 8.9.x will also be committed to 9.0.x in preparation for Drupal 9’s release, but some changes like significant feature additions will be deferred to 9.1.x.). 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.1.x-dev

Drupal 8.9.0-beta1 was released on March 20, 2020. 8.9.x is the final, long-term support (LTS) minor release of Drupal 8, which means new developments and disruptive changes should now 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: 9.1.x-dev » 9.2.x-dev

Drupal 9.1.0-alpha1 will be released the week of October 19, 2020, which means new developments and disruptive changes should now be targeted for the 9.2.x-dev branch. For more information see the Drupal 9 minor version schedule and the Allowed changes during the Drupal 9 release cycle.

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

Drupal 9.2.0-alpha1 will be released the week of May 3, 2021, which means new developments and disruptive changes should now be targeted for the 9.3.x-dev branch. For more information see the Drupal core minor version schedule and the Allowed changes during the Drupal core release cycle.

kristen pol’s picture

Status: Needs review » Needs work
Issue tags: +DrupalSouth, +Needs reroll

Patch does not apply to 9.3:

KristenBackupMBP:drupal-9.3.x-dev admin$ patch -p1 < 2897148-66.patch 
patching file core/modules/content_moderation/content_moderation.services.yml
Hunk #1 FAILED at 15.
1 out of 1 hunk FAILED -- saving rejects to file core/modules/content_moderation/content_moderation.services.yml.rej
patching file core/modules/content_moderation/src/Plugin/WorkflowType/ContentModeration.php
Hunk #2 succeeded at 111 (offset 2 lines).
Hunk #3 succeeded at 126 (offset 2 lines).
patching file core/modules/content_moderation/tests/src/Kernel/ContentModerationWorkflowConfigTest.php
Hunk #1 FAILED at 120.
Hunk #2 succeeded at 137 with fuzz 1 (offset 2 lines).
1 out of 2 hunks FAILED -- saving rejects to file core/modules/content_moderation/tests/src/Kernel/ContentModerationWorkflowConfigTest.php.rej
patching file core/modules/content_moderation/src/EventSubscriber/ConfigImportSubscriber.php
patching file core/modules/workflows/src/Form/WorkflowDeleteForm.php
patching file core/modules/workflows/src/Form/WorkflowEditForm.php
Hunk #1 succeeded at 118 with fuzz 2 (offset -1 lines).
Hunk #2 succeeded at 283 (offset 4 lines).
patching file core/modules/workflows/src/Form/WorkflowStateDeleteForm.php
patching file core/modules/workflows/src/Plugin/WorkflowTypeBase.php
patching file core/modules/workflows/src/WorkflowAccessControlHandler.php
The next patch would delete the file core/modules/workflows/src/WorkflowDeleteAccessCheck.php,
ankithashetty’s picture

Status: Needs work » Needs review
Issue tags: -Needs reroll
StatusFileSize
new33.28 KB
new18.9 KB

Re-rolled the patch in #66 and attached an diff file.

Thanks!

suresh prabhu parkala’s picture

StatusFileSize
new33.28 KB
new1.67 KB

Tried to fix custom failures in the patch #77. Please review.

gauravvvv’s picture

StatusFileSize
new636 bytes
new33.28 KB

Re-rolled patch #77, fixed cs error.

Status: Needs review » Needs work

The last submitted patch, 79: 2897148-78.patch, failed testing. View results

vsujeetkumar’s picture

Status: Needs work » Needs review
StatusFileSize
new36.79 KB
new6.05 KB

Fixed fail tests, Please have a look.

Status: Needs review » Needs work

The last submitted patch, 81: 2897148-81.patch, failed testing. View results

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

Drupal 9.3.0-rc1 was released on November 26, 2021, which means new developments and disruptive changes should now be targeted for the 9.4.x-dev branch. For more information see the Drupal core minor version schedule and the Allowed changes during the Drupal core release cycle.

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

Drupal 9.4.0-alpha1 was released on May 6, 2022, which means new developments and disruptive changes should now 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.

Version: 9.5.x-dev » 10.1.x-dev

Drupal 9.5.0-beta2 and Drupal 10.0.0-beta2 were released on September 29, 2022, which means new developments and disruptive changes should now be targeted for the 10.1.x-dev branch. For more information see the Drupal core minor version schedule and the Allowed changes during the Drupal core release cycle.

Version: 10.1.x-dev » 11.x-dev

Drupal core is moving towards using a “main” branch. As an interim step, a new 11.x branch has been opened, as Drupal.org infrastructure cannot currently fully support a branch named main. New developments and disruptive changes should now be targeted for the 11.x branch, which currently accepts only minor-version allowed changes. For more information, see the Drupal core minor version schedule and the Allowed changes during the Drupal core release cycle.

Version: 11.x-dev » main

Drupal core is now using the main branch as the primary development branch. New developments and disruptive changes should now be targeted to the main branch.

Read more in the announcement.