gorgeous-winter-99296
11/10/2023, 5:05 PMbinary_crate -> workspace -> {all_member_packages}. However, for "non-output" targets it becomes weird. For example, clippy operates on a package but needs the whole workspace. So then we get package -> workspace -> {all_member_packages} - and those member packages then depend back on the package we're analysing via the workspace. I can definitely solve this by just adding more indirection, but having a specific target just for linting feels conceptually wrong.
Maybe @fast-nail-55400 has some thoughts from working with go?broad-processor-92400
11/10/2023, 7:54 PMgorgeous-winter-99296
11/10/2023, 8:00 PMfast-nail-55400
11/10/2023, 8:31 PMCoarsenedTarget to collect the set of files which need to be compiled together.fast-nail-55400
11/10/2023, 8:32 PMgo_package are compiled as one unit.fast-nail-55400
11/10/2023, 8:33 PMCoarsenedTarget instances depending on what dependency inference detected.gorgeous-winter-99296
11/10/2023, 9:46 PMCoarsenedTargets, but that one starts with TransitiveTargetsRequest and explodes.gorgeous-winter-99296
11/10/2023, 9:48 PMpants.engine.internals.graph.CycleException: The dependency graph contained a cycle:
-> examples/workspace/secondlib#package
examples/workspace/wsbin#package
-> examples/workspace/secondlib#packagefast-nail-55400
11/10/2023, 10:22 PMGet look like?gorgeous-winter-99296
11/10/2023, 10:35 PMcoarsened_targets = await Get(CoarsenedTargets, CoarsenedTargetsRequest(request.addresses))
Where request.addresses is frozenset({Address(examples/workspace/wsbin#package)}).gorgeous-winter-99296
11/10/2023, 10:35 PMgorgeous-winter-99296
11/10/2023, 10:38 PMexamples/workspace/wsbin#package
-> examples/workspace:workspace
examples/workspace/secondlib#package
-> examples/workspace:workspacegorgeous-winter-99296
11/10/2023, 11:10 PMgorgeous-winter-99296
11/10/2023, 11:16 PMgorgeous-winter-99296
11/11/2023, 1:10 PMcargo_crates should really be cargo_sources, which maybe makes more sense from a naming standpoint. But I think for various reasons the "source owner" will remain the cargo_package, and any lower level constructs are just for goals.gorgeous-winter-99296
11/11/2023, 1:12 PMgorgeous-winter-99296
11/11/2023, 2:29 PMgorgeous-winter-99296
11/11/2023, 2:30 PMcargo_sources, which is... maybe not great.gorgeous-winter-99296
11/11/2023, 2:33 PMinclude_str!(...) is a file-to-file dependency.fast-nail-55400
11/12/2023, 12:13 AMresources target type for those included files and then add an explicit dependency from the cargo_crate?fast-nail-55400
11/12/2023, 12:13 AMinclude_str! usages)fast-nail-55400
11/12/2023, 12:15 AMgorgeous-winter-99296
11/12/2023, 6:46 AM