Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
Hello,
I'll try to explain the bug I discovered an how I resolved it.
I wanted to install openpublish distribution. In its makefile, it called to a non existing page (404)
Using the quickstart-create command works great until :
Drush command terminated abnormally due to an unrecoverable error. [error]
Error: Uncaught exception 'Exception' with message '
chown: cannot access `/home/drupalpro/websites/site.dev': No such file or directory' in /home/drupalpro/drupalpro/drush_addons/quickstart/quickstart.inc:30
Stack trace:
#0 /home/drupalpro/drupalpro/drush_addons/quickstart/quickstart.drush.inc(205): quickstart_shell_exec('sudo chown -R :...')
#1 [internal function]: drush_quickstart_fixperms()
#2 /home/drupalpro/drush/includes/command.inc(324): call_user_func_array('drush_quickstar...', Array)
#3 /home/drupalpro/drush/includes/command.inc(198): _drush_invoke_hooks('quickstart-fixp...', Array, 'quickstart')
#4 [internal function]: drush_command()
#5 /home/drupalpro/drush/includes/command.inc(165): call_user_func_array('drush_command', Array)
#6 /home/drupalpro/drush/drush.php(90): drush_dispatch(Array)
#7 /home/drupalpro/drush/drush.php(59): _drush_bootstrap_and_dispatch()
#8 /home/drupalpro/drush/drush.php(14): drush_main()
#9 {main}
thrown in /home/drupalpro/drupalpro/drush_addons/quickstart/quickstart.inc, line 30
Fatal error: Uncaught exception 'Exception' with message ' in /home/drupalpro/drupalpro/drush_addons/quickstart/quickstart.inc on line 30
Exception:
chown: cannot access `/home/drupalpro/websites/site.dev': No such file or directory in /home/drupalpro/drupalpro/drush_addons/quickstart/quickstart.inc on line 30
Call Stack:
0.0004 370936 1. {main}() /home/drupalpro/drush/drush.php:0
0.0206 3108912 2. drush_main() /home/drupalpro/drush/drush.php:14
0.0803 7473948 3. _drush_bootstrap_and_dispatch() /home/drupalpro/drush/drush.php:59
0.1064 7479764 4. drush_dispatch() /home/drupalpro/drush/drush.php:90
0.1298 7487608 5. call_user_func_array() /home/drupalpro/drush/includes/command.inc:165
0.1298 7487800 6. drush_command() /home/drupalpro/drush/includes/command.inc:0
0.1299 7487964 7. _drush_invoke_hooks() /home/drupalpro/drush/includes/command.inc:198
0.1308 7524692 8. call_user_func_array() /home/drupalpro/drush/includes/command.inc:324
0.1308 7524884 9. drush_quickstart_fixperms() /home/drupalpro/drush/includes/command.inc:0
0.1366 7529552 10. quickstart_shell_exec() /home/drupalpro/drupalpro/drush_addons/quickstart/quickstart.drush.inc:205
But the installation continues with :
Running installer (takes a minute, check cpu activity) ... [ok]
file_get_contents(/home/drupalpro/websites/site.dev/CHANGELOG.txt): failed to open stream: No such file or directory quickstart.inc:285 [warning]
Command site-install needs a higher bootstrap level to run - you will need invoke drush from a more functional Drupal environment to run this command. [error]
The drush command 'site-install standard' could not be executed. [error]
The directory /home/drupalpro/websites/site.dev does not contain a valid Drupal installation [error]
[ok]
URL: http://site.dev
Admin user: admin
Admin password: admin
... done. [ok]
Command completed successfully.
At the end, we do have a success message although there is nothing in websites/site.dev and accessing site.dev throws a permission error.
Simply deleting the not existing project in the makefile resolved the issue.
Is there a way that the script could check for page existence (404) before downloading/installing ?
Hope I could help :)
Comments
Comment #1
mike stewart CreditAttribution: mike stewart commentedhmm, sorry so slow. It would be useful to see the actual command you run. Did you use the full path (/home/drupalpro/foo/bar/make ) to the openpublish makefile?
care to share the command you ran, something like:
drush -d qc --domain=foobar.dev --makefile=/home/drupalpro/some-makefile
then, the output:
Comment #2
Martin_L CreditAttribution: Martin_L commentedHi,
I ran the command :
For now it works as I warned the openpublish project about the wrong link.
Should we only work with full paths to makefile in Drupalpro?
Thanks