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

Cannot add artifact 'foo.pom' to configuration 'pom' while running checkPgpSignatures #139

Closed
pathikrit opened this issue Jul 25, 2018 · 3 comments

Comments

@pathikrit
Copy link

I followed step by step instruction specified here: https://www.scala-sbt.org/sbt-pgp/usage.html

Step 1: Generate GPG key

> gpg --gen-key

gpg (GnuPG) 2.2.7; Copyright (C) 2018 Free Software Foundation, Inc.
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.

Note: Use "gpg --full-generate-key" for a full featured key generation dialog.

GnuPG needs to construct a user ID to identify your key.

Real name: Pathikrit Bhowmick
Email address: [email protected]
You selected this USER-ID:              
    "Pathikrit Bhowmick <[email protected]>"

Change (N)ame, (E)mail, or (O)kay/(Q)uit? O
We need to generate a lot of random bytes. It is a good idea to perform
some other action (type on the keyboard, move the mouse, utilize the
disks) during the prime generation; this gives the random number
generator a better chance to gain enough entropy.
We need to generate a lot of random bytes. It is a good idea to perform
some other action (type on the keyboard, move the mouse, utilize the
disks) during the prime generation; this gives the random number
generator a better chance to gain enough entropy.
gpg: key 66AA02EC8AA60DB9 marked as ultimately trusted
gpg: directory '/Users/pbhowmick/.gnupg/openpgp-revocs.d' created
gpg: revocation certificate stored as '/Users/pbhowmick/.gnupg/openpgp-revocs.d/F5003E5C4718B1F466B244F766AA02EC8AA60DB9.rev'
public and secret key created and signed.

pub   rsa2048 2018-07-24 [SC] [expires: 2020-07-23]
      F5003E5C4718B1F466B244F766AA02EC8AA60DB9
uid                      Pathikrit Bhowmick <[email protected]>
sub   rsa2048 2018-07-24 [E] [expires: 2020-07-23]

Step 2: Validate PGP keys in sbt shell

sbt:better-files-root> checkPgpSignatures
[error] java.lang.IllegalArgumentException: Cannot add artifact 'better-files_2.12.pom' to configuration 'pom' of module com.github.pathikrit#better-files_2.12;3.6.0-RC1 because this configuration doesn't exist!
[error]         at org.apache.ivy.core.module.descriptor.DefaultModuleDescriptor.addArtifact(DefaultModuleDescriptor.java:371)
[error]         at sbt.internal.librarymanagement.IvySbt$.$anonfun$addArtifacts$2(Ivy.scala:1044)
[error]         at sbt.internal.librarymanagement.IvySbt$.$anonfun$addArtifacts$2$adapted(Ivy.scala:1043)
[error]         at scala.collection.IndexedSeqOptimized.foreach(IndexedSeqOptimized.scala:32)
[error]         at scala.collection.IndexedSeqOptimized.foreach$(IndexedSeqOptimized.scala:29)
[error]         at scala.collection.mutable.ArrayOps$ofRef.foreach(ArrayOps.scala:194)
[error]         at sbt.internal.librarymanagement.IvySbt$.$anonfun$addArtifacts$1(Ivy.scala:1043)
[error]         at sbt.internal.librarymanagement.IvySbt$.$anonfun$addArtifacts$1$adapted(Ivy.scala:1043)
[error]         at scala.collection.Iterator.foreach(Iterator.scala:944)
[error]         at scala.collection.Iterator.foreach$(Iterator.scala:944)
[error]         at scala.collection.AbstractIterator.foreach(Iterator.scala:1432)
[error]         at scala.collection.IterableLike.foreach(IterableLike.scala:71)
[error]         at scala.collection.IterableLike.foreach$(IterableLike.scala:70)
[error]         at scala.collection.AbstractIterable.foreach(Iterable.scala:54)
[error]         at sbt.internal.librarymanagement.IvySbt$.addArtifacts(Ivy.scala:1043)
[error]         at sbt.internal.librarymanagement.IvySbt$Module.newConfiguredModuleID(Ivy.scala:314)
[error]         at sbt.internal.librarymanagement.IvySbt$Module.configureInline(Ivy.scala:275)
[error]         at sbt.internal.librarymanagement.IvySbt$Module.x$7$lzycompute(Ivy.scala:257)
[error]         at sbt.internal.librarymanagement.IvySbt$Module.x$7(Ivy.scala:254)
[error]         at sbt.internal.librarymanagement.IvySbt$Module.moduleDescriptor0$lzycompute(Ivy.scala:254)
[error]         at sbt.internal.librarymanagement.IvySbt$Module.moduleDescriptor0(Ivy.scala:254)
[error]         at sbt.internal.librarymanagement.IvySbt$Module.$anonfun$withModule$1(Ivy.scala:243)
[error]         at sbt.internal.librarymanagement.IvySbt.$anonfun$withIvy$1(Ivy.scala:204)
[error]         at sbt.internal.librarymanagement.IvySbt.sbt$internal$librarymanagement$IvySbt$$action$1(Ivy.scala:70)
[error]         at sbt.internal.librarymanagement.IvySbt$$anon$3.call(Ivy.scala:77)
[error]         at xsbt.boot.Locks$GlobalLock.withChannel$1(Locks.scala:95)
[error]         at xsbt.boot.Locks$GlobalLock.xsbt$boot$Locks$GlobalLock$$withChannelRetries$1(Locks.scala:80)
[error]         at xsbt.boot.Locks$GlobalLock$$anonfun$withFileLock$1.apply(Locks.scala:99)
[error]         at xsbt.boot.Using$.withResource(Using.scala:10)
[error]         at xsbt.boot.Using$.apply(Using.scala:9)
[error]         at xsbt.boot.Locks$GlobalLock.ignoringDeadlockAvoided(Locks.scala:60)
[error]         at xsbt.boot.Locks$GlobalLock.withLock(Locks.scala:50)
[error]         at xsbt.boot.Locks$.apply0(Locks.scala:31)
[error]         at xsbt.boot.Locks$.apply(Locks.scala:28)
[error]         at sbt.internal.librarymanagement.IvySbt.withDefaultLogger(Ivy.scala:77)
[error]         at sbt.internal.librarymanagement.IvySbt.withIvy(Ivy.scala:199)
[error]         at sbt.internal.librarymanagement.IvySbt.withIvy(Ivy.scala:196)
[error]         at sbt.internal.librarymanagement.IvySbt$Module.withModule(Ivy.scala:242)
[error]         at sbt.internal.librarymanagement.IvyActions$.updateEither(IvyActions.scala:193)
[error]         at sbt.sbtpgp.Compat$.updateEither(Compat.scala:55)
[error]         at com.typesafe.sbt.pgp.PgpSignatureCheck$.resolveSignatures(PgpSignatureCheck.scala:72)
[error]         at com.typesafe.sbt.pgp.PgpSettings$.$anonfun$verifySettings$2(PgpSettings.scala:201)
[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:263)
[error]         at sbt.internal.util.ErrorHandling$.wideConvert(ErrorHandling.scala:16)
[error]         at sbt.Execute.work(Execute.scala:272)
[error]         at sbt.Execute.$anonfun$submit$1(Execute.scala:263)
[error]         at sbt.ConcurrentRestrictions$$anon$4.$anonfun$submitValid$1(ConcurrentRestrictions.scala:174)
[error]         at sbt.CompletionService$$anon$2.call(CompletionService.scala:37)
[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.IllegalArgumentException: Cannot add artifact 'better-files-akka_2.12.pom' to configuration 'pom' of module com.github.pathikrit#better-files-akka_2.12;3.6.0-RC1 because this configuration doesn't exist!
[error]         at org.apache.ivy.core.module.descriptor.DefaultModuleDescriptor.addArtifact(DefaultModuleDescriptor.java:371)
[error]         at sbt.internal.librarymanagement.IvySbt$.$anonfun$addArtifacts$2(Ivy.scala:1044)
[error]         at sbt.internal.librarymanagement.IvySbt$.$anonfun$addArtifacts$2$adapted(Ivy.scala:1043)
[error]         at scala.collection.IndexedSeqOptimized.foreach(IndexedSeqOptimized.scala:32)
[error]         at scala.collection.IndexedSeqOptimized.foreach$(IndexedSeqOptimized.scala:29)
[error]         at scala.collection.mutable.ArrayOps$ofRef.foreach(ArrayOps.scala:194)
[error]         at sbt.internal.librarymanagement.IvySbt$.$anonfun$addArtifacts$1(Ivy.scala:1043)
[error]         at sbt.internal.librarymanagement.IvySbt$.$anonfun$addArtifacts$1$adapted(Ivy.scala:1043)
[error]         at scala.collection.Iterator.foreach(Iterator.scala:944)
[error]         at scala.collection.Iterator.foreach$(Iterator.scala:944)
[error]         at scala.collection.AbstractIterator.foreach(Iterator.scala:1432)
[error]         at scala.collection.IterableLike.foreach(IterableLike.scala:71)
[error]         at scala.collection.IterableLike.foreach$(IterableLike.scala:70)
[error]         at scala.collection.AbstractIterable.foreach(Iterable.scala:54)
[error]         at sbt.internal.librarymanagement.IvySbt$.addArtifacts(Ivy.scala:1043)
[error]         at sbt.internal.librarymanagement.IvySbt$Module.newConfiguredModuleID(Ivy.scala:314)
[error]         at sbt.internal.librarymanagement.IvySbt$Module.configureInline(Ivy.scala:275)
[error]         at sbt.internal.librarymanagement.IvySbt$Module.x$7$lzycompute(Ivy.scala:257)
[error]         at sbt.internal.librarymanagement.IvySbt$Module.x$7(Ivy.scala:254)
[error]         at sbt.internal.librarymanagement.IvySbt$Module.moduleDescriptor0$lzycompute(Ivy.scala:254)
[error]         at sbt.internal.librarymanagement.IvySbt$Module.moduleDescriptor0(Ivy.scala:254)
[error]         at sbt.internal.librarymanagement.IvySbt$Module.$anonfun$withModule$1(Ivy.scala:243)
[error]         at sbt.internal.librarymanagement.IvySbt.$anonfun$withIvy$1(Ivy.scala:204)
[error]         at sbt.internal.librarymanagement.IvySbt.sbt$internal$librarymanagement$IvySbt$$action$1(Ivy.scala:70)
[error]         at sbt.internal.librarymanagement.IvySbt$$anon$3.call(Ivy.scala:77)
[error]         at xsbt.boot.Locks$GlobalLock.withChannel$1(Locks.scala:95)
[error]         at xsbt.boot.Locks$GlobalLock.xsbt$boot$Locks$GlobalLock$$withChannelRetries$1(Locks.scala:80)
[error]         at xsbt.boot.Locks$GlobalLock$$anonfun$withFileLock$1.apply(Locks.scala:99)
[error]         at xsbt.boot.Using$.withResource(Using.scala:10)
[error]         at xsbt.boot.Using$.apply(Using.scala:9)
[error]         at xsbt.boot.Locks$GlobalLock.ignoringDeadlockAvoided(Locks.scala:60)
[error]         at xsbt.boot.Locks$GlobalLock.withLock(Locks.scala:50)
[error]         at xsbt.boot.Locks$.apply0(Locks.scala:31)
[error]         at xsbt.boot.Locks$.apply(Locks.scala:28)
[error]         at sbt.internal.librarymanagement.IvySbt.withDefaultLogger(Ivy.scala:77)
[error]         at sbt.internal.librarymanagement.IvySbt.withIvy(Ivy.scala:199)
[error]         at sbt.internal.librarymanagement.IvySbt.withIvy(Ivy.scala:196)
[error]         at sbt.internal.librarymanagement.IvySbt$Module.withModule(Ivy.scala:242)
[error]         at sbt.internal.librarymanagement.IvyActions$.updateEither(IvyActions.scala:193)
[error]         at sbt.sbtpgp.Compat$.updateEither(Compat.scala:55)
[error]         at com.typesafe.sbt.pgp.PgpSignatureCheck$.resolveSignatures(PgpSignatureCheck.scala:72)
[error]         at com.typesafe.sbt.pgp.PgpSettings$.$anonfun$verifySettings$2(PgpSettings.scala:201)
[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:263)
[error]         at sbt.internal.util.ErrorHandling$.wideConvert(ErrorHandling.scala:16)
[error]         at sbt.Execute.work(Execute.scala:272)
[error]         at sbt.Execute.$anonfun$submit$1(Execute.scala:263)
[error]         at sbt.ConcurrentRestrictions$$anon$4.$anonfun$submitValid$1(ConcurrentRestrictions.scala:174)
[error]         at sbt.CompletionService$$anon$2.call(CompletionService.scala:37)
[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.IllegalArgumentException: Cannot add artifact 'better-files-root_2.12.pom' to configuration 'pom' of module com.github.pathikrit#better-files-root_2.12;3.6.0-RC1 because this configuration doesn't exist!
[error]         at org.apache.ivy.core.module.descriptor.DefaultModuleDescriptor.addArtifact(DefaultModuleDescriptor.java:371)
[error]         at sbt.internal.librarymanagement.IvySbt$.$anonfun$addArtifacts$2(Ivy.scala:1044)
[error]         at sbt.internal.librarymanagement.IvySbt$.$anonfun$addArtifacts$2$adapted(Ivy.scala:1043)
[error]         at scala.collection.IndexedSeqOptimized.foreach(IndexedSeqOptimized.scala:32)
[error]         at scala.collection.IndexedSeqOptimized.foreach$(IndexedSeqOptimized.scala:29)
[error]         at scala.collection.mutable.ArrayOps$ofRef.foreach(ArrayOps.scala:194)
[error]         at sbt.internal.librarymanagement.IvySbt$.$anonfun$addArtifacts$1(Ivy.scala:1043)
[error]         at sbt.internal.librarymanagement.IvySbt$.$anonfun$addArtifacts$1$adapted(Ivy.scala:1043)
[error]         at scala.collection.Iterator.foreach(Iterator.scala:944)
[error]         at scala.collection.Iterator.foreach$(Iterator.scala:944)
[error]         at scala.collection.AbstractIterator.foreach(Iterator.scala:1432)
[error]         at scala.collection.IterableLike.foreach(IterableLike.scala:71)
[error]         at scala.collection.IterableLike.foreach$(IterableLike.scala:70)
[error]         at scala.collection.AbstractIterable.foreach(Iterable.scala:54)
[error]         at sbt.internal.librarymanagement.IvySbt$.addArtifacts(Ivy.scala:1043)
[error]         at sbt.internal.librarymanagement.IvySbt$Module.newConfiguredModuleID(Ivy.scala:314)
[error]         at sbt.internal.librarymanagement.IvySbt$Module.configureInline(Ivy.scala:275)
[error]         at sbt.internal.librarymanagement.IvySbt$Module.x$7$lzycompute(Ivy.scala:257)
[error]         at sbt.internal.librarymanagement.IvySbt$Module.x$7(Ivy.scala:254)
[error]         at sbt.internal.librarymanagement.IvySbt$Module.moduleDescriptor0$lzycompute(Ivy.scala:254)
[error]         at sbt.internal.librarymanagement.IvySbt$Module.moduleDescriptor0(Ivy.scala:254)
[error]         at sbt.internal.librarymanagement.IvySbt$Module.$anonfun$withModule$1(Ivy.scala:243)
[error]         at sbt.internal.librarymanagement.IvySbt.$anonfun$withIvy$1(Ivy.scala:204)
[error]         at sbt.internal.librarymanagement.IvySbt.sbt$internal$librarymanagement$IvySbt$$action$1(Ivy.scala:70)
[error]         at sbt.internal.librarymanagement.IvySbt$$anon$3.call(Ivy.scala:77)
[error]         at xsbt.boot.Locks$GlobalLock.withChannel$1(Locks.scala:95)
[error]         at xsbt.boot.Locks$GlobalLock.xsbt$boot$Locks$GlobalLock$$withChannelRetries$1(Locks.scala:80)
[error]         at xsbt.boot.Locks$GlobalLock$$anonfun$withFileLock$1.apply(Locks.scala:99)
[error]         at xsbt.boot.Using$.withResource(Using.scala:10)
[error]         at xsbt.boot.Using$.apply(Using.scala:9)
[error]         at xsbt.boot.Locks$GlobalLock.ignoringDeadlockAvoided(Locks.scala:60)
[error]         at xsbt.boot.Locks$GlobalLock.withLock(Locks.scala:50)
[error]         at xsbt.boot.Locks$.apply0(Locks.scala:31)
[error]         at xsbt.boot.Locks$.apply(Locks.scala:28)
[error]         at sbt.internal.librarymanagement.IvySbt.withDefaultLogger(Ivy.scala:77)
[error]         at sbt.internal.librarymanagement.IvySbt.withIvy(Ivy.scala:199)
[error]         at sbt.internal.librarymanagement.IvySbt.withIvy(Ivy.scala:196)
[error]         at sbt.internal.librarymanagement.IvySbt$Module.withModule(Ivy.scala:242)
[error]         at sbt.internal.librarymanagement.IvyActions$.updateEither(IvyActions.scala:193)
[error]         at sbt.sbtpgp.Compat$.updateEither(Compat.scala:55)
[error]         at com.typesafe.sbt.pgp.PgpSignatureCheck$.resolveSignatures(PgpSignatureCheck.scala:72)
[error]         at com.typesafe.sbt.pgp.PgpSettings$.$anonfun$verifySettings$2(PgpSettings.scala:201)
[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:263)
[error]         at sbt.internal.util.ErrorHandling$.wideConvert(ErrorHandling.scala:16)
[error]         at sbt.Execute.work(Execute.scala:272)
[error]         at sbt.Execute.$anonfun$submit$1(Execute.scala:263)
[error]         at sbt.ConcurrentRestrictions$$anon$4.$anonfun$submitValid$1(ConcurrentRestrictions.scala:174)
[error]         at sbt.CompletionService$$anon$2.call(CompletionService.scala:37)
[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] (core / updatePgpSignatures) java.lang.IllegalArgumentException: Cannot add artifact 'better-files_2.12.pom' to configuration 'pom' of module com.github.pathikrit#better-files_2.12;3.6.0-RC1 because this configuration doesn't exist!
[error] (akka / updatePgpSignatures) java.lang.IllegalArgumentException: Cannot add artifact 'better-files-akka_2.12.pom' to configuration 'pom' of module com.github.pathikrit#better-files-akka_2.12;3.6.0-RC1 because this configuration doesn't exist!
[error] (updatePgpSignatures) java.lang.IllegalArgumentException: Cannot add artifact 'better-files-root_2.12.pom' to configuration 'pom' of module com.github.pathikrit#better-files-root_2.12;3.6.0-RC1 because this configuration doesn't exist!
@jamesward
Copy link

Switching to the 2.0.0-M2 release resolves this for me.

@kovszilard
Copy link

I have the same problem.
sbt-pgp: 2.0.0-M2
sbt: 1.2.8
scala: 2.12.8
there is an other open issue for this #156

@eed3si9n eed3si9n changed the title sbt-pgp documentation gives error Cannot add artifact 'foo.pom' to configuration 'pom' while running checkPgpSignatures Sep 15, 2019
@eed3si9n
Copy link
Member

Looks like this is also a duplicate of #129

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

No branches or pull requests

4 participants