Skip to content

Commit

Permalink
chore: update logs
Browse files Browse the repository at this point in the history
  • Loading branch information
Primexz committed May 12, 2024
1 parent 0f38462 commit a1b8a60
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions kraken/kraken_api.go
Original file line number Diff line number Diff line change
Expand Up @@ -88,8 +88,6 @@ func BuyBtc(_retry_do_not_use int) {
"expiretm": "+240", // close order after 4 minutes
}

log.Debug("Buying btc with price ", args["price"])

response, krakenErr = getApi().AddOrder("xbt"+strings.ToLower(currency), "buy", "limit", config.KrakenOrderSize, args)
if krakenErr != nil {
log.Error("Failed to buy btc", krakenErr.Error())
Expand All @@ -108,7 +106,7 @@ func BuyBtc(_retry_do_not_use int) {
order, ok := orderInfo[transactionId]
if ok {
orderStatus := order.Status
log.Info("current order status:", orderStatus)
log.Info("Order status:", orderStatus)

if orderStatus == "closed" {
log.Info("Order successfully executed")
Expand Down Expand Up @@ -139,6 +137,7 @@ func BuyBtc(_retry_do_not_use int) {
} else {
log.Error("Failed to query order status")
}

//wait on pending, open
time.Sleep(5 * time.Second)
}
Expand Down

0 comments on commit a1b8a60

Please sign in to comment.