Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

(feat) add side to liquidation data #7014

Merged
merged 4 commits into from May 13, 2024

Conversation

p-meier
Copy link

@p-meier p-meier commented May 7, 2024

Before submitting this PR, please make sure:

  • Your code builds clean without any errors or warnings
  • You are using approved title ("feat/", "fix/", "docs/", "refactor/")

A description of the changes proposed in the pull request:

I added the side of the liquidations - whether it is the shorts (=buy orders) or longs (=sell orders) that got liquidated.

Tests performed by the developer:

Usage in own strategy with logging (status --live) and adapting the automated tests.

Tips for QA testing:

None

Copy link
Contributor

@cardosofede cardosofede left a comment

Choose a reason for hiding this comment

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

The changes are okey, one thing to review will be instead of using LiquidationSide you can use TradeType.BUY or TradeType.SELL, maybe is better to use the same structure to compare sides in the strategy later on

Copy link
Contributor

@nikspz nikspz left a comment

Choose a reason for hiding this comment

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

image

@p-meier
Copy link
Author

p-meier commented May 10, 2024

@cardosofede thanks for the feedback. I thought about that but normally when I hear people talking about liquidations they speak from Long / Short Liquidations and not in which side the forced order was executed.

Therefore I found it easier to grasp by doing the inversion in the LiquidationsFeed instead of later on in the strategy.

However I am also happy to change it if you like.

@cardosofede
Copy link
Contributor

@cardosofede thanks for the feedback. I thought about that but normally when I hear people talking about liquidations they speak from Long / Short Liquidations and not in which side the forced order was executed.

Therefore I found it easier to grasp by doing the inversion in the LiquidationsFeed instead of later on in the strategy.

However I am also happy to change it if you like.

yep I agree, seems more descriptive too

@nikspz nikspz merged commit 216d3c0 into hummingbot:development May 13, 2024
2 checks passed
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.

None yet

3 participants