My module depends on the Fcntl
module (https://github.com/manchicken/perl6-Fcntl), which hasn't been updated in a long time and is broken. However, there's a fork (https://github.com/jonathanstowe/perl6-Fcntl) that works for me if I zef install
it manually. Is it possible to specify the dependency in my module's META-6.json
such that the correct github repo will be used for installing the module?

- 1,202
- 5
- 14
1 Answers
No, you cannot list a uri as a dependency. The spec actually states that dependency names in META6.json should match what you would use
.
If you insist on not integrating the namespace into one of the many cooperative ecosystems then you are still free to list the urls in your installation instructions:
zef install MyModule https://github.com/foo/dependency.git
When a user provides a uri to zef it is essentially treated as a stand-alone ecosystem and thus is able to fulfill dependencies for MyModule
. This is ok -- the user is explicitly requesting that source to be used. What is not ok is for module authors to dictate where dependencies are downloaded from (only what dependencies are needed).
All that said you can solve your problem a different way -- fork the module, change the auth
field to something else, list (and use
) Fcntl:auth<mynewauth>
as the dependency name, and then add your fork to an ecosystem. Alternative you could just bump the version so-to-speak.

- 5,297
- 1
- 28
- 49
-
3The idea of avoiding URIs is a good one for another reason: if everything is done by module name, author name, and version, then dependencies can be maintained long term by ecosystem repositories like CPAN, etc. If URIs are allowed, then link rottage could set in rather fast and break modules with potentially little recourse. – user0721090601 Aug 13 '20 at 01:57