Metadata-Version: 2.0
Name: more.whytool
Version: 0.5
Summary: What code was responsible for generating a view
Home-page: https://github.com/morepath/more.whytool
Author: Martijn Faassen
Author-email: faassen@startifact.com
License: BSD
Keywords: morepath
Platform: UNKNOWN
Classifier: Intended Audience :: Developers
Classifier: License :: OSI Approved :: BSD License
Classifier: Programming Language :: Python :: 2.7
Classifier: Programming Language :: Python :: 3.5
Requires-Dist: dectate
Requires-Dist: morepath (>=0.15)
Requires-Dist: setuptools
Requires-Dist: webob
Provides-Extra: coverage
Requires-Dist: pytest-cov; extra == 'coverage'
Provides-Extra: docs
Requires-Dist: sphinx; extra == 'docs'
Provides-Extra: pep8
Requires-Dist: flake8; extra == 'pep8'
Provides-Extra: test
Requires-Dist: pytest (>=2.9.0); extra == 'test'
Requires-Dist: pytest-remove-stale-bytecode; extra == 'test'

more.whytool: find out what code was responsible for generating a response
==========================================================================

``more.whytool`` lets you create a tool that tells you what view code
was responsible for handling a request.

To create such a tool you do the following, for instance in the
``main.py`` of your project::

  from more.whytool import why_tool
  from .someplace import SomeApp

  def my_why_tool():
      SomeApp.commit()
      why_tool(SomeApp)

where ``SomeApp`` is the application you want to query, typically the
root application of your project.

Now you need to hook it up in ``setup.py`` to you can have the tool
available::

    entry_points={
        'console_scripts': [
            'morewhytool = myproject.main:my_why_tool',
        ]
    },

After you install your project, you should now have a ``morewhytool``
tool available. You can give it requests::

  $ morewhytool /some/path

It tells you:

* What path directive handled the request.

* What view directive handled the request.

CHANGES
*******

0.5 (2017-01-13)
================

- Initial public release.


