This message was deleted.
# configuration-cache
s
This message was deleted.
e
Hey, @Jakub Chrzanowski! I think what you have or some variation of it makes sense. 1. Cacheable
createFooFile
2. Non-cacheable
printFooFile
that depends on
createFooFile
j
Is the following still a valid way for making task non-cacheable?
Copy code
outputs.upToDateWhen { false }
e
So, that will disable incremental building (up-to-date checks) for the task which is different from build caching. You may want to read the docs on incremental building vs build caching.
For your
print
task you should not have to explicitly disable build caching or incremental building. The
print
task should not have an output defined and those features will be disabled by default.
party gradlephant 1
v
And otherwise, it would be
@UntrackedTask
or
doNotTrackState()
🙂 Btw. your question should probably have gone to #CA83B1VLL, as it has nothing to do with configuration cache. 😉
👍 2
thank you 1
j
Oh my, it should go to #CA83B1VLL indeed, my bad!
Thank you for all details, folks! I'll get through these pages too. Extending a bit my question – as we have
runIde
task which runs guest IDE instance, and that's something should be invoked everytime, it should be annotated with
@UntrackedTask
right?
e
@UntrackedTask
is a newer annotation but I believe that is a valid use case. See the JavaDoc.
j
Since 7.3 - so I still have to wait a bit. We're supporting 7.1+ now
v
Do you have inputs and outputs for
runIde
task? If you have neither,
@UntrackedTask
will just be a noop, as there is nothing to track anyway.
You can attach it to be explicit, but it wouldn't change anything
j
It takes inputs, but produces nothing.
v
Yeah, then I'd add the annotation once you are on recent enough version, or do the runtime-api call depending on the current Gradle version, so that the inputs do not even need to be fingerprinted. But for always rerunning not having any output defined would already be sufficient.