Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove JS Legacy transformer #425

Closed
mvicsokolova opened this issue Apr 28, 2024 · 1 comment
Closed

Remove JS Legacy transformer #425

mvicsokolova opened this issue Apr 28, 2024 · 1 comment
Assignees
Labels
deprecation A feature that is going to deprecated and removed in future releases

Comments

@mvicsokolova
Copy link
Collaborator

mvicsokolova commented Apr 28, 2024

AtomicfuJSTransformer that transformed the final *.js files for JS legacy compiler backend can be removed from the library, as Kotlin compiler already removed JS legacy backend since Kotlin 1.9.0

@mvicsokolova mvicsokolova added the deprecation A feature that is going to deprecated and removed in future releases label Apr 28, 2024
@mvicsokolova mvicsokolova self-assigned this Oct 15, 2024
@mvicsokolova
Copy link
Collaborator Author

Starting from Kotlin 2.1.0-Beta1 with kotlinx-atomicfu <= 0.25.0 keeping transformJs flag enabled is an error ❌:

e: KLIB resolver: The same 'unique_name=kotlinx.atomicfu.examples:mpp-sample' found in more than one library: /build/classes/atomicfu/js/main, /build/classes/kotlin/js/main
Please file an issue to https://kotl.in/issue and meanwhile use CLI flag `-Xklib-duplicated-unique-name-strategy` with one of the following values:
allow-all-with-warning: Use all KLIB dependencies, even when they have same `unique_name` property.
allow-first-with-warning: Use the first KLIB dependency with clashing `unique_name` property. No order guarantees are given though.

This happens, because in kotlinx-atomicfu 0.25.0 this flag is still enabled by default and while taking no effect for Kotlin versions > 1.9.0 (no transformations are performed, because Js Legacy is disabled since Kotlin 1.9.0), the AtomicfuGradlePlugin still created an empty directory: /build/classes/kotlin/js/main.

In the nearest release 0.25.1 transformJs flag will be deprecated with a warning and will take no effect, the JS Legacy transformer will be removed.
In the next release transformJs flag will be removed completely.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
deprecation A feature that is going to deprecated and removed in future releases
Projects
None yet
Development

No branches or pull requests

1 participant