From e9461a3dfe800ce89a5613a72bd30c1c6f11d281 Mon Sep 17 00:00:00 2001 From: jaredvu Date: Fri, 26 Apr 2024 10:50:13 -0700 Subject: [PATCH 1/2] Add new broadcast error and order removal reason --- config/localization/en/app.json | 2 ++ package-lock.json | 4 ++-- package.json | 2 +- scripts/generated/app.ts | 2 ++ 4 files changed, 7 insertions(+), 3 deletions(-) diff --git a/config/localization/en/app.json b/config/localization/en/app.json index 3d16981ee..7578bd5ec 100644 --- a/config/localization/en/app.json +++ b/config/localization/en/app.json @@ -1249,6 +1249,7 @@ "ORDER_REMOVAL_REASON_UNDERCOLLATERALIZED": "The order was removed due to being undercollateralized.", "ORDER_REMOVAL_REASON_UNSPECIFIED": "Unspecified error.", "ORDER_REMOVAL_REASON_USER_CANCELED": "The order was canceled by a user.", + "ORDER_REMOVAL_REASON_VIOLATES_ISOLATED_SUBACCOUNT_CONSTRAINTS": "The order has been removed since filling it would lead to the subaccount violating isolated subaccount constraints.", "ORDER_TYPE": "Order type", "ORDERBOOK": "Order book", "ORDERBOOK_ASK_PRICE": "Ask Price", @@ -1968,6 +1969,7 @@ "BROADCAST_ERROR_2001": "Reduce-only orders cannot increase the position size", "BROADCAST_ERROR_2002": "Reduce-only orders cannot change the position side", "BROADCAST_ERROR_2003": "Post-only order would cross one or more maker orders", + "BROADCAST_ERROR_2005": "Order would violate isolated subaccount constraints.", "BROADCAST_ERROR_3000": "Invalid order flags", "BROADCAST_ERROR_3001": "Invalid order goodTilBlockTime", "BROADCAST_ERROR_3002": "Stateful orders cannot require immediate execution", diff --git a/package-lock.json b/package-lock.json index 4a54737e5..37328f5d5 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,12 +1,12 @@ { "name": "@dydxprotocol/v4-localization", - "version": "1.1.71", + "version": "1.1.72", "lockfileVersion": 2, "requires": true, "packages": { "": { "name": "@dydxprotocol/v4-localization", - "version": "1.1.71", + "version": "1.1.72", "license": "AGPL-3.0", "devDependencies": { "@types/node": "^20.1.7" diff --git a/package.json b/package.json index dc91c7a9d..b1ae2cb11 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@dydxprotocol/v4-localization", - "version": "1.1.71", + "version": "1.1.72", "description": "v4 localization", "main": "index.ts", "scripts": { diff --git a/scripts/generated/app.ts b/scripts/generated/app.ts index 826eddeec..8092f6b7f 100644 --- a/scripts/generated/app.ts +++ b/scripts/generated/app.ts @@ -1406,6 +1406,7 @@ export const APP_STRING_KEYS = { ORDER_REMOVAL_REASON_UNDERCOLLATERALIZED: 'APP.TRADE.ORDER_REMOVAL_REASON_UNDERCOLLATERALIZED', ORDER_REMOVAL_REASON_UNSPECIFIED: 'APP.TRADE.ORDER_REMOVAL_REASON_UNSPECIFIED', ORDER_REMOVAL_REASON_USER_CANCELED: 'APP.TRADE.ORDER_REMOVAL_REASON_USER_CANCELED', + ORDER_REMOVAL_REASON_VIOLATES_ISOLATED_SUBACCOUNT_CONSTRAINTS: 'APP.TRADE.ORDER_REMOVAL_REASON_VIOLATES_ISOLATED_SUBACCOUNT_CONSTRAINTS', ORDER_TYPE: 'APP.TRADE.ORDER_TYPE', PARTIALLY_FILLED: 'APP.TRADE.PARTIALLY_FILLED', PAYMENT: 'APP.TRADE.PAYMENT', @@ -1613,6 +1614,7 @@ export const ERRORS_STRING_KEYS = { BROADCAST_ERROR_2001: 'ERRORS.BROADCAST_ERROR_2001', BROADCAST_ERROR_2002: 'ERRORS.BROADCAST_ERROR_2002', BROADCAST_ERROR_2003: 'ERRORS.BROADCAST_ERROR_2003', + BROADCAST_ERROR_2005: 'ERRORS.BROADCAST_ERROR_2005', BROADCAST_ERROR_3000: 'ERRORS.BROADCAST_ERROR_3000', BROADCAST_ERROR_3001: 'ERRORS.BROADCAST_ERROR_3001', BROADCAST_ERROR_3002: 'ERRORS.BROADCAST_ERROR_3002', From 4bd46f5228915cb1ca84f58fd5b89609e39a553d Mon Sep 17 00:00:00 2001 From: jaredvu Date: Fri, 26 Apr 2024 11:13:43 -0700 Subject: [PATCH 2/2] remove . --- config/localization/en/app.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/config/localization/en/app.json b/config/localization/en/app.json index 7578bd5ec..04d725084 100644 --- a/config/localization/en/app.json +++ b/config/localization/en/app.json @@ -1969,7 +1969,7 @@ "BROADCAST_ERROR_2001": "Reduce-only orders cannot increase the position size", "BROADCAST_ERROR_2002": "Reduce-only orders cannot change the position side", "BROADCAST_ERROR_2003": "Post-only order would cross one or more maker orders", - "BROADCAST_ERROR_2005": "Order would violate isolated subaccount constraints.", + "BROADCAST_ERROR_2005": "Order would violate isolated subaccount constraints", "BROADCAST_ERROR_3000": "Invalid order flags", "BROADCAST_ERROR_3001": "Invalid order goodTilBlockTime", "BROADCAST_ERROR_3002": "Stateful orders cannot require immediate execution",