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

zef may fail to install IO::String #559

Open
lucs opened this issue May 22, 2024 · 1 comment
Open

zef may fail to install IO::String #559

lucs opened this issue May 22, 2024 · 1 comment

Comments

@lucs
Copy link

lucs commented May 22, 2024

tl;dr: For historical reasons 'zef install IO::String' may fail,
reporting problems with Text::CSV:ver<0.015>.
Workaround: 'zef install IO::String:ver<0.2.0>'
or a more recent version, if any.

Details:

I'm upgrading my Rakudo from moar-2023.02 to
moar-2024.04. I'm having problems obtaining the
IO::String distribution. raku.land proposes:

P6C: IO::String:ver<0.1.1>
ZEF: IO::String:ver<0.2.0>:auth<zef:jjmerelo>

Now, in a shell having moar-2024.04 active, please
observe:

▸ zef --dry install 'IO::String:ver<0.1.1>'
===> Searching for: IO::String:ver<0.1.1>
===> Staging IO::String:ver<0.1.1>
===> Staging [OK] for IO::String:ver<0.1.1>
===> Testing: IO::String:ver<0.1.1>
===> Testing [OK] for IO::String:ver<0.1.1>

▸ zef --dry install 'IO::String:ver<0.2.0>'
===> Searching for: IO::String:ver<0.2.0>
===> Staging IO::String:ver<0.2.0>:auth<zef:jjmerelo>
===> Staging [OK] for IO::String:ver<0.2.0>:auth<zef:jjmerelo>
===> Testing: IO::String:ver<0.2.0>:auth<zef:jjmerelo>
===> Testing [OK] for IO::String:ver<0.2.0>:auth<zef:jjmerelo>

So both of those are good. But:

▸ zef --dry install 'IO::String'
===> Searching for: IO::String
===> Staging Text::CSV:ver<0.015>:auth<zef:Tux>
===> Staging [OK] for Text::CSV:ver<0.015>:auth<zef:Tux>
===> Testing: Text::CSV:ver<0.015>:auth<zef:Tux>
===> Testing [FAIL]: Text::CSV:ver<0.015>:auth<zef:Tux>
Aborting due to test failure: Text::CSV:ver<0.015>:auth<zef:Tux> (use --force-test to override)

Yet:

▸ zef --dry install 'Text::CSV'
===> Searching for: Text::CSV
===> Staging Text::CSV:ver<0.022>:auth<zef:Tux>
===> Staging [OK] for Text::CSV:ver<0.022>:auth<zef:Tux>
===> Testing: Text::CSV:ver<0.022>:auth<zef:Tux>
===> Testing [OK] for Text::CSV:ver<0.022>:auth<zef:Tux>

I believe that in the past (versions 0.015 and
preceding) Text::CSV supplied an IO::String and that
somehow confuses things. Note that since version 0.016
(was fixed in commit 348a68c) it supplies a
Text::IO::String instead and does not use IO::String
anymore.

So I know that simply installing ver<0.2.0> solves my
problem, but I figured I should mention it so zef's
understanding could be fixed somehow.

@ugexe
Copy link
Owner

ugexe commented May 25, 2024

I'm not sure this can be changed easily. Below I will list the distributions in just the zef ecosystem alone that depend on a module name and not a distribution name. I suspect most of these were intentional, so fixing this would probably require updating all these distributions to depend on the distribution name shown instead of the module name. At that point zef could be updated to not consider module names when searching for candidates.

Distribution "Cro::RPC::JSON" depends on "Cro::HTTP::Router", but we source it from "Cro::HTTP"
Distribution "MUGS::UI::CLI" depends on "Text::MiscUtils::Layout", but we source it from "Text::MiscUtils"
Distribution "FHIR" depends on "Cro::HTTP::Client", but we source it from "Cro::HTTP"
Distribution "Sparky" depends on "Cro::HTTP::Server", but we source it from "Cro::HTTP"
Distribution "Discogs::API" depends on "Cro::HTTP::Client", but we source it from "Cro::HTTP"
Distribution "Terminal::LineEditor" depends on "Text::MiscUtils::Layout", but we source it from "Text::MiscUtils"
Distribution "Shodan" depends on "Cro::HTTP::Client", but we source it from "Cro::HTTP"
Distribution "Pod::To::PDF" depends on "HarfBuzz::Font::Cairo", but we source it from "HarfBuzz::Shaper::Cairo"
Distribution "Raku::Pod::Render" depends on "Cro::WebApp::Template::Repository::Hash", but we source it from "CWT-Repository-Hash"
Distribution "FeiShuBot" depends on "Cro::HTTP::Client", but we source it from "Cro::HTTP"
Distribution "Data::UkraineWar::MoD" depends on "Ake:ver<0.1.2+>", but we source it from "ake"
Distribution "Ikoko" depends on "Cro::HTTP::Client", but we source it from "Cro::HTTP"
Distribution "Kivuli" depends on "Cro::HTTP::Client", but we source it from "Cro::HTTP"
Distribution "AWS::SNS::Notification" depends on "Cro::HTTP::Client", but we source it from "Cro::HTTP"
Distribution "Cro::HTTP::BodyParser::JSONClass" depends on "Cro::BodyParser", but we source it from "Cro::Core"
Distribution "Collection-Raku-Documentation" depends on "Collection::RefreshPlugins", but we source it from "Collection"
Distribution "Prettier::Table" depends on "Text::Wrap", but we source it from "_"
Distribution "Intl::CLDR" depends on "Intl::UserLanguage:ver<0.4.0+>:auth<zef:guifa>", but we source it from "User::Language"
Distribution "Trove" depends on "Digest::MD5", but we source it from "Digest"
Distribution "Sys::HostAddr" depends on "Cro::HTTP::Client", but we source it from "Cro::HTTP"
Distribution "App::Tasks" depends on "Cro", but we source it from "Cro::Core"
Distribution "BusyIndicator" depends on "Cro", but we source it from "Cro::Core"
Distribution "Net::SMTP" depends on "Digest::MD5", but we source it from "Digest"
Distribution "WWW::OpenAI" depends on "Cro::HTTP::Client:ver<0.8.7+>", but we source it from "Cro::HTTP"
Distribution "Terminal::Tests" depends on "Text::MiscUtils::Layout", but we source it from "Text::MiscUtils"
Distribution "WebService::AWS::Auth::V4" depends on "URI::Escape", but we source it from "URI"
Distribution "GlotIO" depends on "URI::Escape", but we source it from "URI"
Distribution "Intl::Regex::CharClass" depends on "Intl::UserLanguage:ver<0.4.0+>:auth<zef:guifa>", but we source it from "User::Language"
Distribution "Node::Ethereum::KeyStore::V3" depends on "Crypt::LibGcrypt::Random", but we source it from "Crypt::LibGcrypt"
Distribution "Marrow" depends on "Cro::HTTP::Router", but we source it from "Cro::HTTP"
Distribution "Ethelia" depends on "Crypt::LibGcrypt::Random", but we source it from "Crypt::LibGcrypt"

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

No branches or pull requests

2 participants