{"action":"created","issue":{"url":"https://api.github.com/repos/ccxt/ccxt/issues/1054","repository_url":"https://api.github.com/repos/ccxt/ccxt","labels_url":"https://api.github.com/repos/ccxt/ccxt/issues/1054/labels{/name}","comments_url":"https://api.github.com/repos/ccxt/ccxt/issues/1054/comments","events_url":"https://api.github.com/repos/ccxt/ccxt/issues/1054/events","html_url":"https://github.com/ccxt/ccxt/issues/1054","id":285762833,"number":1054,"title":"Binance create_market_sell_order: Illegal characters found in parameter 'quantity'","user":{"login":"allenfrostline","id":24261329,"avatar_url":"https://avatars3.githubusercontent.com/u/24261329?v=4","gravatar_id":"","url":"https://api.github.com/users/allenfrostline","html_url":"https://github.com/allenfrostline","followers_url":"https://api.github.com/users/allenfrostline/followers","following_url":"https://api.github.com/users/allenfrostline/following{/other_user}","gists_url":"https://api.github.com/users/allenfrostline/gists{/gist_id}","starred_url":"https://api.github.com/users/allenfrostline/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/allenfrostline/subscriptions","organizations_url":"https://api.github.com/users/allenfrostline/orgs","repos_url":"https://api.github.com/users/allenfrostline/repos","events_url":"https://api.github.com/users/allenfrostline/events{/privacy}","received_events_url":"https://api.github.com/users/allenfrostline/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":{"login":"kroitor","id":1294454,"avatar_url":"https://avatars3.githubusercontent.com/u/1294454?v=4","gravatar_id":"","url":"https://api.github.com/users/kroitor","html_url":"https://github.com/kroitor","followers_url":"https://api.github.com/users/kroitor/followers","following_url":"https://api.github.com/users/kroitor/following{/other_user}","gists_url":"https://api.github.com/users/kroitor/gists{/gist_id}","starred_url":"https://api.github.com/users/kroitor/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kroitor/subscriptions","organizations_url":"https://api.github.com/users/kroitor/orgs","repos_url":"https://api.github.com/users/kroitor/repos","events_url":"https://api.github.com/users/kroitor/events{/privacy}","received_events_url":"https://api.github.com/users/kroitor/received_events","type":"User","site_admin":false},"assignees":[{"login":"kroitor","id":1294454,"avatar_url":"https://avatars3.githubusercontent.com/u/1294454?v=4","gravatar_id":"","url":"https://api.github.com/users/kroitor","html_url":"https://github.com/kroitor","followers_url":"https://api.github.com/users/kroitor/followers","following_url":"https://api.github.com/users/kroitor/following{/other_user}","gists_url":"https://api.github.com/users/kroitor/gists{/gist_id}","starred_url":"https://api.github.com/users/kroitor/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kroitor/subscriptions","organizations_url":"https://api.github.com/users/kroitor/orgs","repos_url":"https://api.github.com/users/kroitor/repos","events_url":"https://api.github.com/users/kroitor/events{/privacy}","received_events_url":"https://api.github.com/users/kroitor/received_events","type":"User","site_admin":false}],"milestone":null,"comments":12,"created_at":"2018-01-03T17:58:56Z","updated_at":"2018-04-28T21:36:27Z","closed_at":"2018-01-04T02:26:26Z","author_association":"NONE","body":"Here is a simple example of this problem. `a` is created as a Binance exchange object and the markets are already fetched. However,\r\n\r\n```{bash}\r\n>>> a.create_market_sell_order('BTC/USDT', 0.000096)\r\nTraceback (most recent call last):\r\n  File \"/Users/Allen_Frostline/anaconda3/lib/python3.6/site-packages/ccxt/base/exchange.py\", line 346, in fetch\r\n    response.raise_for_status()\r\n  File \"/Users/Allen_Frostline/anaconda3/lib/python3.6/site-packages/requests/models.py\", line 935, in raise_for_status\r\n    raise HTTPError(http_error_msg, response=self)\r\nrequests.exceptions.HTTPError: 400 Client Error: Bad Request for url: https://api.binance.com/api/v3/order\r\n\r\nDuring handling of the above exception, another exception occurred:\r\n\r\nTraceback (most recent call last):\r\n  File \"<stdin>\", line 1, in <module>\r\n  File \"/Users/Allen_Frostline/anaconda3/lib/python3.6/site-packages/ccxt/base/exchange.py\", line 1010, in create_market_sell_order\r\n    return self.create_order(symbol, 'market', 'sell', amount, None, params)\r\n  File \"/Users/Allen_Frostline/anaconda3/lib/python3.6/site-packages/ccxt/binance.py\", line 545, in create_order\r\n    response = self.privatePostOrder(self.extend(order, params))\r\n  File \"/Users/Allen_Frostline/anaconda3/lib/python3.6/site-packages/ccxt/base/exchange.py\", line 296, in request\r\n    return self.fetch2(path, api, method, params, headers, body)\r\n  File \"/Users/Allen_Frostline/anaconda3/lib/python3.6/site-packages/ccxt/base/exchange.py\", line 293, in fetch2\r\n    return self.fetch(request['url'], request['method'], request['headers'], request['body'])\r\n  File \"/Users/Allen_Frostline/anaconda3/lib/python3.6/site-packages/ccxt/base/exchange.py\", line 358, in fetch\r\n    self.handle_errors(response.status_code, response.reason, url, method, None, self.last_http_response)\r\n  File \"/Users/Allen_Frostline/anaconda3/lib/python3.6/site-packages/ccxt/binance.py\", line 707, in handle_errors\r\n    raise ExchangeError(self.id + ' ' + self.json(response))\r\nccxt.base.errors.ExchangeError: binance {\"code\":-1100,\"msg\":\"Illegal characters found in parameter 'quantity'; legal range is '^([0-9]{1,20})(\\\\.[0-9]{1,20})?$'.\"}\r\n>>> \r\n```\r\n\r\nCan anybody explain or solve this?"},"comment":{"url":"https://api.github.com/repos/ccxt/ccxt/issues/comments/385207155","html_url":"https://github.com/ccxt/ccxt/issues/1054#issuecomment-385207155","issue_url":"https://api.github.com/repos/ccxt/ccxt/issues/1054","id":385207155,"user":{"login":"akaniklaus","id":7537828,"avatar_url":"https://avatars1.githubusercontent.com/u/7537828?v=4","gravatar_id":"","url":"https://api.github.com/users/akaniklaus","html_url":"https://github.com/akaniklaus","followers_url":"https://api.github.com/users/akaniklaus/followers","following_url":"https://api.github.com/users/akaniklaus/following{/other_user}","gists_url":"https://api.github.com/users/akaniklaus/gists{/gist_id}","starred_url":"https://api.github.com/users/akaniklaus/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/akaniklaus/subscriptions","organizations_url":"https://api.github.com/users/akaniklaus/orgs","repos_url":"https://api.github.com/users/akaniklaus/repos","events_url":"https://api.github.com/users/akaniklaus/events{/privacy}","received_events_url":"https://api.github.com/users/akaniklaus/received_events","type":"User","site_admin":false},"created_at":"2018-04-28T21:36:27Z","updated_at":"2018-04-28T21:36:27Z","author_association":"NONE","body":"@DexHunter Already did, thanks. I am using the following function:\r\n```\r\ndef format_value(val, ss):\r\n\tprecision = ss.find('1') - 1\r\n\treturn \"{:0.0{}f}\".format(val, precision)\r\n```"}}
{"actor":{"display_login":"akaniklaus"}}