Skip to content

Conversation

@whyoleg
Copy link
Collaborator

@whyoleg whyoleg commented Sep 17, 2025

Contains IT from #4268 (reproducer for KT-81108) - working correctly now.

As shown in the changed IT expectedData, we now treat source sets like linuxMain as native and analyze them using the native analysis platform.

@whyoleg
Copy link
Collaborator Author

whyoleg commented Sep 17, 2025

AA issue: KT-81108 AA: java.lang.ClassCastException: class org.jetbrains.kotlin.fir.FirBinaryDependenciesModuleData cannot be cast to class org.jetbrains.kotlin.analysis.low.level.api.fir.projectStructure.LLFirModuleData

@whyoleg whyoleg added the blocked: AA Changes required in Analysis API label Sep 17, 2025
@vmishenev
Copy link
Contributor

vmishenev commented Sep 17, 2025

@vmishenev, have you seen similar errors before? I

No, I don't remember.
Can you create a unit test only for this class https://github.com/Kotlin/kotlinx-io/blob/b1db70bb9822b0095b13626d955ddc8ebc1e7f17/core/androidNative/src/files/FileSystemAndroid.kt#L31 ?
It would be useful for Dokka as well

@whyoleg
Copy link
Collaborator Author

whyoleg commented Sep 17, 2025

Can you create a unit test

I can't, as it depends on K/N platform libraries :(
But I will try to create an integration test and check if it reproducible there

@whyoleg whyoleg force-pushed the whyoleg/dgp-isMetadata branch from 06d4000 to 6a186a8 Compare September 17, 2025 16:29
@whyoleg
Copy link
Collaborator Author

whyoleg commented Sep 17, 2025

Reproduced the issue from kotlinx.io in 59286fe - I will create an issue in Dokka to track this

(also, I will extract test changes into one more PR)

@vmishenev
Copy link
Contributor

I can't, as it depends on K/N platform libraries :(

You can copy the required subset of them for tests.

@whyoleg
Copy link
Collaborator Author

whyoleg commented Sep 18, 2025

You can copy the required subset of them for tests.

But it fails specifically because of cnames.structs.DIR in the constructor, which is a bit of a special case in K/N and comes from platform libraries (or cinterop). If I use anything else in the constructor, it will not fail.
So I'm not sure that we could do a unit test for it...

@whyoleg whyoleg force-pushed the whyoleg/dgp-isMetadata branch from 6a186a8 to 6c8e431 Compare September 18, 2025 15:43
@whyoleg whyoleg changed the base branch from master to whyoleg/kmp-it September 18, 2025 15:44
Base automatically changed from whyoleg/kmp-it to master October 6, 2025 10:30
@whyoleg whyoleg removed the blocked: AA Changes required in Analysis API label Oct 8, 2025
@adam-enko adam-enko added this to the Dokka 2.1.x milestone Oct 29, 2025
@whyoleg whyoleg force-pushed the whyoleg/dgp-isMetadata branch 2 times, most recently from 9950776 to 292dd40 Compare November 3, 2025 09:53
@whyoleg whyoleg marked this pull request as ready for review November 3, 2025 09:56
@adam-enko
Copy link
Member

:dokka-integration-tests:cli: is failing on TC - is that unrelated to this PR?

@whyoleg whyoleg force-pushed the whyoleg/dgp-isMetadata branch from 292dd40 to bd4a933 Compare November 3, 2025 14:48
@whyoleg
Copy link
Collaborator Author

whyoleg commented Nov 3, 2025

:dokka-integration-tests:cli: is failing on TC - is that unrelated to this PR?

@adam-enko, no, it should be fixed by #4324. Rebased the PR.

@whyoleg whyoleg merged commit 08f8de9 into master Nov 3, 2025
14 checks passed
@whyoleg whyoleg deleted the whyoleg/dgp-isMetadata branch November 3, 2025 16:36
adam-enko pushed a commit that referenced this pull request Nov 4, 2025
* Reproduce kotlinx.io issue with `cnames` usage
* Update IT expected data after the `isMetadata` flag is fixed
* Update IT expected data for `cnames` usage
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

AA: java.lang.ClassCastException: FirBinaryDependenciesModuleData cannot be cast to LLFirModuleData

4 participants