fix
parent
d6f46bea43
commit
bb1a39f4f7
|
@ -0,0 +1,19 @@
|
|||
from app import app, url_for
|
||||
app.config["SERVER_NAME"] = "server"
|
||||
|
||||
with app.app_context():
|
||||
import urllib
|
||||
output = []
|
||||
for rule in app.url_map.iter_rules():
|
||||
|
||||
options = {}
|
||||
for arg in rule.arguments:
|
||||
options[arg] = "[{0}]".format(arg)
|
||||
|
||||
methods = ','.join(rule.methods)
|
||||
url = url_for(rule.endpoint, **options)
|
||||
line = urllib.unquote("{:50s} {:20s} {}".format(rule.endpoint, methods, url))
|
||||
output.append(line)
|
||||
|
||||
for line in sorted(output):
|
||||
print(line)
|
2
app.py
2
app.py
|
@ -57,7 +57,7 @@ def chat():
|
|||
def scoreboard():
|
||||
data = cache.get_complex("scoreboard")
|
||||
graphdata = cache.get_complex("graph")
|
||||
if not data or not graphdata:
|
||||
if data is None or graphdata is None:
|
||||
if config.immediate_scoreboard:
|
||||
data = utils.scoreboard.calculate_scores()
|
||||
graphdata = utils.scoreboard.calculate_graph(data)
|
||||
|
|
|
@ -0,0 +1,19 @@
|
|||
from app import app, url_for
|
||||
app.config["SERVER_NAME"] = "server"
|
||||
|
||||
with app.app_context():
|
||||
import urllib.parse
|
||||
output = []
|
||||
for rule in app.url_map.iter_rules():
|
||||
|
||||
options = {}
|
||||
for arg in rule.arguments:
|
||||
options[arg] = "[{0}]".format(arg)
|
||||
|
||||
methods = ','.join(rule.methods)
|
||||
url = url_for(rule.endpoint, **options)
|
||||
line = urllib.parse.unquote("{:50s} {:20s} {}".format(rule.endpoint, methods, url))
|
||||
output.append(line)
|
||||
|
||||
for line in sorted(output):
|
||||
print(line)
|
Loading…
Reference in New Issue