Deribit broker fix #21

Open
ntorres wants to merge 13 commits from deribit_fix into gitea_feats
Collaborator

Here we unify all the deribit’s fixes for the reversed_option chart, this fixes are in the deribit_fix branch and cherry-picked the commits from fix_deribit_hist_queries branch.

  • 2cdaf1ad94: Move from api to venues all the msgspecs structs, also add critical imports in api.py, feed.py and init.py.

  • 89e0e53e2f: Changes related with the api module.

    • Resolve the issue with the expiration dates from deribits, now we int instead of the crazy custom deribits format.
    • The client now have a new _json_rpc_auth_wrapper() that adquires a first access token and then will refresh the access token when this expires.
    • get_assets() fixed, now we use the public endpoint to check the available assets, in the future probably this will change, but for now is working just fine.
    • get_mkt_pairs(), exch_info() and cache_symbols() fix.
    • Also a lot of reformat made in api.
  • 7fdf6fb5ea: Changes related with the feed module.

    • FeedInitfor init_msgs instream_quotes`.
    • new cache is client_pairs so is replacing the old client.cache_symbols().
    • get_mkt_info() add and get_ohlc() fix to comply the new ways of the feed.

Fixes for some issues discussed in #8 (comment)

Please test and merge if satisfied B)


comment in the original PR: #10 (comment)


  • d475347e53:
    • get_timestamp_int(): this a hack to avoid using the custom deribit’s date format, get_currencies() so we could get all deribit’s available currencies.

How to test it.

Easy, run the piker chart command with a valid deribit instrument, here’s an example:

    piker -b deribit chart btc-7mar25-95000-c.reversed_option.deribit
Here we unify all the deribit's fixes for the `reversed_option` `chart`, this fixes are in the `deribit_fix` branch and cherry-picked the commits from `fix_deribit_hist_queries` branch. - https://pikers.dev/pikers/piker/commit/2cdaf1ad940f95e5117dd52feedef94562c94f45: Move from api to venues all the msgspecs structs, also add critical imports in api.py, feed.py and __init__.py. - https://pikers.dev/pikers/piker/commit/89e0e53e2f5189bda9cb16152e13706a42603151: Changes related with the api module. - Resolve the issue with the expiration dates from deribits, now we int instead of the crazy custom deribits format. - The client now have a new `_json_rpc_auth_wrapper()` that adquires a first access token and then will refresh the access token when this expires. - `get_assets()` fixed, now we use the public endpoint to check the available assets, in the future probably this will change, but for now is working just fine. - `get_mkt_pairs()`, `exch_info()` and `cache_symbols()` fix. - Also a lot of reformat made in api. - https://pikers.dev/pikers/piker/commit/7fdf6fb5ea08695e0e249657e69c80ede5cd4aa3: Changes related with the feed module. - FeedInit` for init_msgs in `stream_quotes`. - new cache is `client_pairs` so is replacing the old `client.cache_symbols()`. - `get_mkt_info()` add and `get_ohlc()` fix to comply the new ways of the feed. ----- Fixes for some issues discussed in https://pikers.dev/pikers/piker/pulls/8#issuecomment-156 Please test and merge if satisfied B) ----- comment in the original PR: https://pikers.dev/pikers/piker/pulls/10#issuecomment-162 ----- - https://pikers.dev/pikers/piker/commit/d475347e533081f0cffd042f3ebc7328f47afd09: - `get_timestamp_int()`: this a hack to avoid using the custom deribit's date format, `get_currencies()` so we could get all deribit's available currencies. ----- ### How to test it. Easy, run the piker chart command with a valid deribit instrument, here's an example: ``` piker -b deribit chart btc-7mar25-95000-c.reversed_option.deribit ```
ntorres added 3 commits 2025-01-30 18:51:07 +00:00
f306c94e0d Venues
Moved from api to venues all the msgspecs structs, also added critical imports in api, feed and __init__ mods.
e825b00b85 Deribit's api fix
key changes:

- Resolved the issue with the expiration dates from deribits, now we int instead of the crazy custom deribits format.

- The client now has a new  `_json_rpc_auth_wrapper` that adquires a first access token and then will refresh the access token when this expires.

- `get_assets` fixed, now  we use the public endpoint to check the availables assets, in the future probably this will change, but for now is working just fine.

- `get_mkt_pairs` added.

- `exch_info` added.

- `cache_symbols` fixed.

- Also a lot of reformat made in api.
81cb75f4b3 Deribit's feed fix
- `FeedInit` for init_msgs in `stream_quotes`.

- new cache is `client_pairs` so is replacing the old `client.cache_symbols`.

- `get_mkt_info` added

- `get_ohlc` fixed to comply the new ways of the feed.
ntorres force-pushed deribit_fix from 81cb75f4b3 to 6b48bbca3c 2025-02-03 21:57:09 +00:00 Compare
ntorres force-pushed deribit_fix from 6b48bbca3c to 1568a19cc0 2025-02-03 22:10:39 +00:00 Compare
ntorres force-pushed deribit_fix from 1568a19cc0 to 8165c684e5 2025-02-03 22:22:52 +00:00 Compare
ntorres changed title from Deribit broker fix to Deribit broker fix 2025-02-13 20:06:59 +00:00
ntorres changed target branch from kucoin_and_binance_fix to gitea_feats 2025-02-13 20:07:00 +00:00
ntorres changed title from Deribit broker fix to Deribit broker fix 2025-02-17 14:25:45 +00:00
ntorres changed target branch from gitea_feats to add_ruff_linter 2025-02-17 14:25:46 +00:00
ntorres changed title from Deribit broker fix to Deribit broker fix 2025-02-17 14:26:21 +00:00
ntorres changed target branch from add_ruff_linter to gitea_feats 2025-02-17 14:26:21 +00:00
ntorres force-pushed deribit_fix from 8165c684e5 to e36dde1aa4 2025-02-17 15:52:18 +00:00 Compare
ntorres force-pushed deribit_fix from e36dde1aa4 to 3d00d27a12 2025-02-17 16:25:52 +00:00 Compare
ntorres force-pushed deribit_fix from 3d00d27a12 to d475347e53 2025-02-17 19:03:38 +00:00 Compare
ntorres force-pushed deribit_fix from d475347e53 to b209512eb6 2025-02-24 20:22:26 +00:00 Compare
This pull request can be merged automatically.
You are not authorized to merge this pull request.
You can also view command line instructions.

Step 1:

From your project repository, check out a new branch and test the changes.
git checkout -b deribit_fix gitea_feats
git pull origin deribit_fix

Step 2:

Merge the changes and update on Gitea.
git checkout gitea_feats
git merge --no-ff deribit_fix
git push origin gitea_feats
Sign in to join this conversation.
No reviewers
No Label
No Milestone
No project
No Assignees
1 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: pikers/piker#21
There is no content yet.