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

mockk-android:1.12.6 is not published #883

Closed
3 tasks done
kubode opened this issue Aug 23, 2022 · 6 comments · Fixed by #887
Closed
3 tasks done

mockk-android:1.12.6 is not published #883

kubode opened this issue Aug 23, 2022 · 6 comments · Fixed by #887

Comments

@kubode
Copy link
Contributor

kubode commented Aug 23, 2022

Just be aware about usual MockK support pattern.
Tickets are checked from time to time, replied, discussed, labeled, e.t.c.
But real fixes are applied in a month-two month period in a bunch.
If you think this is unacceptable, go on, join the project, change the world.

Please remove sections wisely

Our project uses mockk-android.
Renovate created a PR to update to 1.12.6, but it does not resolve the dependency.
It seems that mockk-android:1.12.6 is not published.

Is this an intended behavior?

I think #855 is relevant.

Prerequisites

  • I am running the latest version
  • I checked the documentation and found no answer
  • I checked to make sure that this issue has not already been filed

Expected Behavior

Can resolve mockk-android:1.12.6.

Current Behavior

mockk-android:1.12.6 is not published to Maven Central.

https://search.maven.org/search?q=g:io.mockk
image

Failure Information (for bugs)

Please help provide information about the failure if this is a bug. If it is not a bug, please remove the rest of this template.

Steps to Reproduce

  1. Add io.mockk:mockk-android:1.12.6 to dependencies.

Context

  • MockK version: 1.12.6

Failure Logs

Task failed with an exception.
-----------
* What went wrong:
Execution failed for task ':app:androidDependencies'.
> Could not resolve all artifacts for configuration ':app:studentProductionDebugAndroidTestCompileClasspath'.
   > Could not find io.mockk:mockk-android:1.12.6.
     Required by:
         project :app

* Try:
> Run with --stacktrace option to get the stack trace.
> Run with --info or --debug option to get more log output.
> Run with --scan to get full insights.

Minimal reproducible code (the gist of this issue)

dependencies {
    androidTestImplementation("io.mockk:mockk-android:1.12.6")
}
@Sulion
Copy link

Sulion commented Aug 23, 2022

Same with JVM:

Execution failed for task ':compileTestKotlin'.
> Error while evaluating property 'filteredArgumentsMap' of task ':compileTestKotlin'
   > Could not resolve all files for configuration ':testCompileClasspath'.
      > Could not find io.mockk:mockk-jvm:1.12.6.
        Required by:
            project : > io.mockk:mockk:1.12.6

@aSemy
Copy link
Contributor

aSemy commented Aug 23, 2022

Regarding mockk-android, can you try checking out the project and building it?

  1. cd $myProjectsDir
  2. git clone git@github.com:mockk/mockk.git
  3. cd mockk
  4. git fetch --all --tags
  5. git checkout tags/1.12.6 -b 1.12.6-branch
  6. Edit buildSrc/src/main/kotlin/buildsrc/convention/mockk-publishing.gradle.kts buildSrc/src/main/kotlin/buildsrc/convention/mockk-publishing.gradle.kts to comment out line 75
      // signing.sign(this)
  7. ./gradlew publishToMavenLocal -Pversion=1.12.6

For mockk-jvm it seems like something went amiss when publishing to Maven Central.

#872 (comment)

mockk-jvm-1.12.6.pom is still not available, which is unusual. I'm very confused because the .asc signature and checksum files are available, so clearly it existed at some point.

https://repo.maven.apache.org/maven2/io/mockk/mockk-jvm/1.12.6/

image

UPDATE: I've created an issue https://issues.sonatype.org/browse/OSSRH-83851

@SilenLoc
Copy link

Same with JVM:

Execution failed for task ':compileTestKotlin'.
> Error while evaluating property 'filteredArgumentsMap' of task ':compileTestKotlin'
   > Could not resolve all files for configuration ':testCompileClasspath'.
      > Could not find io.mockk:mockk-jvm:1.12.6.
        Required by:
            project : > io.mockk:mockk:1.12.6

same picture for my repos

@kubode
Copy link
Contributor Author

kubode commented Aug 23, 2022

I tried #883 (comment).
mockk-android is not published to mavenLocal.

➜  mockk git:(1.12.6-branch) ✗ ./gradlew publishToMavenLocal -Pversion=1.12.6
➜  mockk git:(1.12.6-branch) ✗ ls ~/.m2/repository/io/mockk/     
mockk               mockk-agent-api     mockk-agent-jvm     mockk-dsl-jvm
mockk-agent         mockk-agent-api-jvm mockk-dsl           mockk-jvm

@aSemy
Copy link
Contributor

aSemy commented Aug 23, 2022

I've replicated mockk-android not being published locally.

If anyone is familiar with publishing Android libs to Maven, please take a look at the Gradle config and check what's missing. Thanks!

Here's the mockk-android subproject Gradle config: https://github.com/mockk/mockk/blob/1.12.6/modules/mockk-android/build.gradle.kts

These are the relevant convention plugins:

@kubode
Copy link
Contributor Author

kubode commented Aug 23, 2022

I'm working on fixing this problem.
I will make a PR soon.

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

Successfully merging a pull request may close this issue.

4 participants