For example when commonMain depends on commonTest there will be
CommonMainWithDependsOnDiagnostic diagnostic reported.
Or running gradle build on linux with apple targets inside will report
DisabledKotlinNativeTargets diagnostic.
KotlinSourceSetTreeDependsOnMismatchTest is not interested in them
Excluding android source sets can actually bring unexpected behaviour
when, for example, androidInstrumentedTest get depends on commonMain.
In this case "nativeMain" will be reported as checked skipped android
source sets, but they are still present in dependsOn edges.
Another important aspect is that mpp+android is a majority and their
cases should be checked as well
^KT-47144 Verification Pending
Introduce "White Crow" heuristic that will report incorrect dependency
edge when there is only one source set with different Source Set Tree.
Otherwise, report all source sets from all Source Set Tree groups
to user to choose which of them are incorrect.
And cover with more tests.
^KT-47144 Verification Pending
In Kotlin Multiplatform it is not possible to have
source set dependencies between two different SourceSet Trees.
For example commonTest can't dependOn commonMain as SourceSet dependency
instead binaries of commonMain should be included as dependency to
commonTest. Which is implemented through different mechanisms
^KT-47144 Verification Pending
- CompilationFreeArgsValidator got accidentally unused at some point,
and for now we don't see a reason to enable it back. A proper solution
includes exposing K/N linker options more explicitly via DSL, which
would address the initial problem of passing linker options to compiler
accidentally
- With ComplationFreeArgsValidator removal and migration of
DisabledNativeTargetsReporter to diagnostics infra, AggregateReporter
becomes unused so it can be removed as well
Also demote it from FATAL to ERROR, as FATAL leads to pretty disruptive
UX in IDE (import fails, and you don't get a broken project, which
makes it hard to fix the root cause and declare a target)
- Allow matching substring for 'assertNoDiagnostic' as well
- Better handling of cases when multiple diagnostics with the same ID
are reported (properly look for one 'withSubstring' if provided)
- Introduce 'UsesKotlinDiagnostics' marker-interface for tasks that
want to report diagnostics during their execution
- Introduce 'transparent mode' to collector. When all projects are
evaluated, Collector switches to it and will render all received
diagnostics right away. This allows reporting and rendering diagnostics
that are reported not from tasks, but after evaluation phase (e.g.
diagnostics on resolved dependencies)
^KT-58353 Fixed
This might become an issue if (when) the editable diff window will
be supported, but for now it doesn't make much difference against
which file we compare the actual output.