Я пытаюсь опубликовать мою библиотеку Scala.js в Sonatype и выполнил следующие инструкции:
Однако при попытке (окончательной) команды sbt tarjanJS/publishSigned
или sbt publishSigned
я всегда сталкиваюсь с этими ошибками:
Для sbt tarjanJS/publishSigned
:
sbt:scalajs-cross-compile-tarjan> tarjanJS/publishSigned
[info] Wrote /home/florian/Documents/scalajs-cross-compile-tarjan/js/target/scala-2.12/scala-tarjan_sjs0.6_2.12-0.1-SNAPSHOT.pom
[error] gpg: [don't know]: invalid packet (ctb=2d)
[error] gpg: keydb_search failed: Invalid packet
[error] gpg: no default secret key: Invalid packet
[error] gpg: signing failed: Invalid packet
[error] java.lang.RuntimeException: Failure running gpg --detach-sign. Exit code: 2
[error] at scala.sys.package$.error(package.scala:27)
[error] at com.typesafe.sbt.pgp.CommandLineGpgSigner.sign(PgpSigner.scala:27)
[error] at com.typesafe.sbt.pgp.PgpSettings$.$anonfun$signingSettings$2(PgpSettings.scala:157)
[error] at scala.collection.TraversableLike.$anonfun$flatMap$1(TraversableLike.scala:241)
[error] at scala.collection.immutable.Map$Map4.foreach(Map.scala:210)
[error] at scala.collection.TraversableLike.flatMap(TraversableLike.scala:241)
[error] at scala.collection.TraversableLike.flatMap$(TraversableLike.scala:238)
[error] at scala.collection.AbstractTraversable.flatMap(Traversable.scala:104)
[error] at com.typesafe.sbt.pgp.PgpSettings$.$anonfun$signingSettings$1(PgpSettings.scala:154)
[error] at scala.Function1.$anonfun$compose$1(Function1.scala:44)
[error] at sbt.internal.util.$tilde$greater.$anonfun$$u2219$1(TypeFunctions.scala:39)
[error] at sbt.std.Transform$$anon$4.work(System.scala:66)
[error] at sbt.Execute.$anonfun$submit$2(Execute.scala:262)
[error] at sbt.internal.util.ErrorHandling$.wideConvert(ErrorHandling.scala:16)
[error] at sbt.Execute.work(Execute.scala:271)
[error] at sbt.Execute.$anonfun$submit$1(Execute.scala:262)
[error] at sbt.ConcurrentRestrictions$$anon$4.$anonfun$submitValid$1(ConcurrentRestrictions.scala:174)
[error] at sbt.CompletionService$$anon$2.call(CompletionService.scala:36)
[error] at java.util.concurrent.FutureTask.run(FutureTask.java:266)
[error] at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
[error] at java.util.concurrent.FutureTask.run(FutureTask.java:266)
[error] at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
[error] at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
[error] at java.lang.Thread.run(Thread.java:748)
[error] (tarjanJS / signedArtifacts) Failure running gpg --detach-sign. Exit code: 2
Для sbt publishSigned
:
bt:scalajs-cross-compile-tarjan> publishSigned
[info] Wrote /home/florian/Documents/scalajs-cross-compile-tarjan/js/target/scala-2.12/scala-tarjan_sjs0.6_2.12-0.1-SNAPSHOT.pom
[info] Wrote /home/florian/Documents/scalajs-cross-compile-tarjan/jvm/target/scala-2.12/scala-tarjan_2.12-0.1-SNAPSHOT.pom
[info] Wrote /home/florian/Documents/scalajs-cross-compile-tarjan/target/scala-2.12/scalajs-cross-compile-tarjan_2.12-0.1.0-SNAPSHOT.pom
[error] gpg: [don't know]: invalid packet (ctb=2d)
[error] gpg: keydb_search failed: Invalid packet
[error] gpg: no default secret key: Invalid packet
[error] gpg: signing failed: Invalid packet
[error] gpg: [don't know]: invalid packet (ctb=2d)
[error] gpg: keydb_search failed: Invalid packet
[error] gpg: no default secret key: Invalid packet
[error] gpg: signing failed: Invalid packet
[error] gpg: [don't know]: invalid packet (ctb=2d)
[error] gpg: keydb_search failed: Invalid packet
[error] gpg: no default secret key: Invalid packet
[error] gpg: signing failed: Invalid packet
[error] java.lang.RuntimeException: Failure running gpg --detach-sign. Exit code: 2
[error] at scala.sys.package$.error(package.scala:27)
[error] at com.typesafe.sbt.pgp.CommandLineGpgSigner.sign(PgpSigner.scala:27)
[error] at com.typesafe.sbt.pgp.PgpSettings$.$anonfun$signingSettings$2(PgpSettings.scala:157)
[error] at scala.collection.TraversableLike.$anonfun$flatMap$1(TraversableLike.scala:241)
[error] at scala.collection.immutable.Map$Map4.foreach(Map.scala:210)
[error] at scala.collection.TraversableLike.flatMap(TraversableLike.scala:241)
[error] at scala.collection.TraversableLike.flatMap$(TraversableLike.scala:238)
[error] at scala.collection.AbstractTraversable.flatMap(Traversable.scala:104)
[error] at com.typesafe.sbt.pgp.PgpSettings$.$anonfun$signingSettings$1(PgpSettings.scala:154)
[error] at scala.Function1.$anonfun$compose$1(Function1.scala:44)
[error] at sbt.internal.util.$tilde$greater.$anonfun$$u2219$1(TypeFunctions.scala:39)
[error] at sbt.std.Transform$$anon$4.work(System.scala:66)
[error] at sbt.Execute.$anonfun$submit$2(Execute.scala:262)
[error] at sbt.internal.util.ErrorHandling$.wideConvert(ErrorHandling.scala:16)
[error] at sbt.Execute.work(Execute.scala:271)
[error] at sbt.Execute.$anonfun$submit$1(Execute.scala:262)
[error] at sbt.ConcurrentRestrictions$$anon$4.$anonfun$submitValid$1(ConcurrentRestrictions.scala:174)
[error] at sbt.CompletionService$$anon$2.call(CompletionService.scala:36)
[error] at java.util.concurrent.FutureTask.run(FutureTask.java:266)
[error] at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
[error] at java.util.concurrent.FutureTask.run(FutureTask.java:266)
[error] at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
[error] at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
[error] at java.lang.Thread.run(Thread.java:748)
[error] java.lang.RuntimeException: Failure running gpg --detach-sign. Exit code: 2
[error] at scala.sys.package$.error(package.scala:27)
[error] at com.typesafe.sbt.pgp.CommandLineGpgSigner.sign(PgpSigner.scala:27)
[error] at com.typesafe.sbt.pgp.PgpSettings$.$anonfun$signingSettings$2(PgpSettings.scala:157)
[error] at scala.collection.TraversableLike.$anonfun$flatMap$1(TraversableLike.scala:241)
[error] at scala.collection.immutable.Map$Map4.foreach(Map.scala:210)
[error] at scala.collection.TraversableLike.flatMap(TraversableLike.scala:241)
[error] at scala.collection.TraversableLike.flatMap$(TraversableLike.scala:238)
[error] at scala.collection.AbstractTraversable.flatMap(Traversable.scala:104)
[error] at com.typesafe.sbt.pgp.PgpSettings$.$anonfun$signingSettings$1(PgpSettings.scala:154)
[error] at scala.Function1.$anonfun$compose$1(Function1.scala:44)
[error] at sbt.internal.util.$tilde$greater.$anonfun$$u2219$1(TypeFunctions.scala:39)
[error] at sbt.std.Transform$$anon$4.work(System.scala:66)
[error] at sbt.Execute.$anonfun$submit$2(Execute.scala:262)
[error] at sbt.internal.util.ErrorHandling$.wideConvert(ErrorHandling.scala:16)
[error] at sbt.Execute.work(Execute.scala:271)
[error] at sbt.Execute.$anonfun$submit$1(Execute.scala:262)
[error] at sbt.ConcurrentRestrictions$$anon$4.$anonfun$submitValid$1(ConcurrentRestrictions.scala:174)
[error] at sbt.CompletionService$$anon$2.call(CompletionService.scala:36)
[error] at java.util.concurrent.FutureTask.run(FutureTask.java:266)
[error] at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
[error] at java.util.concurrent.FutureTask.run(FutureTask.java:266)
[error] at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
[error] at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
[error] at java.lang.Thread.run(Thread.java:748)
[error] java.lang.RuntimeException: Failure running gpg --detach-sign. Exit code: 2
[error] at scala.sys.package$.error(package.scala:27)
[error] at com.typesafe.sbt.pgp.CommandLineGpgSigner.sign(PgpSigner.scala:27)
[error] at com.typesafe.sbt.pgp.PgpSettings$.$anonfun$signingSettings$2(PgpSettings.scala:157)
[error] at scala.collection.TraversableLike.$anonfun$flatMap$1(TraversableLike.scala:241)
[error] at scala.collection.immutable.Map$Map4.foreach(Map.scala:210)
[error] at scala.collection.TraversableLike.flatMap(TraversableLike.scala:241)
[error] at scala.collection.TraversableLike.flatMap$(TraversableLike.scala:238)
[error] at scala.collection.AbstractTraversable.flatMap(Traversable.scala:104)
[error] at com.typesafe.sbt.pgp.PgpSettings$.$anonfun$signingSettings$1(PgpSettings.scala:154)
[error] at scala.Function1.$anonfun$compose$1(Function1.scala:44)
[error] at sbt.internal.util.$tilde$greater.$anonfun$$u2219$1(TypeFunctions.scala:39)
[error] at sbt.std.Transform$$anon$4.work(System.scala:66)
[error] at sbt.Execute.$anonfun$submit$2(Execute.scala:262)
[error] at sbt.internal.util.ErrorHandling$.wideConvert(ErrorHandling.scala:16)
[error] at sbt.Execute.work(Execute.scala:271)
[error] at sbt.Execute.$anonfun$submit$1(Execute.scala:262)
[error] at sbt.ConcurrentRestrictions$$anon$4.$anonfun$submitValid$1(ConcurrentRestrictions.scala:174)
[error] at sbt.CompletionService$$anon$2.call(CompletionService.scala:36)
[error] at java.util.concurrent.FutureTask.run(FutureTask.java:266)
[error] at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
[error] at java.util.concurrent.FutureTask.run(FutureTask.java:266)
[error] at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
[error] at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
[error] at java.lang.Thread.run(Thread.java:748)
[error] (tarjanJS / signedArtifacts) Failure running gpg --detach-sign. Exit code: 2
[error] (tarjanJVM / signedArtifacts) Failure running gpg --detach-sign. Exit code: 2
[error] (signedArtifacts) Failure running gpg --detach-sign. Exit code: 2
[error] Total time: 1 s, completed Nov 3, 2018 1:22:02 PM
Какой-нибудь совет, где искать ошибку? Я почти уверен, что дословно следовал инструкциям и делал это несколько раз ...
Моя версия gpg:
gpg (GnuPG) 2.2.4
libgcrypt 1.8.1
Copyright (C) 2017 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <https://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.
Home: /home/florian/.gnupg
Supported algorithms:
Pubkey: RSA, ELG, DSA, ECDH, ECDSA, EDDSA
Cipher: IDEA, 3DES, CAST5, BLOWFISH, AES, AES192, AES256, TWOFISH,
CAMELLIA128, CAMELLIA192, CAMELLIA256
Hash: SHA1, RIPEMD160, SHA256, SHA384, SHA512, SHA224
Compression: Uncompressed, ZIP, ZLIB, BZIP2
Это файлы в моей папке .gnupg
:
*.gnupg* ls
crls.d openpgp-revocs.d private-keys-v1.d pubring.kbx pubring.kbx~ sshcontrol trustdb.gpg
А папка private-keys-v1.d
содержит два .key
файла.
При запуске gpg --list-keys
получаю следующее:
~ gpg --list-keys
/home/florian/.gnupg/pubring.kbx
--------------------------------
pub rsa3072 2018-11-03 [SC] [expires: 2020-11-02]
XXXXXXXXXXXXXXXXXXXXXXXXXXXX
uid [ultimate] Florian Baierl <fbaierl1@gmail.com>
sub rsa3072 2018-11-03 [E] [expires: 2020-11-02]
Мне было интересно, может быть, это pubring.kbx
это проблема? В уроке говорится, что он должен распечатать что-то вроде pubring.gpg
.