-
Notifications
You must be signed in to change notification settings - Fork 357
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
MRepo refactor #3118
Merged
Merged
MRepo refactor #3118
Conversation
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
AntoinePrv
force-pushed
the
repo
branch
11 times, most recently
from
January 16, 2024 09:42
19916d6
to
5156505
Compare
AntoinePrv
commented
Jan 17, 2024
Comment on lines
+74
to
113
auto add_repo_from_repodata_json( | ||
const fs::u8path& path, | ||
std::string_view url, | ||
solver::libsolv::PipAsPythonDependency add = solver::libsolv::PipAsPythonDependency::No, | ||
solver::libsolv::RepodataParser parser = solver::libsolv::RepodataParser::Mamba | ||
) -> expected_t<solver::libsolv::RepoInfo>; | ||
|
||
auto add_repo_from_native_serialization( | ||
const fs::u8path& path, | ||
const solver::libsolv::RepodataOrigin& expected, | ||
solver::libsolv::PipAsPythonDependency add = solver::libsolv::PipAsPythonDependency::No | ||
) -> expected_t<solver::libsolv::RepoInfo>; | ||
|
||
template <typename Iter> | ||
auto add_repo_from_packages( | ||
Iter first_package, | ||
Iter last_package, | ||
std::string_view name = "", | ||
solver::libsolv::PipAsPythonDependency add = solver::libsolv::PipAsPythonDependency::No | ||
) -> solver::libsolv::RepoInfo; | ||
|
||
template <typename Range> | ||
auto add_repo_from_packages( | ||
const Range& packages, | ||
std::string_view name = "", | ||
solver::libsolv::PipAsPythonDependency add = solver::libsolv::PipAsPythonDependency::No | ||
) -> solver::libsolv::RepoInfo; | ||
|
||
auto native_serialize_repo( | ||
const solver::libsolv::RepoInfo& repo, | ||
const fs::u8path& path, | ||
const solver::libsolv::RepodataOrigin& metadata | ||
) -> expected_t<solver::libsolv::RepoInfo>; | ||
|
||
void set_installed_repo(const solver::libsolv::RepoInfo& repo); | ||
|
||
void | ||
set_repo_priority(const solver::libsolv::RepoInfo& repo, solver::libsolv::Priorities priorities); | ||
|
||
void remove_repo(::Id repo_id, bool reuse_ids); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@jaimergp What do you think of the new API here?
JohanMabille
approved these changes
Jan 17, 2024
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
The repo never really needed to hold much information, in fact it's always the Pool that hold the data in libsolv.
Close #3066 since this is a total refactor.
The Pool bindings are unfortunately only tested manually. They'll be tests when it is refactored.