fresh-cat-90827
12/29/2022, 4:35 PMGet to call a rule without parameters ๐งตfresh-cat-90827
12/29/2022, 4:35 PM@dataclass
class Dummy:
pass
@rule
async def foo() -> Dummy:
return Dummy()
@goal_rule
async def goal_dummy() -> DummyGoal:
result = await Get(Dummy, {})
gives me
[ERROR] Invalid Get. Because you are using the shorthand form Get(OutputType, InputType(constructor args), the second argument should be a constructor call, like `MergeDigest(...)` or `Process(...)`. Failed for Get(Dummy, <class 'ast.Dict'>) in .../rules.py.bitter-ability-32190
12/29/2022, 4:35 PM@goal_rule
async def goal_dummy(dummy: Dummy) -> DummyGoal:
...fresh-cat-90827
12/29/2022, 4:36 PMbitter-ability-32190
12/29/2022, 4:37 PMfresh-cat-90827
12/29/2022, 4:37 PMfresh-cat-90827
12/29/2022, 4:37 PMbitter-ability-32190
12/29/2022, 4:37 PMbitter-ability-32190
12/29/2022, 4:38 PMAllTargetsRequest + AllTargetsfresh-cat-90827
12/29/2022, 4:40 PMawait Get(OutputClass, str, "") but it's not pretty ๐hundreds-father-404
12/29/2022, 4:41 PMfresh-cat-90827
12/29/2022, 4:42 PMfresh-cat-90827
12/29/2022, 4:42 PMfresh-cat-90827
12/29/2022, 4:48 PM[ERROR] Could not resolve type `<ast.Name object at 0x7fc024bd6460>` in top level of module project_version.rules defined in .../rules.py:103
line 103: result = await Get(Dummy, {})fresh-cat-90827
12/29/2022, 4:49 PM"2.15.0rc1" and "2.16.0.dev3"hundreds-father-404
12/29/2022, 4:49 PMfresh-cat-90827
12/29/2022, 4:49 PMfresh-cat-90827
12/29/2022, 4:50 PM