From 5dc7440a2ba228bc6d7b693ff4737d3a2453e965 Mon Sep 17 00:00:00 2001 From: Ian Cordasco Date: Mon, 1 Feb 2016 20:09:15 -0600 Subject: [PATCH] Start documenting our Trie implementation --- docs/source/internal/plugin_handling.rst | 3 +++ flake8/{ => plugins}/_trie.py | 0 flake8/plugins/manager.py | 2 +- flake8/{ => plugins}/notifier.py | 2 +- tests/unit/test_notifier.py | 2 +- tests/unit/test_trie.py | 2 +- 6 files changed, 7 insertions(+), 4 deletions(-) rename flake8/{ => plugins}/_trie.py (100%) rename flake8/{ => plugins}/notifier.py (97%) diff --git a/docs/source/internal/plugin_handling.rst b/docs/source/internal/plugin_handling.rst index d69957d..e217497 100644 --- a/docs/source/internal/plugin_handling.rst +++ b/docs/source/internal/plugin_handling.rst @@ -53,6 +53,9 @@ These are used to interact with each of the types of plugins individually. Our inspiration for our plugin handling comes from the author's extensive experience with ``stevedore``. +Notifying Listener Plugins +-------------------------- + API Documentation ----------------- diff --git a/flake8/_trie.py b/flake8/plugins/_trie.py similarity index 100% rename from flake8/_trie.py rename to flake8/plugins/_trie.py diff --git a/flake8/plugins/manager.py b/flake8/plugins/manager.py index 570c1d0..4a06c75 100644 --- a/flake8/plugins/manager.py +++ b/flake8/plugins/manager.py @@ -4,8 +4,8 @@ import logging import pkg_resources -from flake8 import notifier from flake8 import exceptions +from flake8.plugins import notifier LOG = logging.getLogger(__name__) diff --git a/flake8/notifier.py b/flake8/plugins/notifier.py similarity index 97% rename from flake8/notifier.py rename to flake8/plugins/notifier.py index e7bf3ba..323ea1d 100644 --- a/flake8/notifier.py +++ b/flake8/plugins/notifier.py @@ -1,5 +1,5 @@ """Implementation of the class that registers and notifies listeners.""" -from flake8 import _trie +from flake8.plugins import _trie class Notifier(object): diff --git a/tests/unit/test_notifier.py b/tests/unit/test_notifier.py index 84b8a45..effcc88 100644 --- a/tests/unit/test_notifier.py +++ b/tests/unit/test_notifier.py @@ -1,7 +1,7 @@ """Unit tests for the Notifier object.""" import pytest -from flake8 import notifier +from flake8.plugins import notifier class _Listener(object): diff --git a/tests/unit/test_trie.py b/tests/unit/test_trie.py index 4cbd8c5..152b5b6 100644 --- a/tests/unit/test_trie.py +++ b/tests/unit/test_trie.py @@ -1,5 +1,5 @@ """Unit test for the _trie module.""" -from flake8 import _trie as trie +from flake8.plugins import _trie as trie class TestTrie(object):