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

Avoid implicit task dependencies for grpc generated tasks #2442

Merged
merged 1 commit into from
Nov 23, 2022

Conversation

Scottmitch
Copy link
Member

Motivation:
The protobuf gradle plugin will generate tasks dynamically, which have implicit relationships on our dynamically generated quality tasks (pmd, spotbugs, checkstyle). Gradle build generates warnings and deoptimizes some flows.

Execution optimizations have been disabled for task ':servicetalk-grpc-health:pmdMain' to ensure correctness due to the following reasons:
  - Gradle detected a problem with the following location: '/Users/scottmitchell/git/servicetalk/servicetalk-grpc-health/src/generated'. Reason: Task ':servicetalk-grpc-health:pmdMain' uses this output of task ':servicetalk-grpc-health:generateTestProto' without declaring an explicit or implicit dependency. This can lead to incorrect results being produced, depending on what order the tasks are executed. Please refer to https://docs.gradle.org/7.6-rc-3/userguide/validation_problems.html#implicit_dependency for more details about this problem.

Motivation:
The protobuf gradle plugin will generate tasks dynamically, which have
implicit relationships on our dynamically generated quality tasks (pmd, spotbugs, checkstyle).
Gradle build generates warnings and deoptimizes some flows.

```
Execution optimizations have been disabled for task ':servicetalk-grpc-health:pmdMain' to ensure correctness due to the following reasons:
  - Gradle detected a problem with the following location: '/Users/scottmitchell/git/servicetalk/servicetalk-grpc-health/src/generated'. Reason: Task ':servicetalk-grpc-health:pmdMain' uses this output of task ':servicetalk-grpc-health:generateTestProto' without declaring an explicit or implicit dependency. This can lead to incorrect results being produced, depending on what order the tasks are executed. Please refer to https://docs.gradle.org/7.6-rc-3/userguide/validation_problems.html#implicit_dependency for more details about this problem.
```
@Scottmitch
Copy link
Member Author

test failure attributed to #2378

@Scottmitch Scottmitch merged commit 07255b0 into apple:main Nov 23, 2022
@Scottmitch Scottmitch deleted the gradle_grpc_generated_deps branch November 23, 2022 23:53
idelpivnitskiy added a commit to idelpivnitskiy/servicetalk that referenced this pull request Nov 28, 2022
idelpivnitskiy added a commit to idelpivnitskiy/servicetalk that referenced this pull request Nov 29, 2022
idelpivnitskiy added a commit that referenced this pull request Nov 29, 2022
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 this pull request may close these issues.

1 participant