From e43b4c6696d4f5deb8810421576a3c98d3365a0b Mon Sep 17 00:00:00 2001 From: Claude Date: Sun, 20 Sep 2026 21:49:37 +0000 Subject: [PATCH] fix(quartz): stop shipping a dead keep rule to every consumer, fix a dead link Both found answering "does this keep quartz's names for library users". consumer-rules.pro is merged into the R8 configuration of every app that depends on quartz, so its contents are somebody else's build, not just ours. The three libscrypt rules match nothing: quartz replaced it with a pure-Kotlin implementation, and `:quartz:dependencies --configuration jvmRuntimeClasspath` shows no com.lambdaworks on the graph at all. The secp256k1 JNI rule stays -- that one is real. The KDoc on NwcTransactionMetadata still pointed at nip47WalletConnect.kotlinSerialization.toAnyValue. That package went away when the helper moved to nip01Core.kotlinSerialization, so the link resolved to nothing for anyone reading the published docs. Co-Authored-By: Claude Opus 5 Claude-Session: https://claude.ai/code/session_01DEoxktEZyTrAS33vVZBiwm --- quartz/consumer-rules.pro | 8 ++++---- .../nip47WalletConnect/rpc/NwcTransactionMetadata.kt | 2 +- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/quartz/consumer-rules.pro b/quartz/consumer-rules.pro index a072dd5bc4..5c7330a4a2 100644 --- a/quartz/consumer-rules.pro +++ b/quartz/consumer-rules.pro @@ -15,10 +15,10 @@ # secp256k1's JNI layer resolves these from native code. -keep class fr.acinq.secp256k1.** { *; } -# libscrypt --keep class com.lambdaworks.codec.** { *; } --keep class com.lambdaworks.crypto.** { *; } --keep class com.lambdaworks.jni.** { *; } +# Nothing keeps libscrypt any more: quartz replaced it with a pure-Kotlin +# implementation and `:quartz:dependencies` shows no com.lambdaworks on any +# configuration. These rules are merged into the R8 config of EVERY app that +# depends on quartz, so a rule we do not need is noise in somebody else's build. # No Jackson keeps. Every wire format Quartz speaks is now handled by a # hand-written serializer that names its fields as string literals: the diff --git a/quartz/src/commonMain/kotlin/com/vitorpamplona/quartz/nip47WalletConnect/rpc/NwcTransactionMetadata.kt b/quartz/src/commonMain/kotlin/com/vitorpamplona/quartz/nip47WalletConnect/rpc/NwcTransactionMetadata.kt index bfa0c64788..d5fca147f8 100644 --- a/quartz/src/commonMain/kotlin/com/vitorpamplona/quartz/nip47WalletConnect/rpc/NwcTransactionMetadata.kt +++ b/quartz/src/commonMain/kotlin/com/vitorpamplona/quartz/nip47WalletConnect/rpc/NwcTransactionMetadata.kt @@ -187,7 +187,7 @@ class NwcTransactionMetadata( * of key order, escaping and number formatting matching by coincidence, and * it fails as a silently unlabelled row rather than as an error. Passing the * bytes through also sidesteps the number-widening hazard in - * [com.vitorpamplona.quartz.nip47WalletConnect.kotlinSerialization.toAnyValue], + * [com.vitorpamplona.quartz.nip01Core.kotlinSerialization.toAnyValue], * which resolves untyped numbers with `toDoubleOrNull()` BEFORE * `toLongOrNull()`: nothing here decomposes the event at all. *