can a `rule` have no input parameters? I can't see...
# plugins
f
can a
rule
have no input parameters? I can't seem to find any example in the repo. My use case is that a rule makes a
Process
call and returns a scalar value; it doesn't really need any inputs. Right now I have to do
await Get(OutputClass, str, "")
with the rule being
async def foo(dummy: str = "") -> OutputClass:
to satisfy the build graph.
1
h
It's valid to have no params. You would either put the type in the "calling" rule's function signature, or use
Get(OutputClass, {})
. We want to simplify that to
Get(OutputClass)
if you have any interest in implementing that syntactic sugar 🙂
1
🙇 1
(this is all new in the past 2-3 months, to support 2.15's new "environments" feature)