Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

modules: Report switching module streams #1308

Merged

Conversation

pkratoch
Copy link
Contributor

Replacement for #1285 , but opened against the dnf5-5.2.0.0 branch.

The tests are still here: rpm-software-management/ci-dnf-stack#1462

@pkratoch pkratoch force-pushed the report-switch-stream-5.2 branch from 84a2a0e to 511eb65 Compare March 13, 2024 11:27
@kontura kontura self-assigned this Mar 14, 2024
@kontura
Copy link
Contributor

kontura commented Mar 14, 2024

@pkratoch it seems a rebase is needed.

Comment on lines 37 to 38
std::string module_stream;
std::string source_stream;
std::string target_stream;
Copy link
Contributor

Choose a reason for hiding this comment

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

Looking at https://github.com/fedora-modularity/libmodulemd/blob/main/yaml_specs/modulemd_obsoletes_v1.yaml I think it would be possible that a TransactionModule should change to a different module:stream (not only a stream).

What about to use similar approach like TransactionPackage, add something like get_replaces() or get_replaced_by()?

Copy link
Contributor

Choose a reason for hiding this comment

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

This is interesting suggestion (good). There is related feature - module obsoletes. Because it was introduced in later state of DNF4 development (shipped only to RHEL9 and Fedora), I am not sure whether module obsoletes are well implemented in software DB.

It would be good to investigate SWDB structure and DNF5 module transaction items whether they support easily those states in way that they could be even reverted.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Thanks for the suggestion! I am not quite sure how the obsoletes will be implemented, but I modified the TransactionModule similarly to the TransactionPackage. The get_replaced_by() is not needed for stream switching, but I added it, too, for later use for obsoletes.

@pkratoch pkratoch force-pushed the report-switch-stream-5.2 branch from 511eb65 to bb2a4de Compare March 22, 2024 09:35
@kontura
Copy link
Contributor

kontura commented Mar 25, 2024

Thank you

@kontura kontura merged commit a071fbe into rpm-software-management:dnf5-5.2.0.0 Mar 25, 2024
9 of 22 checks passed
@pkratoch pkratoch deleted the report-switch-stream-5.2 branch March 25, 2024 07:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants