Commit f0ed0bd3 authored by hackhard's avatar hackhard
Browse files

Fixed pipeline

parent 8a9b64fb
Pipeline #9917 passed with stage
in 2 minutes and 34 seconds
...@@ -97,13 +97,22 @@ class Analyzer: ...@@ -97,13 +97,22 @@ class Analyzer:
query_by_relay = ( query_by_relay = (
self.__db_session.query(FetchCompleted, Relay).join(Relay) self.__db_session.query(FetchCompleted, Relay).join(Relay)
).all() ).all()
proxy_countries_html_data = [] proxy_countries_html_data = []
for proxy in proxies: for proxy in proxies:
# checks for the proxy id and proxy country with relay country # checks for the proxy id and proxy country with relay country
query_proxy = self.__db_session.query(Proxy).filter(Proxy.id == proxy.proxy_id,Proxy.country == query_by_relay[0].Relay.country).first() query_proxy = (
self.__db_session.query(Proxy).filter(
Proxy.id == proxy.proxy_id,
Proxy.country == query_by_relay[0].Relay.country,
)
).first()
# Checks for the fetch_completed table to hold off the html_data of that specific proxy # Checks for the fetch_completed table to hold off the html_data of that specific proxy
query_proxy_html = self.__db_session.query(FetchCompleted).filter(FetchCompleted.proxy_id == query_proxy.id).first() query_proxy_html = (
self.__db_session.query(FetchCompleted).filter(
FetchCompleted.proxy_id is query_proxy.id
)
).first()
proxy_countries_html_data.append(query_proxy_html.html_data) proxy_countries_html_data.append(query_proxy_html.html_data)
# Loads JSON # Loads JSON
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment