parameters: (target)
docstring: Load a bottle application from a module and make sure that the import
          does not affect the current default application, but returns a separate
          application object. See :func:`load` for the target parameter.
docstring_summary: Load a bottle application from a module and make sure that the import
          does not affect the current default application, but returns a separate
          application object. See :func:`load` for the target parameter.
docstring_tokens: Load a bottle application from a module and make sure that the import does not affect the current default application but returns a separate application object . See : func : load for the target parameter .
function: def load_app(target):
      """ Load a bottle application from a module and make sure that the import
          does not affect the current default application, but returns a separate
          application object. See :func:`load` for the target parameter. """
      global NORUN; NORUN, nr_old = True, NORUN
      try:
          tmp = default_app.push() # Create a new "default application"
          rv = load(target) # Import the target module
          return rv if callable(rv) else tmp
      finally:
          default_app.remove(tmp) # Remove the temporary added default application
          NORUN = nr_old
function_tokens: def load_app ( target ) : global NORUN NORUN , nr_old = True , NORUN try : tmp = default_app . push ( ) # Create a new "default application" rv = load ( target ) # Import the target module return rv if callable ( rv ) else tmp finally : default_app . remove ( tmp ) # Remove the temporary added default application NORUN = nr_old