You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In file thehive4py/auth.py, you need to import requests. Else, an error occured
Traceback (most recent call last):
File "/usr/local/lib/python3.7/site-packages/thehive4py/auth.py", line 24, in __call__
req.headers['Authorization'] = requests.auth._basic_auth_str(self.username, self.password)
NameError: name 'requests' is not defined
Steps to Reproduce
Execute the fonction
Possible Solutions
import requests
The text was updated successfully, but these errors were encountered:
In my script, I have the requests dependency. The issue comes from file : thehive4py/auth.py
In line 24, the script is using requests, but the module is not imported at the beggining of the file.
You should add import requests before the line from requests.auth import AuthBase.
NameError: name 'requests' is not defined
Request Type
Bug
Work Environment
Problem Description
In file thehive4py/auth.py, you need to import requests. Else, an error occured
Steps to Reproduce
Possible Solutions
import requests
The text was updated successfully, but these errors were encountered: