-
Notifications
You must be signed in to change notification settings - Fork 115
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
Candles HLOC Data #1887
Merged
adamfraser
merged 30 commits into
main
from
adam/ct-973-add-midbookopen-and-midbookclose-values-to-candles
Jul 25, 2024
Merged
Candles HLOC Data #1887
Changes from 27 commits
Commits
Show all changes
30 commits
Select commit
Hold shift + click to select a range
0c5bec0
Add getOrderBookMidPrice function
adamfraser 1e9ccd7
Add orderbook mid open and mid close prices to candles model
adamfraser 4ebf9be
mend
adamfraser c104358
Merge branch 'main' into adam/ct-973-add-midbookopen-and-midbookclose…
adamfraser 9ec0e6f
Github workflow tweak
adamfraser 2cd954b
Fix typo on column name
adamfraser 464d7ea
Set orderbook mid price to be required but nullable
adamfraser 99dfeab
Add athena table changes
adamfraser 1e055c3
Get tests building
adamfraser 1bd9a8f
WIP: Tests passing
adamfraser a079b29
Add helper function to reset orderbook levels cache
adamfraser e850980
Add tests for orderbook price updates
adamfraser 8b259a1
Return candle updates as well as new candles
adamfraser 1187de5
Add functionality to use orderbook for HLOC in candles API response
adamfraser 9346dc2
Add logging for unexpected orderbook level values
adamfraser acb65b7
Deploy to Dev2
adamfraser b0c7e81
Fix typo in db migration
adamfraser a5c78be
Comments
adamfraser 297d4d5
Athena db column changes
adamfraser b2b708f
Revert "Add functionality to use orderbook for HLOC in candles API re…
adamfraser 3470736
Remove unused comments
adamfraser af54233
Update Candles DB migration file
adamfraser 78cdcc5
Remove unnecessary Promise.all
adamfraser 1b534fd
Test name tweak
adamfraser 0ee1a17
Remove unnecessary redis helper
adamfraser 9055013
Match types to codebase style
adamfraser 33d678f
Revert "Github workflow tweak"
adamfraser 6652e22
Update candle model jsonSchema
adamfraser 5037908
orderbookMidPrices arent required fields
adamfraser 3903935
Wait for candle updates to run before checking for updates
adamfraser File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
19 changes: 19 additions & 0 deletions
19
...db/migrations/migration_files/20240627152937_candles_add_mid_book_price_open_and_close.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
import * as Knex from 'knex'; | ||
|
||
export async function up(knex: Knex): Promise<void> { | ||
return knex | ||
.schema | ||
.alterTable('candles', (table) => { | ||
table.decimal('orderbookMidPriceOpen', null); | ||
table.decimal('orderbookMidPriceClose', null); | ||
}); | ||
} | ||
|
||
export async function down(knex: Knex): Promise<void> { | ||
return knex | ||
.schema | ||
.alterTable('candles', (table) => { | ||
table.dropColumn('orderbookMidPriceOpen'); | ||
table.dropColumn('orderbookMidPriceClose'); | ||
}); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Specify precision and scale for decimal columns.
It's a good practice to specify the precision and scale for decimal columns to avoid potential issues with data storage and retrieval.
Committable suggestion