question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

bybit.py of async version fetch_order() returns coroutine object.

See original GitHub issue
  • OS: Linux
  • Programming Language version: python 3.8.3
  • CCXT version: 1.83.42
import ccxt.async_support as ccxt
bybit = ccxt.bybit({'api_key': '', 'secret': ''})

async def exec():
     id = # get id from order already submitted
     symbol = # same as above
     result1 = await bybit.fetch_order(id=id, symbol=symbol)
     print(result1)

asyncio.run(exec())
<coroutine object bybit.fetch_orders at 0x7f7f35081f40>

Issue Analytics

  • State:closed
  • Created a year ago
  • Reactions:1
  • Comments:6 (3 by maintainers)

github_iconTop GitHub Comments

1reaction
kjnh10commented, May 21, 2022

@kroitor 1.83.44 works fine for me. Thanks for your quick action.

1reaction
kroitorcommented, May 21, 2022

@kroitor Oh great, thanks. And maybe fetch_order() return the result as a list (not dict). I checked this by awaiting the result of fetch_order(). This is because fetch_order() use fetch_orders().

So should use return fetch_orders()[0] or something, right?

Yes, you’re right, will fix that as well.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Python async function returning coroutine object
I am running a python program to listen to azure iot hub. The function is returning me a coroutine object instead of a...
Read more >
ccxt/bybit.py at master - GitHub
A JavaScript / Python / PHP cryptocurrency trading API with support for more than 100 bitcoin/altcoin exchanges - ccxt/bybit.py at master · ccxt/ccxt....
Read more >
mdk.fr – Python coroutines with async and await - Julien Palard
As a coroutine just return a coroutine object when called, at some point, some code have to call send(None) on it. But that's...
Read more >
Group And Resources – Bybit API Docs - GitHub Pages
Prior to December 31, 2020, order price of a market order was returned as ... This issue will be has been fixed in...
Read more >
pybit - PyPI
Put simply, pybit (Python + Bybit) is the official lightweight one-stop-shop module for the Bybit HTTP and WebSocket APIs. Originally created by Verata ......
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found