From db497f9c171f7a6bd074a57e0946e67b86c9f7a0 Mon Sep 17 00:00:00 2001 From: Elvis Pranskevichus Date: Sat, 8 Feb 2020 20:40:44 -0500 Subject: [PATCH] Fix httptools.__all__ While looking at #52, I noticed that `httptools.__all__` is incorrect and doesn't actually include everything that is exported by the module, which might entice the users to import from the private submodule directly. Fixes: #52 --- httptools/__init__.py | 4 ++-- httptools/parser/__init__.py | 7 +++---- 2 files changed, 5 insertions(+), 6 deletions(-) diff --git a/httptools/__init__.py b/httptools/__init__.py index 5154d40..972053e 100644 --- a/httptools/__init__.py +++ b/httptools/__init__.py @@ -1,6 +1,6 @@ -from .parser import parser +from . import parser from .parser import * # NOQA from ._version import __version__ # NOQA -__all__ = parser.__all__ # NOQA +__all__ = parser.__all__ + ('__version__',) # NOQA diff --git a/httptools/parser/__init__.py b/httptools/parser/__init__.py index fa23e23..d53bad9 100644 --- a/httptools/parser/__init__.py +++ b/httptools/parser/__init__.py @@ -1,5 +1,4 @@ -from .parser import * -from .errors import * +from .parser import * # NoQA +from .errors import * # NoQA - -__all__ = parser.__all__ + errors.__all__ +__all__ = parser.__all__ + errors.__all__ # NoQA