diff --git a/automon/integrations/facebook/groups.py b/automon/integrations/facebook/groups.py index d84eb87b..791f1a06 100644 --- a/automon/integrations/facebook/groups.py +++ b/automon/integrations/facebook/groups.py @@ -585,7 +585,6 @@ def to_dict(self): title=self.title(), url=self.url, visible=self.visible(), - status=self._browser.request_status, ) def quit(self): diff --git a/automon/integrations/seleniumWrapper/browser.py b/automon/integrations/seleniumWrapper/browser.py index 3e97a9a9..7670c886 100644 --- a/automon/integrations/seleniumWrapper/browser.py +++ b/automon/integrations/seleniumWrapper/browser.py @@ -15,7 +15,6 @@ from automon.helpers.dates import Dates from automon.helpers.sleeper import Sleeper from automon.helpers.sanitation import Sanitation -from automon.integrations.requestsWrapper import RequestsClient from .config import SeleniumConfig from .user_agents import SeleniumUserAgentBuilder @@ -33,13 +32,11 @@ def __init__(self, config: SeleniumConfig = None): """A selenium wrapper""" self._config = config or SeleniumConfig() - self.request = None def __repr__(self): try: return str(dict( webdriver=self.webdriver.name or None, - request_status=self.request_status, window_size=self.window_size, )) except Exception as error: @@ -90,14 +87,6 @@ def refresh(self): self.webdriver.refresh() log.info(f'{True}') - @property - def request_status(self): - if self.request is not None: - try: - return self.request.results.status_code - except: - pass - @property def url(self): return self.current_url @@ -327,20 +316,15 @@ def get(self, url: str, **kwargs) -> bool: """get url""" try: if self.webdriver.get(url, **kwargs) is None: - self.request = RequestsClient(url=url) - log.info(str(dict( url=url, current_url=self._current_url, - request_status=self.request_status, kwargs=kwargs ))) return True except Exception as error: - self.request = RequestsClient(url=url) log.error(str(dict( error=error, - request_status=self.request_status ))) return False