Skip to content

Conversation

dboyliao
Copy link
Collaborator

@dboyliao dboyliao commented Mar 5, 2025

As title.

@dboyliao dboyliao enabled auto-merge March 5, 2025 08:49
@dboyliao dboyliao merged commit f7cae54 into main Mar 5, 2025
3 checks passed
@dboyliao dboyliao deleted the dboy/coinbase-fix branch March 5, 2025 08:59
Side: cbOrder.Side.GlobalSideType(),
Quantity: cbOrder.Size,
Price: cbOrder.Price,
StopPrice: cbOrder.StopPrice,
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

OrderType field is missing

and TimeInForce

@@ -12,12 +12,20 @@ import (

func toGlobalOrder(cbOrder *api.Order) types.Order {
return types.Order{
SubmitOrder: types.SubmitOrder{
ClientOrderID: cbOrder.ClientOID,
Side: cbOrder.Side.GlobalSideType(),
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

use toGlobalSide() instead of method,

because binding method will import the global types package from the api package.

Exchange: types.ExchangeCoinBase,
Status: cbOrder.Status.GlobalOrderStatus(),
UUID: cbOrder.ID,
OrderID: FNV64a(cbOrder.ID),
OriginalStatus: string(cbOrder.Status),
CreationTime: cbOrder.CreatedAt,
IsWorking: cbOrder.Status == api.OrderStatusOpen,
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

partially fill also means IsWorking

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants