lint
This commit is contained in:
parent
64c6414fb8
commit
28e817f814
4 changed files with 5 additions and 3 deletions
|
@ -34,6 +34,7 @@ app.register_blueprint(portal, url_prefix="/portal")
|
|||
app.register_blueprint(tfstate, url_prefix="/tfstate")
|
||||
app.register_blueprint(report, url_prefix="/report")
|
||||
|
||||
|
||||
def not_migrating() -> bool:
|
||||
return len(sys.argv) < 2 or sys.argv[1] != "db"
|
||||
|
||||
|
|
|
@ -4,7 +4,7 @@ from typing import Optional
|
|||
|
||||
from flask import Blueprint, render_template, request, url_for, redirect
|
||||
from flask.typing import ResponseReturnValue
|
||||
from jinja2.utils import markupsafe
|
||||
from markupsafe import Markup
|
||||
from sqlalchemy import desc, or_, func
|
||||
|
||||
from app.alarms import alarms_for
|
||||
|
@ -90,7 +90,7 @@ def describe_brn(s: str) -> ResponseReturnValue:
|
|||
).first()
|
||||
if not proxy:
|
||||
return s
|
||||
return markupsafe.Markup(
|
||||
return Markup(
|
||||
f"Proxy: {proxy.url}<br>({proxy.origin.group.group_name}: {proxy.origin.domain_name})")
|
||||
if parts[5].startswith("quota/"):
|
||||
if parts[4] == "cloudfront":
|
||||
|
|
|
@ -10,7 +10,7 @@ report = Blueprint("report", __name__)
|
|||
|
||||
@report.route("/blocks", methods=['GET'])
|
||||
def report_blocks() -> ResponseReturnValue:
|
||||
blocked_today = db.session.query(
|
||||
blocked_today = db.session.query( # type: ignore[no-untyped-call]
|
||||
Origin.domain_name,
|
||||
Origin.description,
|
||||
Proxy.added,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue