This commit is contained in:
parent
9033151006
commit
dd97d5ec4e
9 changed files with 19 additions and 34 deletions
|
@ -1,8 +1,7 @@
|
||||||
using System;
|
using System;
|
||||||
using System.Threading.Tasks;
|
using System.Threading.Tasks;
|
||||||
using System.Threading.Channels;
|
using System.Threading.Channels;
|
||||||
using Exceptionless;
|
|
||||||
using Exceptionless.Models;
|
|
||||||
|
|
||||||
namespace Sledgemapper
|
namespace Sledgemapper
|
||||||
{
|
{
|
||||||
|
@ -29,7 +28,7 @@ namespace Sledgemapper
|
||||||
}
|
}
|
||||||
catch (Exception ex)
|
catch (Exception ex)
|
||||||
{
|
{
|
||||||
ExceptionlessClient.Default.SubmitException(ex);
|
//ExceptionlessClient.Default.SubmitException(ex);
|
||||||
throw;
|
throw;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,5 +1,4 @@
|
||||||
using System;
|
using System;
|
||||||
using Exceptionless;
|
|
||||||
|
|
||||||
namespace Sledgemapper
|
namespace Sledgemapper
|
||||||
{
|
{
|
||||||
|
@ -8,14 +7,8 @@ namespace Sledgemapper
|
||||||
[STAThread]
|
[STAThread]
|
||||||
static void Main()
|
static void Main()
|
||||||
{
|
{
|
||||||
ExceptionlessClient.Default.Configuration.ServerUrl = "https://exceptionless.michelescandura.com";
|
|
||||||
|
using(Sentry.SentrySdk.Init("https://973ac1606651454ba7a19f642d0a9bc1@glitchtip.michelescandura.com/1"))
|
||||||
#if DEBUG
|
|
||||||
ExceptionlessClient.Default.Startup("Qvdn6odZRJyGNnorjayMkiwjVsnAK3rNkFtn9bvL");
|
|
||||||
#else
|
|
||||||
ExceptionlessClient.Default.Startup("uprV1LocxAlUPPC9oB4eOlt8jGZ5WypMZKdJCsdL");
|
|
||||||
#endif
|
|
||||||
|
|
||||||
using (var game = new Sledgemapper())
|
using (var game = new Sledgemapper())
|
||||||
game.Run();
|
game.Run();
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,5 +1,4 @@
|
||||||
using System;
|
using System;
|
||||||
using Exceptionless;
|
|
||||||
using Microsoft.Xna.Framework;
|
using Microsoft.Xna.Framework;
|
||||||
|
|
||||||
namespace Sledgemapper
|
namespace Sledgemapper
|
||||||
|
@ -28,7 +27,7 @@ namespace Sledgemapper
|
||||||
}
|
}
|
||||||
catch (Exception ex)
|
catch (Exception ex)
|
||||||
{
|
{
|
||||||
ExceptionlessClient.Default.SubmitException(ex);
|
//ExceptionlessClient.Default.SubmitException(ex);
|
||||||
MachineName = "n/a";
|
MachineName = "n/a";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,5 +1,3 @@
|
||||||
using Exceptionless;
|
|
||||||
using Exceptionless.Models;
|
|
||||||
using Microsoft.AspNetCore.SignalR.Client;
|
using Microsoft.AspNetCore.SignalR.Client;
|
||||||
using Microsoft.Xna.Framework;
|
using Microsoft.Xna.Framework;
|
||||||
using Microsoft.Xna.Framework.Graphics;
|
using Microsoft.Xna.Framework.Graphics;
|
||||||
|
@ -75,27 +73,27 @@ namespace Sledgemapper
|
||||||
|
|
||||||
private async Task OnHubDisconnected(Exception arg)
|
private async Task OnHubDisconnected(Exception arg)
|
||||||
{
|
{
|
||||||
ExceptionlessClient.Default.SubmitEvent(new Event { Message = "Hub disconnected", Type = "SignalR Client Events", Source = _settings.MachineName });
|
// ExceptionlessClient.Default.SubmitEvent(new Event { Message = "Hub disconnected", Type = "SignalR Client Events", Source = _settings.MachineName });
|
||||||
_mainWidget.lblConnectionStatus.Text = "Disconnected";
|
_mainWidget.lblConnectionStatus.Text = "Disconnected";
|
||||||
await Task.Yield();
|
await Task.Yield();
|
||||||
}
|
}
|
||||||
|
|
||||||
private async Task OnHubReconnecting(Exception arg)
|
private async Task OnHubReconnecting(Exception arg)
|
||||||
{
|
{
|
||||||
ExceptionlessClient.Default.SubmitEvent(new Event { Message = "Reconnecting Hub", Type = "SignalR Client Events", Source = _settings.MachineName });
|
// ExceptionlessClient.Default.SubmitEvent(new Event { Message = "Reconnecting Hub", Type = "SignalR Client Events", Source = _settings.MachineName });
|
||||||
_mainWidget.lblConnectionStatus.Text = "Reconnecting";
|
_mainWidget.lblConnectionStatus.Text = "Reconnecting";
|
||||||
await Task.Yield();
|
await Task.Yield();
|
||||||
}
|
}
|
||||||
private async Task OnHubReconnected(string arg)
|
private async Task OnHubReconnected(string arg)
|
||||||
{
|
{
|
||||||
ExceptionlessClient.Default.SubmitEvent(new Event { Message = "Hub reconnected", Type = "SignalR Client Events", Source = _settings.MachineName });
|
// ExceptionlessClient.Default.SubmitEvent(new Event { Message = "Hub reconnected", Type = "SignalR Client Events", Source = _settings.MachineName });
|
||||||
_mainWidget.lblConnectionStatus.Text = "Connected";
|
_mainWidget.lblConnectionStatus.Text = "Connected";
|
||||||
await Task.Yield();
|
await Task.Yield();
|
||||||
}
|
}
|
||||||
|
|
||||||
protected override void Initialize()
|
protected override void Initialize()
|
||||||
{
|
{
|
||||||
ExceptionlessClient.Default.SubmitEvent(new Event { Message = "Initialize", Type = "AppLifecycle", Source = _settings.MachineName });
|
// ExceptionlessClient.Default.SubmitEvent(new Event { Message = "Initialize", Type = "AppLifecycle", Source = _settings.MachineName });
|
||||||
IsMouseVisible = true;
|
IsMouseVisible = true;
|
||||||
Window.AllowUserResizing = true;
|
Window.AllowUserResizing = true;
|
||||||
Window.ClientSizeChanged += OnClientSizeChanged;
|
Window.ClientSizeChanged += OnClientSizeChanged;
|
||||||
|
|
|
@ -42,7 +42,6 @@
|
||||||
</ItemGroup> -->
|
</ItemGroup> -->
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<PackageReference Include="AsyncAwaitBestPractices" Version="6.0.0" />
|
<PackageReference Include="AsyncAwaitBestPractices" Version="6.0.0" />
|
||||||
<PackageReference Include="exceptionless" Version="4.6.2" />
|
|
||||||
<PackageReference Include="Microsoft.Extensions.Configuration.Json" Version="6.0.0-preview.7.21377.19" />
|
<PackageReference Include="Microsoft.Extensions.Configuration.Json" Version="6.0.0-preview.7.21377.19" />
|
||||||
<PackageReference Include="MonoGame.Extended" Version="3.8.0" />
|
<PackageReference Include="MonoGame.Extended" Version="3.8.0" />
|
||||||
<PackageReference Include="MonoGame.Framework.DesktopGL" Version="3.8.0.1641" />
|
<PackageReference Include="MonoGame.Framework.DesktopGL" Version="3.8.0.1641" />
|
||||||
|
@ -55,6 +54,7 @@
|
||||||
<PackageReference Include="polly" Version="7.2.2" />
|
<PackageReference Include="polly" Version="7.2.2" />
|
||||||
<PackageReference Include="polly.extensions.http" Version="3.0.0" />
|
<PackageReference Include="polly.extensions.http" Version="3.0.0" />
|
||||||
<PackageReference Include="Refit.HttpClientFactory" Version="6.0.94" />
|
<PackageReference Include="Refit.HttpClientFactory" Version="6.0.94" />
|
||||||
|
<PackageReference Include="Sentry" Version="3.9.2" />
|
||||||
<PackageReference Include="TinyMessenger" Version="1.4.0-alpha3">
|
<PackageReference Include="TinyMessenger" Version="1.4.0-alpha3">
|
||||||
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
|
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
|
||||||
<PrivateAssets>all</PrivateAssets>
|
<PrivateAssets>all</PrivateAssets>
|
||||||
|
|
|
@ -1,4 +1,3 @@
|
||||||
using Exceptionless;
|
|
||||||
using Myra.Graphics2D.Brushes;
|
using Myra.Graphics2D.Brushes;
|
||||||
using Myra.Graphics2D.UI;
|
using Myra.Graphics2D.UI;
|
||||||
using System;
|
using System;
|
||||||
|
@ -123,7 +122,7 @@ namespace Sledgemapper.UI
|
||||||
}
|
}
|
||||||
catch (Exception ex)
|
catch (Exception ex)
|
||||||
{
|
{
|
||||||
ExceptionlessClient.Default.SubmitException(ex);
|
//ExceptionlessClient.Default.SubmitException(ex);
|
||||||
}
|
}
|
||||||
|
|
||||||
//if (successful)
|
//if (successful)
|
||||||
|
|
|
@ -1,7 +1,6 @@
|
||||||
using System;
|
using System;
|
||||||
using System.Diagnostics;
|
using System.Diagnostics;
|
||||||
using System.Linq;
|
using System.Linq;
|
||||||
using Exceptionless;
|
|
||||||
using Microsoft.Xna.Framework;
|
using Microsoft.Xna.Framework;
|
||||||
using Myra.Graphics2D.Brushes;
|
using Myra.Graphics2D.Brushes;
|
||||||
using Myra.Graphics2D.UI;
|
using Myra.Graphics2D.UI;
|
||||||
|
@ -122,13 +121,13 @@ namespace Sledgemapper.UI
|
||||||
}
|
}
|
||||||
catch (Refit.ApiException refitException)
|
catch (Refit.ApiException refitException)
|
||||||
{
|
{
|
||||||
ExceptionlessClient.Default.SubmitException(refitException);
|
//ExceptionlessClient.Default.SubmitException(refitException);
|
||||||
LblLoginError.Text = refitException.Content;
|
LblLoginError.Text = refitException.Content;
|
||||||
LblLoginError.Visible = true;
|
LblLoginError.Visible = true;
|
||||||
}
|
}
|
||||||
catch (Exception ex)
|
catch (Exception ex)
|
||||||
{
|
{
|
||||||
ExceptionlessClient.Default.SubmitException(ex);
|
//ExceptionlessClient.Default.SubmitException(ex);
|
||||||
LblLoginError.Text = "Can't connect to the server";
|
LblLoginError.Text = "Can't connect to the server";
|
||||||
LblLoginError.Visible = true;
|
LblLoginError.Visible = true;
|
||||||
Debug.Write(ex);
|
Debug.Write(ex);
|
||||||
|
@ -190,13 +189,13 @@ namespace Sledgemapper.UI
|
||||||
}
|
}
|
||||||
catch (Refit.ApiException refitException)
|
catch (Refit.ApiException refitException)
|
||||||
{
|
{
|
||||||
ExceptionlessClient.Default.SubmitException(refitException);
|
//ExceptionlessClient.Default.SubmitException(refitException);
|
||||||
localContent.LblLoginError.Text = refitException.Content;
|
localContent.LblLoginError.Text = refitException.Content;
|
||||||
localContent.LblLoginError.Visible = true;
|
localContent.LblLoginError.Visible = true;
|
||||||
}
|
}
|
||||||
catch (Exception ex)
|
catch (Exception ex)
|
||||||
{
|
{
|
||||||
ExceptionlessClient.Default.SubmitException(ex);
|
//ExceptionlessClient.Default.SubmitException(ex);
|
||||||
localContent.LblLoginError.Text = "Can't connect to the server";
|
localContent.LblLoginError.Text = "Can't connect to the server";
|
||||||
localContent.LblLoginError.Visible = true;
|
localContent.LblLoginError.Visible = true;
|
||||||
Debug.Write(ex);
|
Debug.Write(ex);
|
||||||
|
|
|
@ -1,4 +1,3 @@
|
||||||
using Exceptionless;
|
|
||||||
using Microsoft.AspNetCore.SignalR.Client;
|
using Microsoft.AspNetCore.SignalR.Client;
|
||||||
using Microsoft.Xna.Framework;
|
using Microsoft.Xna.Framework;
|
||||||
using Microsoft.Xna.Framework.Content;
|
using Microsoft.Xna.Framework.Content;
|
||||||
|
@ -617,7 +616,7 @@ namespace Sledgemapper.UI
|
||||||
}
|
}
|
||||||
catch (Exception ex)
|
catch (Exception ex)
|
||||||
{
|
{
|
||||||
ExceptionlessClient.Default.SubmitException(ex);
|
Sentry.SentrySdk.CaptureException(ex);
|
||||||
}
|
}
|
||||||
|
|
||||||
//if (successful)
|
//if (successful)
|
||||||
|
@ -780,7 +779,7 @@ namespace Sledgemapper.UI
|
||||||
}
|
}
|
||||||
catch (Exception ex)
|
catch (Exception ex)
|
||||||
{
|
{
|
||||||
ExceptionlessClient.Default.SubmitException(ex);
|
//ExceptionlessClient.Default.SubmitException(ex);
|
||||||
}
|
}
|
||||||
|
|
||||||
//if (successful)
|
//if (successful)
|
||||||
|
|
|
@ -1,6 +1,5 @@
|
||||||
/* Generated by MyraPad at 10/11/2020 10:59:36 */
|
/* Generated by MyraPad at 10/11/2020 10:59:36 */
|
||||||
using System;
|
using System;
|
||||||
using Exceptionless;
|
|
||||||
using Microsoft.AspNetCore.SignalR.Client;
|
using Microsoft.AspNetCore.SignalR.Client;
|
||||||
using Myra.Graphics2D.UI;
|
using Myra.Graphics2D.UI;
|
||||||
using Sledgemapper.Shared.Entities;
|
using Sledgemapper.Shared.Entities;
|
||||||
|
@ -58,7 +57,7 @@ namespace Sledgemapper.UI
|
||||||
}
|
}
|
||||||
catch (Exception ex)
|
catch (Exception ex)
|
||||||
{
|
{
|
||||||
ExceptionlessClient.Default.SubmitException(ex);
|
//ExceptionlessClient.Default.SubmitException(ex);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (successful)
|
if (successful)
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue