Gradle does not download jar from package registry

I’ve got a private repository on GitHub which contains my library.
After setting up Gradle maven-publish plugin I’ve successfully published a private package.

Here is the publishing script:

publishing {

    repositories {
        maven {
            name = "GitHubPackages"
            url = "https://maven.pkg.github.com/H4kt/redstone-framework"
            credentials {
                username = System.getenv("GITHUB_USERNAME") ?: env.GITHUB_USERNAME.orNull()
                password = System.getenv("GITHUB_ACCESS_TOKEN") ?: env.GITHUB_ACCESS_TOKEN.orNull()
            }
        }
    }

    publications {
        shadow(MavenPublication) { publication ->
            publication.artifactId = "redstone-framework"
            project.shadow.component(publication)
        }
    }

}

However when I use this package as a dependency in another project gradle only downloads the pom file, but not the jar.

repositories {

    maven {
        name = "GitHubPackages"
        url = "https://maven.pkg.github.com/H4kt/redstone-framework"
        credentials {
            username = System.getenv("GITHUB_USERNAME") ?: env.GITHUB_USERNAME.orNull()
            password = System.getenv("GITHUB_ACCESS_TOKEN") ?: env.GITHUB_ACCESS_TOKEN.orNull()
        }
    }

}

dependencies {
    implementation 'ru.h4kt:redstone-framework:4.2-dev'
}