Skip to content

N°9876 - A non installed extension should not be selected if it is not mandatory - #992

Open
Lenaick wants to merge 4 commits into
developfrom
feature/9876-non-installed-extension-should-not-be-selected-if-it-is-not-mandatory
Open

N°9876 - A non installed extension should not be selected if it is not mandatory#992
Lenaick wants to merge 4 commits into
developfrom
feature/9876-non-installed-extension-should-not-be-selected-if-it-is-not-mandatory

Conversation

@Lenaick

@Lenaick Lenaick commented Aug 4, 2026

Copy link
Copy Markdown
Contributor

N°9876 - A non installed extension should not be selected if it is not mandatory

Copilot AI balanced review requested due to automatic review settings August 4, 2026 15:06
@CombodoApplicationsAccount CombodoApplicationsAccount added the internal Work made by Combodo label Aug 4, 2026
@greptile-apps

greptile-apps Bot commented Aug 4, 2026

Copy link
Copy Markdown
Contributor

Greptile Summary

The PR adjusts setup-wizard selection rules so optional remote extensions are not selected automatically while preserving installed extensions unless force-uninstall is enabled.

  • Removes blanket mandatory status from remote extensions.
  • Refines checked and disabled states for missing, mandatory, installed, and remote extensions.
  • Expands unit coverage for mandatory and force-uninstall combinations.

Confidence Score: 4/5

The PR is not yet safe to merge because both previously reported dependency-issue paths remain reachable.

Installed optional remote extensions with dependency issues can still be removed without force-uninstall, while non-installed optional remote extensions with dependency issues retain their default selected state and are submitted through a hidden input.

Files Needing Attention: setup/extensionsmap.class.inc.php, setup/wizardsteps/WizStepModulesChoice.php

Important Files Changed

Filename Overview
setup/extensionsmap.class.inc.php Removes automatic mandatory status for remote extensions, but installed remote extensions with dependency issues remain removable in normal mode.
setup/wizardsteps/WizStepModulesChoice.php Refines extension checkbox flags, but the dependency-issue branch preserves default selection for non-installed optional remote extensions and misses the installed-remote removal safeguard.
tests/php-unit-tests/unitary-tests/setup/WizStepModulesChoiceTest.php Adds force-uninstall and mandatory-source coverage but does not cover the two dependency-issue combinations underlying the outstanding findings.

Reviews (3): Last reviewed commit: "N°9876 - A non installed extension shoul..." | Re-trigger Greptile

Comment thread setup/extensionsmap.class.inc.php
Comment thread setup/wizardsteps/WizStepModulesChoice.php Outdated

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Prevents optional, non-installed extensions from being selected automatically during setup.

Changes:

  • Preserves extension-defined mandatory status.
  • Refines force-uninstall selection behavior.
  • Updates related flag tests.

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 1 comment.

File Description
setup/extensionsmap.class.inc.php Stops forcing remote extensions to mandatory.
setup/wizardsteps/WizStepModulesChoice.php Adjusts checked and disabled flags.
tests/php-unit-tests/unitary-tests/setup/WizStepModulesChoiceTest.php Updates and expands flag scenarios.
Suppressed comments (1)

tests/php-unit-tests/unitary-tests/setup/WizStepModulesChoiceTest.php:661

  • This scenario does not exercise the newly changed installed/non-uninstallable branch: installed is false while mandatory and uninstallable are true, so execution takes the mandatory branch instead. Configure an installed, optional, non-uninstallable extension so the test verifies that force-uninstall leaves it enabled but checked even when it was not selected.
			'An installed extension with force uninstall should be checked and enabled' => [
				'aExtensionsOnDiskOrDb' => [
					'itop-ext1' => [
						'installed' => false,

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread tests/php-unit-tests/unitary-tests/setup/WizStepModulesChoiceTest.php Outdated
@Lenaick
Lenaick requested review from Timmy38 and bdalsass August 4, 2026 15:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

internal Work made by Combodo

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants