Skip to content

Commit

Permalink
Use better channel comparisons
Browse files Browse the repository at this point in the history
  • Loading branch information
AntoinePrv committed Nov 20, 2023
1 parent 7c71222 commit 74f1b5b
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 4 deletions.
3 changes: 1 addition & 2 deletions libmamba/src/core/pool.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -160,8 +160,7 @@ namespace mamba
// We need to add any repo that matches.
for (const auto& cand_chan : candidate_channels)
{
// TODO replace with weaker equality: no credentials and rstrip
if (repo_chan.url() == cand_chan.url())
if (repo_chan.url_equivalent_with(cand_chan))
{
if (util::set_is_subset_of(repo_chan.platforms(), cand_chan.platforms()))
{
Expand Down
4 changes: 2 additions & 2 deletions libmamba/src/core/subdirdata.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -378,13 +378,13 @@ namespace mamba

bool check_zst(ChannelContext& channel_context, const Channel& channel)
{
// TODO the list of channels with zst shoudl really be computed only once in
// TODO the list of channels with zst should really be computed only once in
// the ChannelContext
for (const auto& c : channel_context.context().repodata_has_zst)
{
for (const auto& chan : channel_context.make_chan(c))
{
if (chan.base_url() == channel.base_url())
if (chan.contains_equivalent(channel))
{
return true;
}
Expand Down

0 comments on commit 74f1b5b

Please sign in to comment.