You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When using Metro (v0.13.2) with generateContributionProviders enabled, SKIE 0.10.11 crashes during iOS framework linking with a NotImplementedError in ExposedDescriptorsCache.exposeGlobalMemberOrExtension.
generateContributionProviders is a Metro feature that generates synthetic FIR provider declarations (top-level functions/properties) in submodules, allowing @ContributesBinding implementation classes to remain internal instead of public. SKIE appears unable to categorize these Metro-generated synthetic declarations during the linkDebugFrameworkIosSimulatorArm64 phase.
Environment
Kotlin: 2.3.20
SKIE: 0.10.11
Metro: 0.13.2
Xcode: 26.0.1
Target: iosSimulatorArm64
Reproduction
In a Kotlin Multiplatform project using Metro for DI, add generateContributionProviders.set(true) to any submodule's build.gradle.kts:
metro {
generateContributionProviders.set(true)
}
Have at least one @ContributesBinding class in that submodule:
e: Compilation failed: An operation is not implemented.
e: kotlin.NotImplementedError: An operation is not implemented.
at co.touchlab.skie.kir.descriptor.cache.ExposedDescriptorsCache.exposeGlobalMemberOrExtension(ExposedDescriptorsCache.kt:130)
at co.touchlab.skie.kir.descriptor.cache.ExposedDescriptorsCache.exposePackageFragment(ExposedDescriptorsCache.kt:89)
at co.touchlab.skie.kir.descriptor.cache.ExposedDescriptorsCache.exposeModules(ExposedDescriptorsCache.kt:75)
at co.touchlab.skie.kir.descriptor.cache.ExposedDescriptorsCache.<init>(ExposedDescriptorsCache.kt:43)
...
> Task :shared:linkDebugFrameworkIosSimulatorArm64 FAILED
Workaround
Disabling generateContributionProviders and making impl classes public instead of internal avoids the crash, but loses the encapsulation benefit the feature provides.
Notes
This is related to Support kotlin-2.3.20 #174 — SebRut reported a similar class of error (different stack trace) when testing SKIE with Metro during the Kotlin 2.3.20 beta period. The NoSuchMethodError from that report appears to have been fixed in 0.10.11, but this NotImplementedError persists.
The crash occurs regardless of whether generateContributionProviders is enabled globally or per-submodule.
Without generateContributionProviders, Metro + SKIE works correctly with @ContributesBinding classes.
Description
When using Metro (v0.13.2) with
generateContributionProvidersenabled, SKIE 0.10.11 crashes during iOS framework linking with aNotImplementedErrorinExposedDescriptorsCache.exposeGlobalMemberOrExtension.generateContributionProvidersis a Metro feature that generates synthetic FIR provider declarations (top-level functions/properties) in submodules, allowing@ContributesBindingimplementation classes to remaininternalinstead ofpublic. SKIE appears unable to categorize these Metro-generated synthetic declarations during thelinkDebugFrameworkIosSimulatorArm64phase.Environment
Reproduction
generateContributionProviders.set(true)to any submodule'sbuild.gradle.kts:metro { generateContributionProviders.set(true) }@ContributesBindingclass in that submodule:Error
Workaround
Disabling
generateContributionProvidersand making impl classespublicinstead ofinternalavoids the crash, but loses the encapsulation benefit the feature provides.Notes
NoSuchMethodErrorfrom that report appears to have been fixed in 0.10.11, but thisNotImplementedErrorpersists.generateContributionProvidersis enabled globally or per-submodule.generateContributionProviders, Metro + SKIE works correctly with@ContributesBindingclasses.