CancellationSpec.groovy

Clone Tools
  • last updated a few seconds ago
Constraints
Constraints: committers
 
Constraints: files
Constraints: dates
Fix more TAPI cancellation flakiness (#9562)

### Context

This is a leftover of https://github.com/gradle/gradle-private/issues/1760

Depending on the point when cancellation happens, the error message can be:

- Build cancelled

- Daemon was stopped to handle build cancel request

In previous fix we neglected one place. This PR fixes it.

Fix more TAPI cancellation flakiness

Fix more TAPI cancellation flakiness

Fix more TAPI cancellation flakiness

Adjust test assertions to fix flakiness (#8979)

This fixes https://github.com/gradle/gradle-private/issues/1760

The changes we made to TAPI in https://github.com/gradle/gradle/pull/7654 caused some flakiness.

This PR fixes these flakiness by adjusting test assertions.

Use assertions based on Gradle version

Use assertions based on Gradle version

Adjust test assertions to fix flakiness

This fixes https://github.com/gradle/gradle-private/issues/1760

The changes we made to TAPI in https://github.com/gradle/gradle/pull/7654 caused some flakiness.

This PR fixes these flakiness by adjusting test assertions.

Adjust test assertions to fix flakiness

This fixes https://github.com/gradle/gradle-private/issues/1760

The changes we made to TAPI in https://github.com/gradle/gradle/pull/7654 caused some flakiness.

This PR fixes these flakiness by adjusting test assertions.

Do not include an additional 'build cancelled' exception in the build result when there are some task failures to report.

Previously, this was sometimes happening and sometimes not, depending on whether the worker thread that ran the failed task happened to clean up the queued tasks based on the failure before some other work thread happened to see the cancellation. Now, if a task happens to fail due to cancellation, the result the same as is as if the had of failed in any other way.

Also clean up the tapi tests to deal with the fact that this is not fixed in older Gradle versions.

  1. … 5 more files in changeset.
Add some context to the exception thrown by the TAPI when the daemon is force killed on cancellation.

Remove some consumer side assumptions about the implementation of the producer, which were present as a work around to produce the correct exception in the consumer when the daemon is force killed by the producer and for very old producer versions.

  1. … 11 more files in changeset.
Fixes for tapi cancellation test coverage

  1. … 8 more files in changeset.
Fix TAPI exception handling when a build is cancelled while running a test execution request or a phased build action.

    • -0
    • +108
    ./CancellationSpec.groovy
  1. … 7 more files in changeset.