Fix bots + positions managements

This commit is contained in:
2025-04-23 19:36:26 +02:00
parent ad5996ca61
commit 76b8b7ebb6
24 changed files with 299 additions and 98 deletions

View File

@@ -50,6 +50,7 @@ namespace Managing.Infrastructure.Evm.Services
}
catch (Exception ex) when (!(ex is Web3ProxyException))
{
SentrySdk.CaptureException(ex);
throw new Web3ProxyException($"Failed to call Privy service at {endpoint}: {ex.Message}");
}
}
@@ -81,6 +82,7 @@ namespace Managing.Infrastructure.Evm.Services
}
catch (Exception ex) when (!(ex is Web3ProxyException))
{
SentrySdk.CaptureException(ex);
throw new Web3ProxyException($"Failed to get Privy service at {endpoint}: {ex.Message}");
}
}
@@ -107,6 +109,7 @@ namespace Managing.Infrastructure.Evm.Services
}
catch (Exception ex) when (!(ex is Web3ProxyException))
{
SentrySdk.CaptureException(ex);
throw new Web3ProxyException($"Failed to call GMX service at {endpoint}: {ex.Message}");
}
}
@@ -138,6 +141,7 @@ namespace Managing.Infrastructure.Evm.Services
}
catch (Exception ex) when (!(ex is Web3ProxyException))
{
SentrySdk.CaptureException(ex);
throw new Web3ProxyException($"Failed to get GMX service at {endpoint}: {ex.Message}");
}
}
@@ -178,6 +182,7 @@ namespace Managing.Infrastructure.Evm.Services
}
catch (Exception ex) when (!(ex is Web3ProxyException))
{
SentrySdk.CaptureException(ex);
// If we couldn't parse the error as JSON or another issue occurred
var content = await response.Content.ReadAsStringAsync();
throw new Web3ProxyException($"HTTP error {statusCode}: {content}");