NativeScript / NativeScript/android
Gradle clean task executes not needed steps
Nobody has claimed this yet.
- Dominant language
- C++
- Stars
- 563
- Forks
- 144
- Avg merge
- 10h 46m
- Merged PRs (30d)
- 14
Description
Environment
- CLI: 5.3.2
- Cross-platform modules:
- Android Runtime: 5.3.1
- iOS Runtime (if applicable):
- Plugin(s):
Describe the bug
Gradle clean...
+ setting applicationId
+ applying user-defined configuration from /Users/myUser/Work/nativescript-cli/scratch/buildProject/app/App_Resources/Android/app.gradle
+ using support library version 28.0.0
+ adding nativescript runtime package dependency: nativescript-optimized-with-inspector
+ adding aar plugin dependency: /Users/myUser/Work/nativescript-cli/scratch/buildProject/node_modules/tns-core-modules-widgets/platforms/android/widgets-release.aar
Gradle build...
+ setting applicationId
+ applying user-defined configuration from /Users/myUser/Work/nativescript-cli/scratch/buildProject/app/App_Resources/Android/app.gradle
+ using support library version 28.0.0
+ adding nativescript runtime package dependency: nativescript-optimized-with-inspector
+ adding aar plugin dependency: /Users/myUser/Work/nativescript-cli/scratch/buildProject/node_modules/tns-core-modules-widgets/platforms/android/widgets-release.aar
As you can see from the above log, the output from Gradle clean... and Gradle build... is the same. Most probably we don't need to execute build task's logic when cleaning the project.
To Reproduce
tns build android --bundle --clean
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reproducing tns build android --bundle --clean and compare the logged steps for the clean and build phases. Trace the clean-task entry point and determine why build-task logic runs during cleaning; done means clean no longer performs unnecessary build steps while the normal build output remains unchanged.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- android
- Domain
- build-system, mobile-dev
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100