Problem/Motivation

Back in #2657178: Warn about experimental modules on their help pages there was an issue to add warnings in three places once an experimental module is installed.

  • During install
  • On the modules page
  • in the site status

However, this commit has introduced a serious flaw in the UX for experimental modules on a drupal site. In general...

  • Warnings must be actionable
  • The site should not question the decisions of a site builder once a decision should be made
  • The site should inform the site builder the implications of installing an experimental module and provide documentation on where to find the status of the experimental module.

This has real consequences for 1st tier drupal shops, which run into issues when using otherwise best practices for drupal development. Not all experimental modules are equal, and the decision to use an experimental module, once installed, should not be questioned by the site. The lightning distribution is currently using layout discovery, which should be encouraged over the deprecated and unsupported layout plugin module.

Also note, there was no UX review of the previous issue, and it was hastily committed within 2 days. It should have not been committed without proper UX review and community feedback.

Proposed resolution

  1. Change the warning to 'info' on the status page, so that site admins are still informed that experimental modules are enabled
  2. Remove the warning from the modules page.
  3. Add a better install notification/confirmation when installing an experimental module via the UI. This has basic support, but a handbook link or link to the status of experimental modules would be helpful.
  4. Encourage drush to add a confirmation before installing an experimental module, using the same url to reference users to the status of experimental modules. Filed https://github.com/drush-ops/drush/issues/2770

Remaining tasks

Create a patch to revert the warning from post install actions. Follow up with additional patch to make the confirmation page better when installing experimental modules.

User interface changes

Experimental modules should display a warning message only on the module confirmation install page.

API changes

N/A

Data model changes

N/A

CommentFileSizeAuthor
#51 2880374-51.patch4.37 KBsmustgrave
#51 interdiff-48-51.txt668 bytessmustgrave
#48 2880374-48.patch3.57 KBsmustgrave
#48 2880374-48-tests-only.patch1.26 KBsmustgrave
#48 interdiff-44-48.txt3.24 KBsmustgrave
#44 reroll_diff_2880374_39-44.txt2.72 KBankithashetty
#44 2880374-44.patch2.35 KBankithashetty
#39 remove-experimental-warning-2880374-39.patch2.27 KBjcnventura
#39 interdiff-2880374-33-39.txt3.95 KBjcnventura
#34 Screen Shot 2020-07-29 at 7.21.40 PM.png333.18 KBtanubansal
#34 Screen Shot 2020-07-29 at 7.21.23 PM.png332.72 KBtanubansal
#33 2880374-33_remove-experimental-warning.patch4.08 KBptmkenny
#30 2880374-30.patch4.01 KBjofitz
#30 interdiff-2880374-27-30.txt726 bytesjofitz
#27 drupal_experimental_modules_warnings_2880374-25.patch3.56 KBadinac
#26 drupal_experimental_modules_warnings_2880374-25.patch2.49 KBadinac
#21 2880374-21.patch3.41 KBjofitz
#14 not_for_prod.png205.43 KBxjm
#6 2880374-remove-experimental-warnings-6.patch3.95 KBjaperry
#2 2880374-remove-experimental-warnings-2.patch2.11 KBjaperry
Support from Acquia helps fund testing for Drupal Acquia logo

Comments

japerry created an issue. See original summary.

japerry’s picture

Status: Active » Needs review
FileSize
2.11 KB

This removes the experimental warnings post install.

phenaproxima’s picture

I am fully on board with this, and I +1 the reasoning @japerry laid out in the IS.

IMHO, once you install an experimental module, the damage is done. You've jumped off the cliff, so you need to be responsible for ensuring that your wings work beforehand. You have made the choice (or, in Lightning's case, the choice has been made for you), and Drupal should shut up about it. Continuously warning the administrators is pointless -- what do we expect them to do? If the answer to that is "not use experimental modules", I do not agree. Panels and its ecosystem are the prime example of a stable module that is depending on an experimental module which no longer has any business being experimental, but will not be stable until 8.4 for policy reasons, not technical ones.

I am going to advocate for us to bring the patch in #2 into Lightning while the requisite debate takes place in this issue. Incidentally, I also agree with what @japerry re: the warning not having received any UX review (at least, nothing documented) before going into core. It deserved a proper discussion, so let's have that now.

japerry’s picture

I mentioned 1st tier companies, but this affects all levels of site builders. If I just went to a Drupalcon talk that discussed using migrate or layout discovery.. or read a blog post from a reputable person, why should my site be questioning the decision I made? If I'm a site owner, why should my site be implying to me that my contractor made a bad decision by installing an experimental module, when it a specific module might be a best practice?

Status: Needs review » Needs work

The last submitted patch, 2: 2880374-remove-experimental-warnings-2.patch, failed testing.

japerry’s picture

Status: Needs work » Needs review
Issue tags: +Needs tests
FileSize
3.95 KB

Updated patch to remove the core test for the experimental module warning to appear. Curious, there doesn't seem to be a test when installing a module? I added 'needs tests' to maybe add a followup to add a test for that...

anavarre’s picture

Issue summary: View changes

Filed the corresponding Drush issue.

DamienMcKenna’s picture

Issue tags: +Usability

+1 for this.

rlnorthcutt’s picture

+1 on this.

David_Rothstein’s picture

Back in #2657178: Warn about experimental modules on their help pages there was an issue to add warnings in three places once an experimental module is installed.

  • During install
  • On the modules page
  • in the site status

Wrong issue. For example, the site status warning seems to have been added as a result of #2560597-5: Mark Migrate* modules as Experimental...

Agreed with the goal though. This patch keeps the message on the site status page but changes it from a warning to an informational message, which makes a lot of sense.

--- a/core/modules/help/src/Controller/HelpController.php
+++ b/core/modules/help/src/Controller/HelpController.php
@@ -117,11 +117,6 @@ public function helpPage($name) {
       $module_name = $this->moduleHandler()->getName($name);
       $build['#title'] = $module_name;
 
-      $info = system_get_info('module', $name);
-      if ($info['package'] === 'Core (Experimental)') {
-        drupal_set_message($this->t('This module is experimental. <a href=":url">Experimental modules</a> are provided for testing purposes only. Use at your own risk.', [':url' => 'https://www.drupal.org/core/experimental']), 'warning');
-      }
-

This is actually what was added in #2657178: Warn about experimental modules on their help pages. Instead of removing it, what about changing it from a warning to an informational message as well? (For example, prepending it to the normal help text or something like that.) I think the discussion in #2657178: Warn about experimental modules on their help pages explains why having some kind of message here is a good idea.

yoroy’s picture

@David_Rothstein :

This patch keeps the message on the site status page but changes it from a warning to an informational message, which makes a lot of sense.

Did you mean to supply a patch with your comment? It's unclear where else "this patch" may be found if not :)

David_Rothstein’s picture

I was referring to the patch in comment #6 above.

xjm’s picture

For me, this is a wontfix that takes us in the wrong direction. People are under-warned about the risks of experimental modules, not over-warned.

xjm’s picture

Issue summary: View changes
FileSize
205.43 KB

Pictures speak louder than words. This is what happens if you update from 8.2.x to 8.3.x with Content Moderation enabled. Your site is unrecoverably broken with no workaround and no upgrade path.

yoroy’s picture

This is a hard problem. We should try and prevent unrecoverable things from happening, but people will do stupid things.
Consistent/persistent warnings are not necessarily the answer, that's mostly training people to ignore them.

Would it help if we designed a super-ultra warning specifically for the scenario where people want to update their site and have experimentals installed? I guess that's only for updates through the UI then. Drush and Composer could do something as well?

(Aside: why the 1st tier vs other companies distinction? it does not seem relevant to the issue at hand).

xjm’s picture

xjm’s picture

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.

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.

balsama’s picture

Issue tags: +Needs reroll
jofitz’s picture

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.

adinac’s picture

Re-roll of the patch from comment #21 for 8.9.x-dev.

adinac’s picture

adinac’s picture

Status: Needs review » Needs work
jofitz’s picture

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.

ptmkenny’s picture

Status: Needs review » Needs work

Sadly the patch in #30 no longer applies.

ptmkenny’s picture

Status: Needs work » Needs review
FileSize
4.08 KB

Reroll for 9.1.x.

tanubansal’s picture

After adding patch #33, experimental module warning disappeared from /admin/reports/status as well as admin/modules page
This can be moved to RTBC

samiullah’s picture

Moving to RTBC

samiullah’s picture

Status: Needs review » Reviewed & tested by the community
catch’s picture

So in 2017, I agreed with @xjm in #2880374-13: Experimental modules and themes should not have warnings after being installed that this issue would have been won't fix.

However, we've significantly changed how experimental modules are added to core, so that they don't make it into a tagged release without a supported upgrade path. So it might be OK now. Tagging for release manager review so we get a chance to discuss it.

catch’s picture

Status: Reviewed & tested by the community » Needs work
+++ /dev/null
@@ -1,65 +0,0 @@
-
-  /**
-   * Verifies that a warning message is displayed for experimental modules.
-   */
-  public function testExperimentalHelp() {
-    $this->drupalLogin($this->adminUser);
-    $this->drupalGet('admin/help/experimental_module_test');
-    $this->assertText('This module is experimental.');
-

This is useful information for site administrators, even if we don't show it as a warning. Moving back to needs review.

jcnventura’s picture

Addressing #38, it seems it would be best to provide a normal status message instead of a warning in the help system, then.

With the addition of claro, it is also important to not punish those users that chose to install it. I'm changing also the message type for themes to REQUIREMENT_INFO.

samiullah’s picture

#39 looks good
Might need code review from FE/verbiage puprose

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.

erin.rasmussen’s picture

We were testing this against Drupal 9.3, 9.2, and 9.1 and found that the patch failed to apply.

ankithashetty’s picture

Re-rolled the patch in #39 against 9.3.x-dev version.

Thanks!

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.

smustgrave’s picture

Status: Needs review » Needs work

Moving back to needs work for the test cases

smustgrave’s picture

The last submitted patch, 48: 2880374-48-tests-only.patch, failed testing. View results

Status: Needs review » Needs work

The last submitted patch, 48: 2880374-48.patch, failed testing. View results

smustgrave’s picture

Status: Needs work » Needs review
FileSize
668 bytes
4.37 KB

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.

catch’s picture

Issue summary: View changes
Issue tags: -Needs release manager review
catch’s picture

Didn't mean to remove the tag, but I've pinged the other release managers and will remove in a few days if no objections.

smustgrave’s picture

Following up on this one.

catch’s picture

It's been more than a few days, so I'm going to go ahead and remove the tag. We have warnings for deprecated modules, so if an experimental module ends up on its way out of core, people will be notified that way. The info level item is still a reminder you're running something that's not fully stable yet.

xjm’s picture

Let's bring it up in the RM channel so that folks have a chance to discuss and agree.

catch’s picture

Issue tags: +Needs screenshots

Could use screenshots of the info-level message in the status report. The test coverage asserts that the warning doesn't appear, but should that change to a positive assertion that an info appears?

xjm credited quietone.

xjm’s picture

Issue tags: -Needs screenshots

Via @quietone:

+++ b/core/modules/system/system.install
@@ -98,7 +98,7 @@ function system_requirements($phase) {
       $requirements['experimental_modules'] = [
         'title' => t('Experimental modules enabled'),
         'value' => t('Experimental modules found: %module_list. <a href=":url">Experimental modules</a> are provided for testing purposes only. Use at your own risk.', ['%module_list' => implode(', ', $experimental_modules), ':url' => 'https://www.drupal.org/core/experimental']),
-        'severity' => REQUIREMENT_WARNING,
+        'severity' => REQUIREMENT_INFO,
       ];
     }
     // Warn if any deprecated modules are installed.
@@ -147,7 +147,7 @@ function system_requirements($phase) {

@@ -147,7 +147,7 @@ function system_requirements($phase) {
       $requirements['experimental_themes'] = [
         'title' => t('Experimental themes enabled'),
         'value' => t('Experimental themes found: %theme_list. Experimental themes are provided for testing purposes only. Use at your own risk.', ['%theme_list' => implode(', ', $experimental_themes)]),
-        'severity' => REQUIREMENT_WARNING,
+        'severity' => REQUIREMENT_INFO,
       ];

This patch is going too far. The scope should be limited to runtime warnings being turned to info mesages. We should still be warning about them during installation/update.

I am also not sure the warning should be removed from the help pages.

xjm’s picture

Status: Needs review » Needs work
Issue tags: +Needs screenshots

Sorry, crosspost.

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.