Conversation
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
cli.StatusReaderConsoleAdaptercli.StatusReaderConsoleAdapter and fix race condition with status.progress
|
Test coverage of 11be640: 94% |
Contributor
There was a problem hiding this comment.
Pull Request Overview
This PR enhances the CLI status reader by reporting errors on processing status files, initializing and resetting a start‐time marker to fix a race condition in progress updates, and adds new tests to cover blocking and delayed‐start scenarios.
- Report the filepath when
full_formatencounters an exception. - Introduce and manage
_progress_t0to ensure ETA calculations don’t race. - Rename test helper, and add
test_blockingandtest_delayedtests for progress behavior.
Reviewed Changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated 3 comments.
| File | Description |
|---|---|
| tests/testsuite.py | Rename CaptureStdout to CaptureOutput and add CaptureStdout subclass using create_redirect. |
| tests/test_cli.py | Guard in asyncTearDown, plus new test_blocking and test_delayed cases for progress output. |
| repype/cli.py | Add _progress_t0 field, catch exceptions in full_format, and refine progress timing/reset logic. |
Comments suppressed due to low confidence (1)
tests/test_cli.py:197
- The
test_delayedmethod has no assertions after exercising the progress reader; add an explicitassertEqualor similar to verify the captured output matches expectations.
async def test_delayed(self):
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
cli.StatusReaderConsoleAdaptercli.StatusReaderConsoleAdapterthat occurred when usingstatus.progress