Skip to content

Commit f4bffbb

Browse files
warning fixes, namespace and polyfill cleanup
1 parent 72c8a71 commit f4bffbb

File tree

67 files changed

+711
-143
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

67 files changed

+711
-143
lines changed

src/CoreIpc.sln

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "UiPath.CoreIpc", "UiPath.Co
77
EndProject
88
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution Items", "Solution Items", "{676A208A-2F08-4749-A833-F8D2BCB1B147}"
99
ProjectSection(SolutionItems) = preProject
10+
Directory.Build.props = Directory.Build.props
1011
Directory.Build.targets = Directory.Build.targets
1112
IpcSample.ConsoleServer\IpcSample.ConsoleServer.csproj = IpcSample.ConsoleServer\IpcSample.ConsoleServer.csproj
1213
..\NuGet.Config = ..\NuGet.Config

src/Directory.Build.props

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
<Project>
2+
<PropertyGroup>
3+
<SuppressTfmSupportBuildWarnings>true</SuppressTfmSupportBuildWarnings>
4+
</PropertyGroup>
5+
</Project>

src/IpcSample.ConsoleClient/Client.cs

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,13 @@
11
using Microsoft.Extensions.DependencyInjection;
22
using System.Diagnostics;
33
using System.Text;
4-
using UiPath.Ipc;
54
using UiPath.Ipc.Transport.NamedPipe;
65

7-
namespace UiPath.CoreIpc.Tests;
6+
namespace UiPath.Ipc.Tests;
87

9-
class Client
8+
internal static class Client
109
{
11-
static async Task Main(string[] args)
10+
public static async Task Main(string[] args)
1211
{
1312
Console.WriteLine(typeof(int).Assembly);
1413
Trace.Listeners.Add(new TextWriterTraceListener(Console.Out));

src/IpcSample.ConsoleClient/IpcSample.ConsoleClient.csproj

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -19,9 +19,5 @@
1919
<PackageReference Include="Microsoft.Extensions.Configuration.Json" Version="8.0.0" />
2020
<PackageReference Include="Microsoft.Extensions.DependencyInjection" Version="8.0.0" />
2121
<PackageReference Include="Microsoft.Extensions.Logging.Console" Version="8.0.0" />
22-
<PackageReference Include="Polyfill" Version="5.5.3">
23-
<PrivateAssets>all</PrivateAssets>
24-
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
25-
</PackageReference>
2622
</ItemGroup>
2723
</Project>

src/IpcSample.ConsoleClient/TcpClient.cs

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -2,15 +2,15 @@
22
using System.Diagnostics;
33
using Microsoft.Extensions.DependencyInjection;
44
using System.Net;
5-
using UiPath.Ipc;
65
using UiPath.Ipc.Transport.Tcp;
76

8-
namespace UiPath.CoreIpc.Tests;
7+
namespace UiPath.Ipc.Tests;
98

10-
class TcpClient
9+
internal static class TcpClient
1110
{
12-
static readonly IPEndPoint SystemEndPoint = new(IPAddress.Loopback, 3131);
13-
static async Task _Main(string[] args)
11+
private static readonly IPEndPoint SystemEndPoint = new(IPAddress.Loopback, 3131);
12+
13+
public static async Task _Main(string[] args)
1414
{
1515
Console.WriteLine(typeof(int).Assembly);
1616
Trace.Listeners.Add(new TextWriterTraceListener(Console.Out));
@@ -118,8 +118,8 @@ private static async Task RunTestsAsync(CancellationToken cancellationToken)
118118
callbackProxy.Dispose();
119119
callbackProxy.Dispose();
120120
//((IpcProxy)callbackProxy).CloseConnection();
121-
((IpcProxy)computingClient).CloseConnection();
122-
((IpcProxy)systemClient).CloseConnection();
121+
await ((IpcProxy)computingClient).CloseConnection();
122+
await ((IpcProxy)systemClient).CloseConnection();
123123
}
124124
finally
125125
{

src/IpcSample.ConsoleClient/WebSocketClient.cs

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,13 @@
11
using Microsoft.Extensions.DependencyInjection;
22
using System.Diagnostics;
33
using System.Text;
4-
using UiPath.Ipc;
54
using UiPath.Ipc.Transport.WebSocket;
65

7-
namespace UiPath.CoreIpc.Tests;
6+
namespace UiPath.Ipc.Tests;
87

9-
class WebSocketClient
8+
internal static class WebSocketClient
109
{
11-
static async Task _Main(string[] args)
10+
public static async Task _Main(string[] args)
1211
{
1312
Console.WriteLine(typeof(int).Assembly);
1413
Trace.Listeners.Add(new TextWriterTraceListener(Console.Out));

src/IpcSample.ConsoleServer/IpcSample.ConsoleServer.csproj

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@
66
<ApplicationManifest>app1.manifest</ApplicationManifest>
77
<LangVersion>latest</LangVersion>
88
<ImplicitUsings>true</ImplicitUsings>
9+
<Nullable>enable</Nullable>
910
</PropertyGroup>
1011

1112
<ItemGroup>

src/IpcSample.ConsoleServer/Server.cs

Lines changed: 3 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,20 +1,12 @@
11
using Microsoft.Extensions.DependencyInjection;
22
using System.Diagnostics;
3-
using UiPath.Ipc;
43
using UiPath.Ipc.Transport.NamedPipe;
54

6-
namespace UiPath.CoreIpc.Tests;
5+
namespace UiPath.Ipc.Tests;
76

8-
class Server
7+
internal static class Server
98
{
10-
//private static readonly Timer _timer = new Timer(_ =>
11-
//{
12-
// Console.WriteLine("GC.Collect");
13-
// GC.Collect();
14-
// GC.WaitForPendingFinalizers();
15-
// GC.Collect();
16-
//}, null, 0, 3000);
17-
static async Task Main()
9+
public static async Task Main()
1810
{
1911
Trace.Listeners.Add(new TextWriterTraceListener(Console.Out));
2012
//GuiLikeSyncContext.Install();

src/IpcSample.ConsoleServer/TcpServer.cs

Lines changed: 4 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,25 +1,17 @@
11
using Microsoft.Extensions.DependencyInjection;
22
using System.Diagnostics;
3-
using UiPath.Ipc;
43
using UiPath.Ipc.Transport.Tcp;
54

6-
namespace UiPath.CoreIpc.Tests;
5+
namespace UiPath.Ipc.Tests;
76

87
using IPEndPoint = System.Net.IPEndPoint;
98
using IPAddress = System.Net.IPAddress;
109

11-
class TcpServer
10+
internal static class TcpServer
1211
{
13-
static readonly IPEndPoint SystemEndPoint = new(IPAddress.Any, 3131);
14-
//private static readonly Timer _timer = new Timer(_ =>
15-
//{
16-
// Console.WriteLine("GC.Collect");
17-
// GC.Collect();
18-
// GC.WaitForPendingFinalizers();
19-
// GC.Collect();
20-
//}, null, 0, 3000);
12+
private static readonly IPEndPoint SystemEndPoint = new(IPAddress.Any, 3131);
2113

22-
static async Task _Main()
14+
public static async Task _Main()
2315
{
2416
Trace.Listeners.Add(new TextWriterTraceListener(Console.Out));
2517
//GuiLikeSyncContext.Install();

src/IpcSample.ConsoleServer/WebSocketServer.cs

Lines changed: 2 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,10 @@
11
using Microsoft.Extensions.DependencyInjection;
22
using System.Diagnostics;
3-
using UiPath.Ipc;
43
using UiPath.Ipc.Transport.WebSocket;
5-
namespace UiPath.CoreIpc.Tests;
4+
namespace UiPath.Ipc.Tests;
65
class WebSocketServer
76
{
8-
//private static readonly Timer _timer = new Timer(_ =>
9-
//{
10-
// Console.WriteLine("GC.Collect");
11-
// GC.Collect();
12-
// GC.WaitForPendingFinalizers();
13-
// GC.Collect();
14-
//}, null, 0, 3000);
15-
16-
static async Task _Main()
7+
public static async Task _Main()
178
{
189
Trace.Listeners.Add(new TextWriterTraceListener(Console.Out));
1910
//GuiLikeSyncContext.Install();

0 commit comments

Comments
 (0)