• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

agama-project / agama / 21357815862

26 Jan 2026 12:33PM UTC coverage: 73.99% (-0.007%) from 73.997%
21357815862

push

github

web-flow
Fixed removing automatically selected recommended patterns (#3072)

## Problem

- The autoselected patterns cannot be deselected
- Example: Clicking checkboxes for the "Multimedia" or "Office Software"
patterns does not change anything:
<img width="1280" height="800" alt="agama-autoselected-patterns"
src="https://github.com/user-attachments/assets/e4f02be9-3cc3-417f-ad23-5b9fa16518cb"
/>

## Solution

It turned out that there are actually two problems, one in backend and
one in the frontend.

## Backend

The original steps done when selecting the software patterns were like
this:

1. Reset all resolvable states in libzypp to start from scratch (to
remove the previous selection)
2. Select and unselect the requested patterns
3. Run the solver to solve the dependencies

The problem is that the automatically selected recommended patterns are
selected by the solver at step 4. Unselecing the not wanted patterns in
step 3 is useless because at that point they are not selected yet.

The solution is to change the steps to this:

1. Reset all resolvable states in libzypp to start from scratch (to
remove the previous selection)
2. Select the requested patterns
3. Run the solver to select the dependencies (ignore the result, we are
only interested in the autoselection now)
4. Unselect the not wanted patterns
5. Run the solver again to solve the final dependencies and possibly
report conflicts to user

## Frontend

Another problem was found in the frontend. When clicking a pattern to
select it also sends all unselected patterns to unselect. The problem is
that then we cannot distinguish between not selected patterns and
patterns explicitly unselected by user.

The fix actually requires also a change in the backend. Similarly to the
selected patterns where we distinguish between explicitly selected and
selected by dependencies we need to have two states for the not selected
patterns as well.

## Testing

- Tested manually
- Tested also with Agama CLI, after unselec... (continued)

2874 of 5132 branches covered (56.0%)

Branch coverage included in aggregate %.

5 of 5 new or added lines in 2 files covered. (100.0%)

3 existing lines in 2 files now uncovered.

20381 of 26298 relevant lines covered (77.5%)

64.05 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

92.0
/web/web/src/components/software/SoftwarePatternsSelection.tsx


Source Not Available

STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc