@@ -813,11 +813,11 @@ def _create_task_cache_dir(self, task_id):
813813 pass
814814 return task_cache_dir
815815
816- def _perform_api_call (self , call , data = None , filePath = None , add_authentication = True ,
817- """Perform an API call at the OpenML server.
816+ def _perform_api_call (self , call , data = None , filePath = None , add_authentication = True ):
817+ """
818+ Perform an API call at the OpenML server.
818819 return self._read_url(url, data=data, filePath=filePath,
819-
820- def _read_url(self, url, add_authentication=False, data=None, filePath=None):
820+ def _read_url(self, url, add_authentication=False, data=None, filePath=None):
821821
822822 Parameters
823823 ----------
@@ -845,8 +845,7 @@ def _read_url(self, url, add_authentication=False, data=None, filePath=None):
845845 def _read_url (self , url , data = None ):
846846 if data is None :
847847 data = {}
848- data ['session_hash' ] = self .config .get ('FAKE_SECTION' , 'apikey' )
849- data ['session_hash' ] = self ._session_hash
848+ data ['session_hash' ] = self .config .get ('FAKE_SECTION' , 'apikey' )
850849
851850 if filePath is not None :
852851 if os .path .isabs (filePath ):
@@ -867,8 +866,6 @@ def _read_url(self, url, data=None):
867866 return response .status_code , response
868867 else :
869868 raise "File doesn't exists"
870-
871-
872869 else :
873870 data = urlencode (data )
874871 data = data .encode ('utf-8' )
@@ -908,7 +905,6 @@ def _read_url(self, url, data=None):
908905 if not chunk :
909906 break
910907 string .write (chunk )
911-
912908 return return_code , string .getvalue ()
913909
914910 def upload_dataset (self , description , filePath = None ):
0 commit comments