Remove NRE workaround and implement progress completion via event handlers#94
Open
kborowinski wants to merge 1 commit intothoemmi:masterfrom
Open
Remove NRE workaround and implement progress completion via event handlers#94kborowinski wants to merge 1 commit intothoemmi:masterfrom
kborowinski wants to merge 1 commit intothoemmi:masterfrom
Conversation
Contributor
There was a problem hiding this comment.
PR Overview
This PR removes the NullReferenceException workaround and implements progress completion via event handlers for both extraction and compression operations.
- Added ExtractionFinished and CompressionFinished event handlers to update and complete the progress bar
- Removed the try-catch block in ThreadedCmdlet.cs that handled the obsolete workaround for NREs
Reviewed Changes
| File | Description |
|---|---|
| 7Zip4Powershell/Expand7Zip.cs | Added ExtractionFinished event handler to mark extraction progress as complete. |
| 7Zip4Powershell/Compress7Zip.cs | Added CompressionFinished event handler to mark compression progress as complete. |
| 7Zip4Powershell/ThreadedCmdlet.cs | Removed obsolete try-catch block for NullReferenceException workaround. |
Copilot reviewed 3 out of 3 changed files in this pull request and generated no comments.
Contributor
Author
Owner
|
@kborowinski that's why I have not merged it yet ;) |
Contributor
Author
|
@thoemmi The PR got merged on 7.6 branch but unfortunately will not be backported to 7.5 and 7.4. Since 7.6 will be LTS you might consider to merge this PR on 7.6 GA |
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.
@thoemmi
ExtractionFinishedandCompressionFinishedevent handlers to properly complete the progress bar instanceNullReferenceExceptions. The PR introduces additional locking mechanisms to prevent such occurrences and ensure thread-safe console access.