-
Notifications
You must be signed in to change notification settings - Fork 46
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(software): Reload repositories after failure (#1894)
## Problem ![agama-repo-failed](https://github.com/user-attachments/assets/522bb11c-9698-4278-816e-b472f25d73f1) - When repository refresh fails there is no way how to retry the operation - The only workaround is to select a different product and then select back the original product - This obviously won't work if the installer contains only one product ## Solution - Detect that a repository failed and offer a reload action ## Recording <!-- [SLES4SAP-screen0.webm](https://github.com/user-attachments/assets/cd530256-c553-400a-b794-f628b06b3980) --> [SLES4SAP-screen0.webm](https://github.com/user-attachments/assets/ad9a5798-5f42-4333-8a4a-9419953a85ee) - There is a new error section with "retry" link - Unfortunately the VirtualBox does not record the mouse pointer so it not obvious that the "Try again" link was clicked by mouse - For easier testing I used a local copy of the SLE repository to easily simulate unreachable repository and make it working for the retry attempt. That's why you see a different (local) repository in the recording. ## Details - It turned out that it is not simple to detect a repository failure in the software page. - It reports an issue but it might contain a translated text or there might be a different issue like missing product or pattern. That means we cannot use the issues texts. - We will very likely need a repository management later anyway it makes sense to add API for fetching the current repository setup with the load status (succeeded or failed). ## Tasks - [x] DBus interface for listing the current repository setup (added the `ListRepositories` DBus method) - [x] Add the HTTP API endpoint `/api/software/repositories` using the DBus backend above (@jreidinger thanks!) - [x] Adapt the frontend code to show a failure - [x] Adapt the frontend to retry after clicking a button --------- Co-authored-by: Josef Reidinger <[email protected]>
- Loading branch information
1 parent
31823f4
commit 6901956
Showing
18 changed files
with
250 additions
and
9 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,10 @@ | ||
------------------------------------------------------------------- | ||
Mon Jan 20 16:44:02 UTC 2025 - Ladislav Slezák <[email protected]> | ||
|
||
- The web server provides /api/software/repositories endpoint | ||
for reading the currently configured repositories, | ||
related to (gh#agama-project/agama#1894) | ||
|
||
------------------------------------------------------------------- | ||
Mon Jan 20 10:35:47 UTC 2025 - Imobach Gonzalez Sosa <[email protected]> | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,9 @@ | ||
------------------------------------------------------------------- | ||
Mon Jan 20 16:44:45 UTC 2025 - Ladislav Slezák <[email protected]> | ||
|
||
- The software service provides DBus API for reading the currently | ||
configured repositories, related to (gh#agama-project/agama#1894) | ||
|
||
------------------------------------------------------------------- | ||
Mon Jan 20 10:35:35 UTC 2025 - Imobach Gonzalez Sosa <[email protected]> | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,10 @@ | ||
------------------------------------------------------------------- | ||
Mon Jan 20 16:45:18 UTC 2025 - Ladislav Slezák <[email protected]> | ||
|
||
- The software page displays a link for reloading the repositories | ||
again if some repository failed to load | ||
(gh#agama-project/agama#1894) | ||
|
||
------------------------------------------------------------------- | ||
Mon Jan 20 10:36:09 UTC 2025 - Imobach Gonzalez Sosa <[email protected]> | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.