The require_once __DIR__ . '/core/vendor/autoload.php'; needs to be removed. That breaks the contract of including bootstrap.inc and bootstrapping Drupal. Why would all scripts need to do this? That's the task of the bootstrap system.

CommentFileSizeAuthor
#4 drupal8.rebuild-autoload.3.patch1.43 KBsun

Comments

chx’s picture

Status: Active » Closed (won't fix)
sun’s picture

Not sure what to do with this issue. Why did you mark it as "won't fix" ?

tim.plunkett’s picture

Just for clarity, this was documented in https://drupal.org/node/2080891

sun’s picture

Title: Drupal can't bootstrap itself any more » rebuild.php does not include /core/vendor/autoload.php
Assigned: Unassigned » sun
Status: Closed (won't fix) » Needs review
Parent issue: » #2171683: Remove all Simpletest overrides and rely on native multi-site functionality instead
StatusFileSize
new1.43 KB

Attached patch fixes the missing inclusion of /core/vendor/autoload.php.

That also allows us to remove that utterly bogus file path that is being included in drupal_settings_initialize().

Lastly, fixed the docs on drupal_bootstrap() accordingly.

chx’s picture

I won't fixed because this is one of those issues which are highly controversial. The fix is not to add autoload to rebuild but remove from the others and move it inside the drupal_bootstrap process.

sun’s picture

Given https://drupal.org/node/2080891, that appears to be a adopted and agreed-on change already. I'm not familiar with the underlying reasons that led to the change.

Unless I'm mistaken, this issue appears to have been created to remove a fix from #2171683: Remove all Simpletest overrides and rely on native multi-site functionality instead that is technically correct (following the status quo of core architecture) but slightly out of scope in that issue.

My interest is to unblock #2171683, so if I should open a separate issue for the patch in #4, then just let me know, please.

Anonymous’s picture

Status: Needs review » Reviewed & tested by the community

this seems like a straightforward fix to me.

i didn't even notice the autoload thing happen 4 mths ago :-)

chx’s picture

sun’s picture

webchick’s picture

Status: Reviewed & tested by the community » Fixed

Committed and pushed to 8.x.

For my part, I've been playing around with other Composer-ish third-party libs like Guzzle and Symfony, etc. and they all have the step of adding a require_once to vendor/autoload.php in addition to whatever other requirements are needed. So although it also feels a bit strange to me that bootstrap.inc doesn't actually bootstrap, it does appear to be the way PHP projects are going.

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.