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
BITBANK sell and buy order error occured OSError: [Errno 22] Invalid argument #2775
Comments
We need the full verbose output without your keys. I don't really understand how you've missed it in that text that says that you should post verbose output and you didn't, you just posted the error callstack again (( You see, if it was enough, I wouldn't ask you about verbose output in #1252 in the first place. That means that the output you've posted isn't enough and there's no need to duplicate it, I need much more of it (another piece of it, above the error). Once again, we need to see the full request and response, not just the error – we need all the verbose output, but without your keys. exchange.verbose = True # ←----------- ADD THIS !
exchange.create_limit_buy_order ('BTC/JPY', amount, ask_price)
exchange.create_limit_sell_order ('BTC/JPY', amount, bid_price) ↑ Run it in like that in |
FYI: I found similar post here https://teratail.com/questions/125060, that seems like multi-posting... |
@sakurai-youhei i guess the teratail website just copies all github content or displays it directly with github API, not related to this issue. |
@kroitor Unfortunately, someone looks to ask his/her own question at teratail as well as here, meaning teratail is not replica of github. teratail is a kind of domestic and standalone Q&A site like stackoverflow and that's why I reached this page when I had been trying to help his/her error. |
Anyway, you can of course ignore my writing noise here; My apologies for bothering you. |
@sakurai-youhei got it, no worries, thx! |
OK.I wrote the request and response detail. |
Also I could ordered in ""bitflyer"" using follow pgm.It was success. bitflyer:SUCCESS the target source orders of market and limit
|
Dear Mr.kroitor
I attached the error follow.Of course I wrote the command like that C:\Users\XXX\AppData\Local\Programs\Python\Python36\python.exe "C:\Program Files\JetBrains\PyCharm Community Edition 2018.1.2\helpers\pydev\pydevd.py" --multiproc --qt-support=auto --client 127.0.0.1 --port XXXXX --file C:/XXX/pr2.py Connected to pydev debugger (build 181.4668.75) Request: POST https://api.bitbank.cc/v1/user/spot/order {'Content-Type': 'application/json', 'ACCESS-KEY': 'XXX', 'ACCESS-NONCE': 'XXX', 'ACCESS-SIGNATURE': 'XXX', 'User-Agent': 'python-requests/2.18.4', 'Accept-Encoding': 'gzip, deflate'} {"pair":"btc_jpy","amount":"0.001","price":"500000.00000000","side":"BUY","type":"limit"} File "C:\Program Files\JetBrains\PyCharm Community Edition 2018.1.2\helpers\pydev\pydevd.py", line 1664, in Process finished with exit code 1 Thanks in advance. |
@k31ww475 ok, now I see it, thx! Will debug it and will get back to you on this issue soon. |
@k31ww475 does fetch_balance work for you? import ccxt
exchange = ccxt.bitbank({
'apiKey': 'YOUR_API_KEY',
'secret': 'YOUR_SECRET',
})
print(exchange.fetch_balance()) ? |
@kroitor |
Target source
The error is follow |
It says that you have to provide a price for whatever order you're making, but you're not providing a price in your request to create a market buy order – you're submitting just the symbol and the amount. |
Exactly.and I set the price in this code like that but the different error still occured.
ERROR
|
@k31ww475 ok, will debug it further and will get back to you shortly. |
@kroitor Thanx lots. |
@kroitor ERROR
TARGET CODE
Thanks in advance |
OSError: [Errno 22] Invalid argument Also it's some kind of pass/directory setting problem.
|
I changed the target code by python.but it ""different"" error occured. error
|
Can you please post your code and verbose output again ? We need to see how you changed the code. For the code: please, make it a complete shortest possible program to reproduce the issue. Don't swallow the lines, we need the entire code that doesn't want to work (10-20 lines), including the instantiation from the beginning to the end, but without your keys. If your code is too big – make it a short example snippet and make sure it works up to the point of error. Do not post one-liners, please. For the output: we need to see the verbose output of both the request and the response. Whenever you have ANY error or ANY problem, please post your code+verbose output for that error, otherwise it will be very hard to help you and we will ask for the data anyway. So, if you don't want to waste your time and you want to get your problem solved quickly, then follow the rules from here precisely: https://github.com/ccxt/ccxt/blob/master/CONTRIBUTING.md#how-to-submit-an-issue |
Hi I can't sell and buy order using bitbank.
the command line is follow
exchange.create_limit_sell_order('BTC/JPY', 0.001, 1000000)
error target source is follow
and I confirmed and successed accurate order on pgm ,when I bought and sold the order the exchage "BITFLYER" in same pgm.So it seems bitbank's interface problem.
detail of error
The text was updated successfully, but these errors were encountered: