https://kotlinlang.org logo
Join the conversationJoin Slack
Channels
100daysofcode
100daysofkotlin
100daysofkotlin-2021
advent-of-code
aem
ai
alexa
algeria
algolialibraries
amsterdam
android
android-architecture
android-databinding
android-studio
androidgithubprojects
androidthings
androidx
androidx-xprocessing
anime
anko
announcements
apollo-kotlin
appintro
arabic
argentina
arkenv
arksemdevteam
armenia
arrow
arrow-contributors
arrow-meta
ass
atlanta
atm17
atrium
austin
australia
austria
awesome-kotlin
ballast
bangladesh
barcelona
bayarea
bazel
beepiz-libraries
belgium
berlin
big-data
books
boston
brazil
brikk
budapest
build
build-tools
bulgaria
bydgoszcz
cambodia
canada
carrat
carrat-dev
carrat-feed
chicago
chile
china
chucker
cincinnati-user-group
cli
clikt
cloudfoundry
cn
cobalt
code-coverage
codeforces
codemash-precompiler
codereview
codingame
codingconventions
coimbatore
collaborations
colombia
colorado
communities
competitive-programming
competitivecoding
compiler
compose
compose-android
compose-desktop
compose-hiring
compose-ios
compose-mp
compose-ui-showcase
compose-wear
compose-web
connect-audit-events
corda
cork
coroutines
couchbase
coursera
croatia
cryptography
cscenter-course-2016
cucumber-bdd
cyprus
czech
dagger
data2viz
databinding
datascience
dckotlin
debugging
decompose
decouple
denmark
deprecated
detekt
detekt-hint
dev-core
dfw
docs-revamped
dokka
domain-driven-design
doodle
dsl
dublin
dutch
eap
eclipse
ecuador
edinburgh
education
effective-kotlin
effectivekotlin
emacs
embedded-kotlin
estatik
event21-community-content
events
exposed
failgood
fb-internal-demo
feed
firebase
flow
fluid-libraries
forkhandles
forum
fosdem
fp-in-kotlin
framework-elide
freenode
french
fritz2
fuchsia
functional
funktionale
gamedev
ge-kotlin
general-advice
georgia
geospatial
german-lang
getting-started
github-workflows-kt
glance
godot-kotlin
google-io
gradle
graphic
graphkool
graphql
graphql-kotlin
graviton-browser
greece
grpc
gsoc
gui
hackathons
hacktoberfest
hamburg
hamkrest
helios
helsinki
hexagon
hibernate
hikari-cp
hire-me
hiring
hongkong
hoplite
http4k
hungary
hyderabad
image-processing
india
indonesia
inkremental
intellij
intellij-plugins
intellij-tricks
internships
introduce-yourself
io
ios
iran
israel
istanbulcoders
italian
jackson-kotlin
jadx
japanese
jasync-sql
java-to-kotlin-refactoring
javadevelopers
javafx
javalin
javascript
jdbi
jhipster-kotlin
jobsworldwide
jpa
jshdq
juul-libraries
jvm-ir-backend-feedback
jxadapter
k2-early-adopters
kaal
kafka
kakao
kalasim
kapt
karachi
karg
karlsruhe
kash_shell
kaskade
kbuild
kdbc
kgen-doc-tools
kgraphql
kinta
klaxon
klock
kloudformation
kmdc
kmm-español
kmongo
knbt
knote
koalaql
koans
kobalt
kobweb
kodein
kodex
kohesive
koin
koin-dev
komapper
kondor-json
kong
kontent
kontributors
korau
korean
korge
korim
korio
korlibs
korte
kotest
kotest-contributors
kotless
kotlick
kotlin-asia
kotlin-beam
kotlin-by-example
kotlin-csv
kotlin-data-storage
kotlin-foundation
kotlin-fuel
kotlin-in-action
kotlin-inject
kotlin-latam
kotlin-logging
kotlin-multiplatform-contest
kotlin-mumbai
kotlin-native
kotlin-pakistan
kotlin-plugin
kotlin-pune
kotlin-roadmap
kotlin-samples
kotlin-sap
kotlin-serbia
kotlin-spark
kotlin-szeged
kotlin-website
kotlinacademy
kotlinbot
kotlinconf
kotlindl
kotlinforbeginners
kotlingforbeginners
kotlinlondon
kotlinmad
kotlinprogrammers
kotlinsu
kotlintest
kotlintest-devs
kotlintlv
kotlinultimatechallenge
kotlinx-datetime
kotlinx-files
kotlinx-html
kotrix
kotson
kovenant
kprompt
kraph
krawler
kroto-plus
ksp
ktcc
ktfmt
ktlint
ktor
ktp
kubed
kug-leads
kug-torino
kvision
kweb
lambdaworld_cadiz
lanark
language-evolution
language-proposals
latvia
leakcanary
leedskotlinusergroup
lets-have-fun
libgdx
libkgd
library-development
linkeddata
lithuania
london
losangeles
lottie
love
lychee
macedonia
machinelearningbawas
madrid
malaysia
mathematics
meetkotlin
memes
meta
metro-detroit
mexico
miami
micronaut
minnesota
minutest
mirror
mockk
moko
moldova
monsterpuzzle
montreal
moonbean
morocco
motionlayout
mpapt
mu
multiplatform
mumbai
munich
mvikotlin
mvrx
myndocs-oauth2-server
naming
navigation-architecture-component
nepal
new-mexico
new-zealand
newname
nigeria
nodejs
norway
npm-publish
nyc
oceania
ohio-kotlin-users
oldenburg
oolong
opensource
orbit-mvi
osgi
otpisani
package-search
pakistan
panamá
pattern-matching
pbandk
pdx
peru
philippines
phoenix
pinoy
pocketgitclient
polish
popkorn
portugal
practical-functional-programming
proguard
prozis-android-backup
pyhsikal
python
python-contributors
quasar
random
re
react
reaktive
realm
realworldkotlin
reductor
reduks
redux
redux-kotlin
refactoring-to-kotlin
reflect
refreshversions
reports
result
rethink
revolver
rhein-main
rocksdb
romania
room
rpi-pico
rsocket
russian
russian_feed
russian-kotlinasfirst
rx
rxjava
san-diego
science
scotland
scrcast
scrimage
script
scripting
seattle
serialization
server
sg-user-group
singapore
skia-wasm-interop-temp
skrape-it
slovak
snake
sofl-user-group
southafrica
spacemacs
spain
spanish
speaking
spek
spin
splitties
spotify-mobius
spring
spring-security
squarelibraries
stackoverflow
stacks
stayhungrystayfoolish
stdlib
stlouis
strife-discord-lib
strikt
students
stuttgart
sudan
swagger-gradle-codegen
swarm
sweden
swing
swiss-user-group
switzerland
talking-kotlin
tallinn
tampa
teamcity
tegal
tempe
tensorflow
terminal
test
testing
testtestest
texas
tgbotapi
thailand
tornadofx
touchlab-tools
training
tricity-kotlin-user-group
trójmiasto
truth
tunisia
turkey
turkiye
twitter-feed
uae
udacityindia
uk
ukrainian
uniflow
unkonf
uruguay
utah
uuid
vancouver
vankotlin
vertx
videos
vienna
vietnam
vim
vkug
vuejs
web-mpp
webassembly
webrtc
wimix_sentry
wwdc
zircon
Powered by Linen
refreshversions
  • j

    jmfayard

    10/24/2019, 3:25 AM
    that's possible yes. We have a problem currently with KMP projects to find available updates. Maybe a similar issue exists when propagating the versions. How can I reproduce the bug?
    s
    l
    • 3
    • 4
  • j

    jmfayard

    11/11/2019, 2:15 PM
    I have discovered this website https://libraries.io/ You can search for a dependency and see immediatly its latest release For example https://libraries.io/maven/com.squareup.okhttp3:okhttp It provides an API https://libraries.io/api That could make the experimental update much faster! What do you think @louiscad ?
    s
    l
    • 3
    • 5
  • j

    jmfayard

    11/16/2019, 7:46 AM
    When you google "gradle dependencies management" you have lots of things already. - The dependencies management on the gradle website, - Spring dependencies management, - .... https://www.google.com/search?q=gradle%20dependencies%20management&safe=off&cad=h
    l
    • 2
    • 3
  • b

    breandan

    01/13/2020, 11:27 AM
    I’m still not sure how to get Gradle plugins inside the
    plugins
    section to read from the versions file but the
    dependencies
    versions appear to work well
    l
    • 2
    • 1
  • d

    Danilo Pianini

    04/06/2020, 1:33 PM
    As I described here: https://github.com/jmfayard/refreshVersions/issues/178 I prepared a bot that is able to apply refreshVersions updates one by one, and opens a pull request to allow semi-automatic management of upgrades. I'm gradually rolling it out on my own projects, and it seems to work well. @louiscad told me that @mbonnin might be interested, so here I am :)
    m
    l
    • 3
    • 2
  • n

    nkiesel

    05/02/2020, 1:56 AM
    I just tried my first baby-steps but got stuck after the Gradge 6 upgrade. My
    settings.gradle
    starts with
    pluginManagement { repositories { gradlePluginPortal() } plugins { id "org.jetbrains.kotlin.jvm" version "1.3.60" ...
    (with proper whitespace) and I could not add the new stuff in there. So I removed the references to plugin
    buildSrcVersions
    in both
    settings.gradle
    and
    build.gradle
    , added
    refreshVersions
    and
    dependencies
    to both, and added
    buildScript.dependencies.classpath "de.fayard:dependencies:0.5.8"
    and the
    import
    to
    build.gradle
    . This gets me past the "import" (note: 0.5.8 seems to have changes the layout and I use
    import de.fayard.dependencies.DependenciesSetup
    ) but now I am stuck at
    DependenciesSetup.bootstrapRefreshVersionsAndDependencies(gradle.settings)
    which fails with "Cannot change the plugin resolution strategy after projects have been loaded." Most likely I painted myself into a corner here...
    l
    • 2
    • 8
  • m

    mbonnin

    06/06/2020, 1:38 PM
    Can you give more details? What is the error you're seeing?
    c
    l
    • 3
    • 6
  • l

    louiscad

    07/02/2020, 9:52 AM
    Hello dear users, I am considering adding config options to refreshVersions, and I'd like your thoughs/feedback on this draft proposal! https://github.com/jmfayard/refreshVersions/issues/202
    n
    • 2
    • 12
  • n

    Nikky

    07/02/2020, 1:15 PM
    another question i had, have you considered doing
    {key}
    for versions (eg:
    {react}
    ) or anything else that is not in maven versions usually that would then lead to a entry
    version.react=1.2.3
    that would probably not look for updates in maven i find that in kotlin-js-wrappers for example the versions are built out of the versio nand the library they are wrapping, would be cool to use
    "{react}-{js.wrappers}"
    as version or
    npm("react, "^{react}")
    l
    • 2
    • 5
  • n

    nkiesel

    07/11/2020, 1:33 AM
    refreshVersions
    uses
    dependencies
    internally to find the the available updates and uses that to re-write
    Versions.kt
    . So unless you want to just see available updates, stick with
    refreshVersions
    .
    l
    • 2
    • 1
  • n

    Nikky

    07/23/2020, 7:46 PM
    consistently across all projects i get a space before
    version.ktor=
    i wonder whats up with that
    z
    l
    • 3
    • 7
  • n

    Nikky

    07/27/2020, 2:53 PM
    tried fiddling with gradle and repository content blocks.. best i can get to work is let gradle tell me that it could resolve a ModuleIdentiefier (
    group:name
    ) on a repository.. true/false but only on repos that have one defined.. and i needed to repimplement some classes because even the most basic stuff is internal or package private in gradle technically i know which code is required to make listing work.. but its all inaccessible from outside
    l
    • 2
    • 11
  • n

    Nikky

    07/30/2020, 9:56 AM
    so.. which versions does refreshVerions need to check and display on comments? pretty much just the latest snapshot, release and such right? i am mentioning this because other gradle plugins seem to do this.. they add dependencies with
    version = "+"
    , resolve them and then compare versions at the very least this will always work
    l
    • 2
    • 2
  • n

    Nikky

    08/15/2020, 10:15 PM
    with 1.4.0 coming along a lot of projects have renamed and reshuffled their artifacts eg: coroutine got no runtime anymore just
    coroutine-core(-$platform)
    for some reason
    ktor.client.websockets
    is aliased to
    "$artifactPrefix-websockets-$native:_"
    even on the jvm ?
    "io.ktor:ktor-client-websockets:_"
    is what i would expect also for some reason refreshVersion did not suggest
    1.4.0
    for version.kotlin even though its available in the repos
    l
    • 2
    • 4
  • n

    Nikky

    08/19/2020, 9:17 AM
    can i somehow use refreshVersions inside
    buildSrc
    ? my usecase is that i need to apply jooq +postgres configurations for a lot of submodules, would be nice to have that done in buildSrc but for that i need the versions
    l
    • 2
    • 4
  • l

    louiscad

    08/20/2020, 12:27 PM
    Which syntax would you prefer for dependencies declaration? 1️⃣:
    AndroidX.emoji
    AndroidX.emoji.appCompat
    2️⃣:
    AndroidX.emoji
    AndroidX.emojiAppCompat
    Telling why your prefer on or another choice in this thread can help too 🙂 FYI, the solution number two is the current ont, but please, don't base your choice on what's there currently in refreshVersions.
    2️⃣ 3
    1️⃣ 3
    m
    n
    • 3
    • 20
  • n

    Nikky

    08/21/2020, 7:56 PM
    seems to fail for me when following the setup guide to upgrade: https://scans.gradle.com/s/xk4hbkhyzzalw/failure#1 seems like gradle / idea had the autoimport wrong and still had depednencies cached
    l
    • 2
    • 1
  • n

    Nikky

    08/21/2020, 9:02 PM
    the new version actually displays more new versions .. very nice
    l
    • 2
    • 1
  • h

    Harun

    08/22/2020, 7:17 AM
    Is there a way to declare refreshVersions usings plugins block and not adding buildscript block?
    l
    • 2
    • 8
  • n

    Nikky

    08/22/2020, 9:18 AM
    is it "safe" to have a composite build included in which i use the
    versions.properties
    file of the outer project?
    bootstrapRefreshVersions(
        listOf(rootDir.parentFile.resolve("buildSrc/dependencies-rules.txt").readText()),
        rootDir.parentFile.resolve("versions.properties")
    )
    l
    • 2
    • 10
  • n

    Nikky

    08/23/2020, 8:23 AM
    so when there is no errors then everything syncs fine:

    https://i.imgur.com/K54GoN5.png▾

    but if there is even one unrelated error then this happens in idea:

    https://i.imgur.com/KkS6SZe.png▾

    i assume that is because idea only then shows the "errors" generated when _ gets rejected is there any way to reduce the severity of those errors or get to the bottom of what the actual cause is ? the errors are also nonsensical:
    Cannot resolve external dependency io.ktor:ktor-client-core:{require 1.4.0; reject _} because no repositories are defined.
    Required by:
        project :util:paste:pastee
        project :util:paste:pastee > project :module:paste
    
    Possible solution:
     - Declare repository providing the artifact, see the documentation at <https://docs.gradle.org/current/userguide/declaring_repositories.html>
    l
    • 2
    • 8
  • n

    Nikky

    08/23/2020, 8:39 AM
    another thing i noticed.. sqldelight duplicates entries in the versions.properties file i have this in there:
    plugin.com.squareup.sqldelight=version.sqldelight
    
    ...
    
    version.sqldelight=1.5.0-SNAPSHOT
    after running the task it changes into
    plugin.com.squareup.sqldelight=1.5.0-SNAPSHOT
    
    plugin.com.squareup.sqldelight=version.sqldelight
    
    ...
    
    version.sqldelight=1.5.0-SNAPSHOT
    l
    • 2
    • 7
  • n

    Nikky

    08/23/2020, 4:23 PM
    btw.. whiy is this a thing and why is refreshVersions not doing it ?
    plugins {
        id("com.gradle.enterprise") version "3.4.1"
    }
    
    gradleEnterprise {
        buildScan {
            termsOfServiceUrl = "<https://gradle.com/terms-of-service>"
            termsOfServiceAgree = "yes"
        }
    }
    it seems like a cleaner way to configure.. than importing a function, i assume that plugins there do not provide the same access ?
    l
    j
    • 3
    • 4
  • n

    Nikky

    08/30/2020, 11:22 AM
    weird issue caused by refreshVersions: https://scans.gradle.com/s/k4cml4unkop5w/failure#1 but only on github actions, cannot reproduce that locally the project is also quite weird so its possible there is some weirdness going on but since its small enough and does not need updates often i removed refreshVersions
    j
    • 2
    • 3
  • j

    jmfayard

    10/15/2020, 3:31 PM
    Hello friends gradle refreshVersions has a new website! I put lots of efforts in it and would appreciate some feedback https://jmfayard.github.io/refreshVersions/
    🙌 3
    z
    m
    • 3
    • 3
  • n

    Nikky

    10/26/2020, 7:47 PM
    refreshVersions might not work out of the box with maven on
    gcs://
    urls (google cloud storage)
    l
    • 2
    • 27
  • n

    Nikky

    11/10/2020, 4:11 PM
    trying to use the gcs thing via jitpack.. on androidStudio it does not work at all.. a different dependency seems to help but then it runs into the issue of not recognizing version in a non android project i tried it and it seems to wrk.. but this error gets thrown:
    org.gradle.api.tasks.TaskExecutionException: Execution failed for task ':refreshVersions'.
    Caused by: java.lang.IllegalArgumentException: Cannot get version candidates with an empty fetchers list.
    l
    • 2
    • 8
  • n

    Nikky

    11/10/2020, 5:14 PM
    do i HAVE to use
    dependencies {
        classpath("com.android.tools.build:gradle:_")
        classpath("org.jetbrains.kotlin:kotlin-gradle-plugin:_")
      }
    instead of
    plugins {
        id("com.android.application")
        id("com.android.library")
    }
    with pluginManagement ? is that already a known issue ?
    l
    • 2
    • 1
  • n

    Nikky

    11/10/2020, 7:37 PM
    yeah there migth be a small issue with gcs support.. and that is.. it might override versions of guava and other google libs that then fail at runtime when loading the plugin i have this error
    Caused by: java.lang.NoSuchMethodError: com.google.common.collect.ImmutableList.toImmutableList()Ljava/util/stream/Collector;
    	at com.android.build.gradle.internal.TaskManager.<init>(TaskManager.java:371)
    not sure if thats the cause.. or not but it is weird
    l
    • 2
    • 7
  • n

    Nikky

    11/11/2020, 12:37 PM
    any workarounds for https://github.com/jmfayard/refreshVersions/issues/265 know btw ?
    l
    • 2
    • 1
Powered by Linen
Title
n

Nikky

11/11/2020, 12:37 PM
any workarounds for https://github.com/jmfayard/refreshVersions/issues/265 know btw ?
l

louiscad

11/11/2020, 12:53 PM
Not yet, I didn't have the time to dive into that one yet. BTW, there's no need to communicate into both this channel and the issues for the exact same issue, I'm watching both and I don't need to be asked the roughly the same question twice 😉 Asking for workarounds in issues is best since everyone can see it at the right place if needed.
View count: 4