CCExtractor / CCExtractor/sample-platform

[BUG] Completed and canceled progress states are not treated as terminal

Open
#1,194 1 comment 0 reactions 0 assignees View on GitHub
Dominant language
Python
Stars
30
Forks
85
Avg merge
6d 21h
Merged PRs (30d)
12

Description

## Description
`progress_type_request` does not correctly reject progress updates after a test has reached `completed` or `canceled`.

`TestStatus.progress_step()` returns an integer progress index, but the returned integer was compared directly against `TestStatus.completed` and `TestStatus.canceled` enum symbols.

As a result, terminal states could be incorrectly treated as active progress states.

## Expected behavior
If the latest progress status is `completed` or `canceled`, a subsequent progress update should be rejected and the progress trail should remain unchanged.

## Actual behavior
The terminal-state guard was bypassed, allowing additional progress entries after `completed` or `canceled`.

## Reproduction
Regression tests demonstrate that:
- completed -> completed was accepted
- canceled -> completed was accepted

## Fix
Compare the stored `TestStatus` enum directly against the terminal enum values, while retaining `progress_step()` for numeric progress ordering.

## Tests
Regression tests cover both `completed` and `canceled` terminal states.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.