Problem/Motivation
When trying to view the configuration menu or status report page of a site installed using the 'minimal' profile as a base I receive an error message:
Drupal\Core\Extension\Exception\UnknownExtensionException: The module minimal does not exist or is not installed. in Drupal\Core\Extension\ExtensionList->getExtensionInfo() (line 346 of core/lib/Drupal/Core/Extension/ExtensionList.php).
Steps to reproduce
Install a clean site using the `minimal` profile.
Login and browse to `/admin/reports/status`
Proposed resolution
The hook_requirements implementation in system.install checks the name of the installprofile, and if it is not 'standard' then it attempts to load the profile, but is attempting to load it via the `extension.list.module` service instead of the `extension.list.profile` service.
Replacing the lookup call with one that uses the proper service. appears to fix the issue.
Issue fork drupal-3293463
Show commands
Start within a Git clone of the project using the version control instructions.
Or, if you do not have SSH keys set up on git.drupalcode.org:
Comments
Comment #3
cilefen commentedThis looks like it may duplicate #1170362: Install profile is disabled for lots of different reasons and core doesn't allow for that or #1676196: Install profiles are registered as modules. Can you verify?
Comment #4
zenphp commentedThis does not appear to be as far as I can tell.
The install profile is properly installed and registered as an install profile and not being disabled.
It's a case where the requirements hook is attempting to load the install profile using the incorrect service.
Comment #5
zenphp commentedComment #6
axbHello,
I came across this issue in the wild, indeed when running a custom installation profile.
Confirmed what @zenphp said about requirements_hook incorrectly loading the install profile.
File modified:
core > moudles > system > system.install
Snippets changed:
With this simple change, I was able to complete my task -- accessing the '/admin/config' page.
Comment #8
smustgrave commentedThis issue is being reviewed by the kind folks in Slack, #need-reveiw-queue. We are working to keep the size of Needs Review queue [2700+ issues] to around 400 (1 month or less), following Review a patch or merge require as a guide.
Think the next step for this would be to get a test case added.
Also will need a 10.1.x MR started.
Comment #11
olarin commentedThis appears to be a guaranteed issue for any new site audacious enough to attempt to use any install profile other than standard (including the core-provided minimal), and there's no workaround to my knowledge, so I think it would qualify as Major priority.
I added a MR for the 10.1.x branch. I'm not sure where to start on adding a relevant test.
Comment #12
smustgrave commentedMay be worth starting in Drupal\FunctionalTests\Installer
Did an Umami install profile yesterday without issue just fyi
Comment #13
johnpitcairn commentedJust bitten by this with a minimal install. Not the first time either from memory. MR3639 does appear to fix the problem.
Is this still a 10.x candidate or does it need to be 11.x now?
Comment #15
mstrelan commentedIs this still an issue? I was unable to reproduce the issue after installing 11.x with minimal profile. I put a breakpoint in
\Drupal\system\Install\Requirements\SystemRequirements::checkRequirementsafter$info = $module_extension_list->getExtensionInfo($profile);and can see the profile info has been loaded.Comment #16
acbramley commentedSeeing the same as #15 when following those steps.
Closing this out for now, if you are able to reproduce this on HEAD then please feel free to reopen and provide the steps. Thanks!