diff --git a/cgi-bin/rtstats.py b/cgi-bin/rtstats.py index 1760951..ed7c316 100644 --- a/cgi-bin/rtstats.py +++ b/cgi-bin/rtstats.py @@ -15,18 +15,17 @@ .../iddstats_vol_nc1?EXP+10.100.69.110 [volume summaries] .../rtstats_summary_volume1?10.100.69.110+GRAPH [volume summary] """ -from html import escape -import sys +import datetime import re +import sys +from html import escape from io import BytesIO -import datetime -import requests +import myview import numpy as np import pandas as pd +import requests from anytree import Node, RenderTree - -import myview from rtstats_util import fancy_labels, plt RE_IP = re.compile(r"\d{1,3}\.\d{1,3}\.\d{1,3}\.\d{1,3}$") @@ -75,9 +74,7 @@ def handle_topoindex(start_response, link="rtstats_feedtree"): feedtype, ) view = myview.MyView() - view.vars[ - "content" - ] = """ + view.vars["content"] = """
For information regarding the type of data contained within a feed type or feed @@ -85,9 +82,7 @@ def handle_topoindex(start_response, link="rtstats_feedtree"):
Cumulative volume summary Cumulative volume summary graph - """ % dict( - h=hostname, p="/cgi-bin/rtstats/rtstats_summary_volume" - ) + """ % dict(h=hostname, p="/cgi-bin/rtstats/rtstats_summary_volume") content += timing(j, URI) view = myview.MyView() view.vars["content"] = content @@ -162,18 +151,14 @@ def handle_sitesummary(start_response, hostname):
Cumulative volume summary
Cumulative volume summary graph
- """ % dict(
- h=hostname, p="/cgi-bin/rtstats/rtstats_summary_volume1"
- )
+ """ % dict(h=hostname, p="/cgi-bin/rtstats/rtstats_summary_volume1")
view = myview.MyView()
view.vars["content"] = content
return [view.render("main.html").encode("ascii", "ignore")]
@@ -203,9 +188,7 @@ def handle_siteindex(start_response, link, feedtype=None):
- """ % (
- "ANY" if feedtype is None else feedtype,
- )
+ """ % ("ANY" if feedtype is None else feedtype,)
keys = list(domains.keys())
keys.sort()
for d in keys:
Domain Hosts