You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am sorry but this is not an issue but request for suggestion whether the following user case is somehow supported in libsolv. I will be very happy to get any help.
Recently we got requests to analyze dependency on top of installed packages without actually installing them. It is something like to simulate that some packages are already installed and then I want to create a job that adds additional packages or modify simulated installed content. The user case is coming from build infrastructure or web services.
I am not happy to crate any fake content in libsolv but I don't see any other option but maybe you do.
We can create additional repository and create inside new solvables (pool_add_solvable(Pool *pool)) and copy features from available solvable. Then we can mark the repo as system repository and make their provide ready. Do you see a better way how to fake installed content?
When all analyses are finished them may be we would like to use the same instance of libsolv or pool data with another installed content. I found pool_free_solvable_block for removal solvable from installed repository but I am not sure whether it is good idea to use it or whether it is too risky? I know that it will make cashed solvable IDs invalid and it will require to recompute provides but there can be other critical issues that I do not see. Be honest I am scared to do it a lot.
Thank you very much for your help and I will also understand if you will close the issue because it is not an issue.
The text was updated successfully, but these errors were encountered:
I don't know if the following helps you, but we had a "patchcheck" program that checked if a patch that updates installed packages can be installed or not.
To do this, the libsolv bindings have a repo.createshadow("name") method that creates a copy of all repository packages (just the dependencies and main attributes, not the "repodata" parts).
There's also repo.moveshadow( [ ids ]) method that moves the packages into the specified repo. (It can only move between a repo and its shadow.)
The patchcheck tool used this to create a "installed" repo as shadow of the repo containing all packages and then used repo.moveshadow() to move packages around.
See bindings/solv.i for the implementation. This is all a big hack, so handle with care.
Yeah, we'd be interested in this as well!
I came up with the following code that loads an installed repo from a Transaction: mamba-org/mamba#1516 (but it's pretty mamba-specific so not sure you can derive much value from it).
I am sorry but this is not an issue but request for suggestion whether the following user case is somehow supported in libsolv. I will be very happy to get any help.
Recently we got requests to analyze dependency on top of installed packages without actually installing them. It is something like to simulate that some packages are already installed and then I want to create a job that adds additional packages or modify simulated installed content. The user case is coming from build infrastructure or web services.
I am not happy to crate any fake content in libsolv but I don't see any other option but maybe you do.
We can create additional repository and create inside new solvables (
pool_add_solvable(Pool *pool)
) and copy features from available solvable. Then we can mark the repo as system repository and make their provide ready. Do you see a better way how to fake installed content?When all analyses are finished them may be we would like to use the same instance of libsolv or pool data with another installed content. I found
pool_free_solvable_block
for removal solvable from installed repository but I am not sure whether it is good idea to use it or whether it is too risky? I know that it will make cashed solvable IDs invalid and it will require to recompute provides but there can be other critical issues that I do not see. Be honest I am scared to do it a lot.Thank you very much for your help and I will also understand if you will close the issue because it is not an issue.
The text was updated successfully, but these errors were encountered: