If at install time a user selects only apps that are already installed, Apps should just go ahead and enable the selected apps, just as it does after install time, where a user can enable an app that's already installed.

Currently, however, at install time Apps doesn't check to see whether apps selected for enabling are already installed. Even if all selected apps are already installed, the download task nonetheless runs (giving a confusing message about downloading project 1 of 0), and then the authorize and install tasks run as well. This adds up to a lot of unneeded screens and an unnecessary barrier to installation--there's no need to enter FTP credentials, since no code needs to be installed.

This bug relates to use cases for apps and distributions. Some apps-based distributions don't ship with their apps and supporting modules, instead relying on Apps to download and install as needed. However, some other apps-based distributions - e.g., Open Outreach - ship with many apps and supporting code already installed.

Proposed resolution

There's already a method for determining which apps are already installed (locally available). We just need to call this method after install time apps have been selected and determine whether any selected apps are not locally available and then set a flag that can be used to determine whether the app install related tasks need to run.

Remaining tasks

User interface changes

Install task screens will be skipped if download and install are not needed.

API changes

Members fund testing for the Drupal project. Drupal Association Learn more


nedjo’s picture

Status: Active » Needs review
2.75 KB

Here's a patch.

nedjo’s picture

This patch conflicts with the patch at #1500360: Facilitate use of Spark components in other distros and non-distro sites. As both are needed in some cases (e.g., for Open Outreach), here's a version with that patch also applied. The version in #1 however is the one to review.

nedjo’s picture

I'd missed unsetting a session variable in the previous patch. Fixed here. Again, there's a version for use with the patch from #1479164: Method for checking writability of server added.

febbraro’s picture

Status: Needs review » Closed (duplicate)

These changes are included in the patch for #1561652: Allow Apps to Be Installed with Drush During Site Install I believe, so I'm going to mark this as a duplicate and hopefully focus effort to test/commit the patch in #19 there.

febbraro’s picture

Issue summary: View changes

Note different apps-based distro models.