I’m attempting to use the `openapi` backend (added...
# general
l
I’m attempting to use the
openapi
backend (added to my
pants.toml
):
Copy code
pants.backend.experimental.openapi
pants.backend.experimental.openapi.codegen.java
released in
2.15.x
, but get an error when running
pants check src::
Copy code
09:32:29.46 [ERROR] Failed to load the pants.backend.experimental.openapi.codegen.java.register backend: ModuleNotFoundError("No module named 'pants.backend.experimental.openapi.codegen'")
I’m running pants
2.17.x
and the backend code is definitely there https://github.com/pantsbuild/pants/tree/2.17.x/src/python/pants/backend/experimental/openapi/codegen/java
e
👀 1
@loud-nightfall-4213 so this is a bug in Pants own packaging. Definitely worth an issue and maybe you even want to tackle it.
🐞 1
l
I see! Happy to open an issue as the
openapi.codegen.java
backend is something my team would definitely want to use. As for tackling it, think I need to understand the problem more, especially what “this is a bug in Pants own packaging” really means, but we can discuss more in the issue which I can open some time today
f
especially what “this is a bug in Pants own packaging” really means
Pants needs all of the backends to be listed as dependencies in the list of backends in the
BUILD
file to which that link points. An entry for
pants.backend.experimental.openapi.codegen.java
is missing from that list which is why that backend was not packaged in the Pants release.
(and thus is why the backend was not found and
ModuleNotFoundError
was raised)
l
thanks for providing clarity on the issue @fast-nail-55400 👍
I opened PR #19835 with CI hopefully passing 🤞
🙏 1