Skip to content
Myr

Merge branch 'master' of github.com:mitsuhiko/flask

Before adoption: this commit came in with the history the project adopted, so no landing records it.

authored by Armin Ronacher · committed by Armin Ronacher · parents 2b8ea40, 90884a7 · Browse files · 3 files+13 added−14 removed
This commit

State

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Diff stats

3 files+13 added−14 removed

  • other:+13 added−14 removed

3 files+13 added−14 removed

modified:flask/app.py+5 added-3 removed
655 unmodified lines
656 # easier add new variables in context processors without breaking657 # existing views.658 context.update(orig_ctx)659660 def run(self, host='127.0.0.1', port=5000, **options):660 def run(self, host='127.0.0.1', port=5000, debug=None, **options):661 """Runs the application on a local development server. If the662 :attr:`debug` flag is set the server will automatically reload663 for code changes and show a debugger in case an exception happened.664
14 unmodified lines
679680 :param host: the hostname to listen on. set this to ``'0.0.0.0'``681 to have the server available externally as well.682 :param port: the port of the webserver683 :param debug: if given, enable or disable debug mode.684 See :attr:`debug`.685 :param options: the options to be forwarded to the underlying686 Werkzeug server. See687 :func:`werkzeug.serving.run_simple` for more688 information.689 """690 from werkzeug.serving import run_simple689 if 'debug' in options:690 self.debug = options.pop('debug')691 if debug is not None:692 self.debug = bool(debug)693 options.setdefault('use_reloader', self.debug)694 options.setdefault('use_debugger', self.debug)695 try:696 run_simple(host, port, self, **options)
857 unmodified lines
modified:flask/views.py+1 added-1 removed
62 unmodified lines
63 decorators = []6465 def dispatch_request(self):66 """Subclasses have to override this method to implement the67 actual view functionc ode. This method is called with all67 actual view function code. This method is called with all68 the arguments from the URL rule.69 """70 raise NotImplementedError()71
80 unmodified lines
modified:setup.py+7 added-10 removed
47 unmodified lines
48 description = "Audit source code with PyFlakes"49 user_options = []5051 def initialize_options(self):52 all = None52 pass5354 def finalize_options(self):55 pass56
4 unmodified lines
61 except ImportError:62 print "Audit requires PyFlakes installed in your system."""63 sys.exit(-1)6465 dirs = ['flask', 'tests']66 # Add example directories67 for dir in ['flaskr', 'jqueryexample', 'minitwit']:68 dirs.append(os.path.join('examples', dir))69 # TODO: Add test subdirectories65 warns = 066 # Define top-level directories67 dirs = ('flask', 'examples', 'scripts')68 for dir in dirs:72 for filename in os.listdir(dir):73 if filename.endswith('.py') and filename != '__init__.py':74 warns += flakes.checkPath(os.path.join(dir, filename))69 for root, _, files in os.walk(dir):70 for file in files:71 if file != '__init__.py' and file.endswith('.py') :72 warns += flakes.checkPath(os.path.join(root, file))73 if warns > 0:74 print ("Audit finished with total %d warnings." % warns)75 else:76 print ("No problems found in sourcecode.")778078setup(79 name='Flask',80 version='0.8-dev',81 url='http://github.com/mitsuhiko/flask/',
27 unmodified lines