Want a quick and dirty Flask test server where I can type in a url path
0.0.0.0/**something**
and get it to call a corresponding method of the same name.
Something like this:
from flask import Flask
app = Flask(__name__)
@app.route('/<action>')
def do_it(action=None):
if {PSEUDO: The method exists, call it}
else:
return 'Action not found'
def something():
return 'Did something'
if __name__ == '__main__':
app.run()
Does Flask have a mechanism to help with this or do I have to get messy with reflection?