Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

_compat.py import creates dependency on Mock library #9

Closed
nichaladas opened this issue Sep 12, 2017 · 2 comments
Closed

_compat.py import creates dependency on Mock library #9

nichaladas opened this issue Sep 12, 2017 · 2 comments

Comments

@nichaladas
Copy link

The importing of the mock library in _compat.py has created a dependency on the mock library when trying to use rlog in a production environment.

Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/VE/lib/python2.7/site-packages/logging_handler.py", line 20, in <module>
    from rlog import RedisHandler
  File "/VE/lib/python2.7/site-packages/rlog/__init__.py", line 2, in <module>
    from rlog.handlers import RedisHandler, RedisListHandler
  File "/VE/lib/python2.7/site-packages/rlog/handlers.py", line 5, in <module>
    from .formatters import JSONFormatter
  File "/VE/lib/python2.7/site-packages/rlog/formatters.py", line 6, in <module>
    from ._compat import json, text_type
  File "/VE/lib/python2.7/site-packages/rlog/_compat.py", line 18, in <module>
    from mock import patch, Mock
ImportError: No module named mock
@lobziik
Copy link
Owner

lobziik commented Sep 13, 2017

Now this import moved to separate file in tests module.

@lobziik lobziik closed this as completed Sep 13, 2017
@lobziik
Copy link
Owner

lobziik commented Sep 13, 2017

Pypi version updated

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants