Skip to content

Commit a363e79

Browse files
authored
Fix RefCount bugs (#2216)
* Fix crash when eager RefCount crosses min observer threshold more than once * Make RefCount tests more comprehensive * Fix RefCount with delayedDisconnect InvalidOperationException bugs Also fixed some build issues: * Fix missing TargetPlatformSdkPath (because an SDK change broke the build) * Bump version since we already released 6.0.1 * Update integration tests to use Rx 6.0.2 preview * Add release notes for 6.0.2
1 parent de5749f commit a363e79

File tree

11 files changed

+2113
-310
lines changed

11 files changed

+2113
-310
lines changed

Rx.NET/Documentation/ReleaseHistory/Rx.v6.md

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,15 @@
11
# Rx Release History v6.0
22

3+
## v6.0.2
4+
5+
This release fixes:
6+
7+
* [Issue #2173: "RefCount with MinObservers > 1 Behaves Unexpectedly"](https://github.com/dotnet/reactive/issues/2173)
8+
* [Issue #2214: "RefCount with disconnect delay and minObservers throws InvalidOperationException when resubscribing to synchronously completing source"](https://github.com/dotnet/reactive/issues/2214)
9+
* [Issue #2215: "RefCount with disconnect delay and minObservers disconnects prematurely if observer count drops to zero and then goes back up"](https://github.com/dotnet/reactive/issues/2215)
10+
11+
Note: the test suite now tests on .NET 9.0. No changes were required as a result of this.
12+
313
## v6.0.1
414

515
This release fixes:

Rx.NET/Integration/LinuxTests/LinuxTests.csproj

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<Project Sdk="Microsoft.NET.Sdk">
22
<PropertyGroup>
3-
<TargetFrameworks>net6.0;net7.0;net8.0</TargetFrameworks>
3+
<TargetFrameworks>net8.0;net9.0</TargetFrameworks>
44
<NoWarn>$(NoWarn);CS0618</NoWarn>
55
<LangVersion>latest</LangVersion>
66
<AssemblyName>Tests.System.Reactive</AssemblyName>
@@ -12,7 +12,7 @@
1212
<PropertyGroup Condition="'$(TargetFramework)' == 'netstandard2.0'">
1313
<DefineConstants>$(DefineConstants);</DefineConstants>
1414
</PropertyGroup>
15-
<PropertyGroup Condition="'$(TargetFramework)' == 'net6.0' or '$(TargetFramework)' == 'net7.0' or '$(TargetFramework)' == 'net8.0'">
15+
<PropertyGroup Condition="'$(TargetFramework)' == 'net8.0' or '$(TargetFramework)' == 'net9.0'">
1616
<DefineConstants>$(DefineConstants);LINUX</DefineConstants>
1717
</PropertyGroup>
1818

@@ -28,8 +28,8 @@
2828
<PackageReference Include="MSTest.TestAdapter" Version="3.0.2" />
2929
<PackageReference Include="MSTest.TestFramework" Version="3.0.2" />
3030
<PackageReference Include="xunit.assert" Version="2.4.2" />
31-
<PackageReference Include="System.Reactive" Version="6.0.0-preview*" />
32-
<PackageReference Include="Microsoft.Reactive.Testing" Version="6.0.0-preview*" />
33-
<PackageReference Include="System.Reactive.Observable.Aliases" Version="6.0.0-preview*" />
31+
<PackageReference Include="System.Reactive" Version="6.0.2-preview*" />
32+
<PackageReference Include="Microsoft.Reactive.Testing" Version="6.0.2-preview*" />
33+
<PackageReference Include="System.Reactive.Observable.Aliases" Version="6.0.2-preview*" />
3434
</ItemGroup>
3535
</Project>

Rx.NET/Integration/WindowsDesktopTests/WindowsDesktopTests.csproj

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<Project Sdk="Microsoft.NET.Sdk">
22
<PropertyGroup>
3-
<TargetFrameworks>net6.0;net6.0-windows10.0.19041;net7.0;net7.0-windows10.0.19041;net8.0;net8.0-windows10.0.19041</TargetFrameworks>
3+
<TargetFrameworks>net8.0;net8.0-windows10.0.19041;net9.0;net9.0-windows10.0.19041</TargetFrameworks>
44
<NoWarn>$(NoWarn);CS0618</NoWarn>
55
<LangVersion>latest</LangVersion>
66
<AssemblyName>Tests.System.Reactive</AssemblyName>
@@ -9,7 +9,7 @@
99
<AssemblyOriginatorKeyFile>..\..\Source\ReactiveX.snk</AssemblyOriginatorKeyFile>
1010
</PropertyGroup>
1111

12-
<PropertyGroup Condition="$(TargetFramework.StartsWith('net6.0-windows')) or $(TargetFramework.StartsWith('net7.0-windows')) or $(TargetFramework.StartsWith('net8.0-windows'))">
12+
<PropertyGroup Condition="$(TargetFramework.StartsWith('net8.0-windows')) or $(TargetFramework.StartsWith('net9.0-windows'))">
1313
<UseWPF>true</UseWPF>
1414
<UseWindowsForms>true</UseWindowsForms>
1515
<DefineConstants>$(DefineConstants);HAS_TRACE;HAS_WINRT;PREFER_ASYNC;HAS_TPL46;NO_REMOTING;HAS_WINFORMS;HAS_WPF;HAS_DISPATCHER;DESKTOPCLR;WINDOWS;CSWINRT</DefineConstants>
@@ -27,8 +27,8 @@
2727
<PackageReference Include="MSTest.TestAdapter" Version="3.0.2" />
2828
<PackageReference Include="MSTest.TestFramework" Version="3.0.2" />
2929
<PackageReference Include="xunit.assert" Version="2.4.2" />
30-
<PackageReference Include="System.Reactive" Version="6.0.0-preview*" />
31-
<PackageReference Include="Microsoft.Reactive.Testing" Version="6.0.0-preview*" />
32-
<PackageReference Include="System.Reactive.Observable.Aliases" Version="6.0.0-preview*" />
30+
<PackageReference Include="System.Reactive" Version="6.0.2-preview*" />
31+
<PackageReference Include="Microsoft.Reactive.Testing" Version="6.0.2-preview*" />
32+
<PackageReference Include="System.Reactive.Observable.Aliases" Version="6.0.2-preview*" />
3333
</ItemGroup>
3434
</Project>

Rx.NET/Integration/global.json

Lines changed: 0 additions & 5 deletions
This file was deleted.

Rx.NET/Source/Directory.build.props

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -70,6 +70,9 @@
7070

7171
<DefineConstants>$(DefineConstants);WINDOWS_UWP</DefineConstants>
7272

73+
<!-- At some point, it looks like a fully-qualified version number stopped resolving the TargetPlatformSdkPath
74+
and now it only works with 10.0, so the SDK no longer sets this for us in UAP targets. -->
75+
<TargetPlatformSdkPath Condition="'$(TargetPlatformSdkPath)' == ''">$([Microsoft.Build.Utilities.ToolLocationHelper]::GetPlatformSDKLocation('Windows', '10.0'))</TargetPlatformSdkPath>
7376
</PropertyGroup>
7477

7578

0 commit comments

Comments
 (0)