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

fix: incorrect number of operationstartedcalls #3452

Merged
merged 1 commit into from
Jan 2, 2025
Merged

Conversation

iancooper
Copy link
Member

fix:

-incorrect number of operationstartedcalls
-make implementation closer to AsyncEx closer for error trapping

@iancooper iancooper added 3 - Done Bug v10 Allocal to a v10 release .NET Pull requests that update .net code labels Jan 2, 2025
@iancooper iancooper self-assigned this Jan 2, 2025
@iancooper iancooper merged commit 32c0605 into master Jan 2, 2025
4 of 6 checks passed
@iancooper iancooper deleted the scheduler_fixes branch January 2, 2025 15:14
Copy link

@codescene-delta-analysis codescene-delta-analysis bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Health Quality Gates: OK

Change in average Code Health of affected files: +0.03 (9.19 -> 9.22)

  • Declining Code Health: 1 findings(s) 🚩
  • Improving Code Health: 1 findings(s) ✅

View detailed results in CodeScene

Comment on lines +100 to +102
if (_disposed)
throw new ObjectDisposedException(nameof(BrighterSynchronizationContext));

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

❌ New issue: Code Duplication
The module contains 2 functions with similar structure: OperationCompleted,OperationStarted

Suppress

@@ -20,15 +20,15 @@ public class BrighterSynchronizationContextsTests
public void AsyncContext_StaysOnSameThread()
{
var testThread = Thread.CurrentThread.ManagedThreadId;
var contextThread = BrighterSynchronizationHelper.Run(() => Thread.CurrentThread.ManagedThreadId);
var contextThread = BrighterAsyncContext.Run(() => Thread.CurrentThread.ManagedThreadId);

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

✅ Getting better: Code Duplication
reduced similar code in: Current_FromBrighterSynchronizationHelper_IsBrighterSynchronizationHelper,SynchronizationContextCurrent_FromBrighterSynchronizationHelper_IsBrighterSynchronizationHelperSynchronizationContext

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
3 - Done Bug .NET Pull requests that update .net code v10 Allocal to a v10 release
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant