I am trying to understand why `pants run "requirem...
# general
f
I am trying to understand why
pants run "requirements:requirements#some-package" --
works to invoke the CLI of some packages but fails with
ImportError: No module named some_package.__main__; 'some_package' is a package and cannot be directly executed
in other cases. Any ideas?
b
I think it depends on the package and its configuration. Do you have a specific example of a package that works and one that doesn’t work so we can explore it concretely?
f
Unfortunately, the packages I tried are all internal. But will let you know if we identify the cause and what’s needed to make it work.
b
Ah okay, I think two things that are likely to be related are: • whether they have a
__main__.py
as the message references • any configured
entry_points
in the package metadata ... but probably mostly the first one 🙂