diff --git a/vnpy/api/rest/rest_client.py b/vnpy/api/rest/rest_client.py index 1af29631..ce2fb60a 100644 --- a/vnpy/api/rest/rest_client.py +++ b/vnpy/api/rest/rest_client.py @@ -49,10 +49,6 @@ class Request(object): self.response = None self.status = RequestStatus.ready - self.json=None - - def set_json(self, json_str: dict): - self.json=json_str def __str__(self): if self.response is None: @@ -65,7 +61,6 @@ class Request(object): "headers: {}\n" "params: {}\n" "data: {}\n" - "json: {}\n" "response:" "{}\n".format( self.method, @@ -75,7 +70,6 @@ class Request(object): self.headers, self.params, self.data, - self.json, "" if self.response is None else self.response.text, ) ) @@ -151,7 +145,6 @@ class RestClient(object): on_failed: Callable = None, on_error: Callable = None, extra: Any = None, - json_str: dict = None, ): """ Add a new request. @@ -177,8 +170,6 @@ class RestClient(object): on_error, extra, ) - if json_str is not None: - request.set_json(json_str) self._queue.put(request) return request @@ -262,7 +253,6 @@ class RestClient(object): headers=request.headers, params=request.params, data=request.data, - json=request.json, proxies=self.proxies, ) request.response = response