#NEWLINE# def get( self , path , params = None ) : #NEWLINE# #INDENT# "Make a GET request, optionally including a parameters, to a path.\n\n        The path of the request is the full URL.\n\n        Parameters\n        ----------\n        path : str\n            The URL to request\n        params : DataQuery, optional\n            The query to pass when making the request\n\n        Returns\n        -------\n        resp : requests.Response\n            The server's response to the request\n\n        Raises\n        ------\n        HTTPError\n            If the server returns anything other than a 200 (OK) code\n\n        See Also\n        --------\n        get_query, get\n        " #NEWLINE# resp = self . _session . get ( path , params = params ) #NEWLINE# if ( resp . status_code != 200 ) : #NEWLINE# #INDENT# if resp . headers [ 'Content-Type' ] . startswith ( 'text/html' ) : #NEWLINE# #INDENT# text = resp . reason #NEWLINE# #UNINDENT# else : #NEWLINE# #INDENT# text = resp . text #NEWLINE# #UNINDENT# raise requests . HTTPError ( ( 'Error accessing %s: %d %s' % ( resp . request . url , resp . status_code , params ) ) ) #NEWLINE# #UNINDENT# return resp