{"action":"created","issue":{"url":"https://api.github.com/repos/coleifer/walrus/issues/5","labels_url":"https://api.github.com/repos/coleifer/walrus/issues/5/labels{/name}","comments_url":"https://api.github.com/repos/coleifer/walrus/issues/5/comments","events_url":"https://api.github.com/repos/coleifer/walrus/issues/5/events","html_url":"https://github.com/coleifer/walrus/issues/5","id":56962932,"number":5,"title":"setup failing","user":{"login":"AGASS007","id":2004696,"avatar_url":"https://avatars.githubusercontent.com/u/2004696?v=3","gravatar_id":"","url":"https://api.github.com/users/AGASS007","html_url":"https://github.com/AGASS007","followers_url":"https://api.github.com/users/AGASS007/followers","following_url":"https://api.github.com/users/AGASS007/following{/other_user}","gists_url":"https://api.github.com/users/AGASS007/gists{/gist_id}","starred_url":"https://api.github.com/users/AGASS007/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/AGASS007/subscriptions","organizations_url":"https://api.github.com/users/AGASS007/orgs","repos_url":"https://api.github.com/users/AGASS007/repos","events_url":"https://api.github.com/users/AGASS007/events{/privacy}","received_events_url":"https://api.github.com/users/AGASS007/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":3,"created_at":"2015-02-08T19:02:43Z","updated_at":"2015-02-09T23:08:13Z","closed_at":"2015-02-09T21:00:19Z","body":"Hi,\r\n\r\nI'm having a hard time figuring out whether redis-py be a hard dependency or not. What threw me off guard is (database.py):\r\n```python\r\ntry:\r\n    from redis import Redis\r\nexcept ImportError:\r\n    Redis = None\r\n```\r\nMy problem occurs when installing walrus in a brand new env. Quoting the doc:\r\n```bash\r\n>>> git clone https://github.com/coleifer/walrus.git\r\n>>> cd walrus\r\n>>> python setup.py install\r\nTraceback (most recent call last):\r\n  File \"setup.py\", line 17, in <module>\r\n    version=__import__('walrus').__version__,\r\n  File \".../walrus/walrus/__init__.py\", line 34, in <module>\r\n    from walrus.database import Database\r\n  File \".../walrus/walrus/database.py\", line 42, in <module>\r\n    class Database(Redis):\r\nTypeError: Error when calling the metaclass bases\r\n    cannot create 'NoneType' instances\r\n```\r\nWhen the setup conf looks for the version in the \\_\\_init\\_\\_.py, **Database** is imported and since *redis-py* isn't installed (yet), the **Database** class definition fails.\r\n\r\nSo, here come my two cents on suggestions:\r\n- specify the version in the setup.py, thus avoiding any conflict if **redis-py** and **walrus** are installed at the same time\r\n- on ```ImportError```, set Redis to ```object``` rather than ```None```\r\n- if **Redis** is mandatory, why not putting ```install_requires=[\"redis\"]``` in the setup conf?\r\n- if the version should stay in the \\_\\_init\\_\\_.py, I guess the **Database** import can't.\r\n\r\nI'd be happy to PR if you let me know what you think!\r\n\r\nAnd, just for the record, I've been a happy user of redis-completion for a few years, and I am looking forward to getting my hands dirty with all the new stuff you concocted for us.\r\n\r\n\\_\\_\\_\\_\\_\\_\\_\\_\\_\\_\\_\\_\\_\\_\\_\\_\\_\\_\\_\\_\\_\\_\\_\\_\\_\r\nOff topic: since the autocomplete appears to rely on [HSCAN](http://redis.io/commands/HSCAN), you might want to mention that it's only compatible with Redis >= 2.8.0 (I couldn't set it up on 2.4.14, which is Debian 7 stable version).\r\n\\_\\_\\_\\_\\_\\_\\_\\_\\_\\_\\_\\_\\_\\_\\_\\_\\_\\_\\_\\_\\_\\_\\_\\_\\_\r\n\r\nCheers"},"comment":{"url":"https://api.github.com/repos/coleifer/walrus/issues/comments/73610874","html_url":"https://github.com/coleifer/walrus/issues/5#issuecomment-73610874","issue_url":"https://api.github.com/repos/coleifer/walrus/issues/5","id":73610874,"user":{"login":"coleifer","id":119974,"avatar_url":"https://avatars.githubusercontent.com/u/119974?v=3","gravatar_id":"","url":"https://api.github.com/users/coleifer","html_url":"https://github.com/coleifer","followers_url":"https://api.github.com/users/coleifer/followers","following_url":"https://api.github.com/users/coleifer/following{/other_user}","gists_url":"https://api.github.com/users/coleifer/gists{/gist_id}","starred_url":"https://api.github.com/users/coleifer/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/coleifer/subscriptions","organizations_url":"https://api.github.com/users/coleifer/orgs","repos_url":"https://api.github.com/users/coleifer/repos","events_url":"https://api.github.com/users/coleifer/events{/privacy}","received_events_url":"https://api.github.com/users/coleifer/received_events","type":"User","site_admin":false},"created_at":"2015-02-09T23:08:13Z","updated_at":"2015-02-09T23:08:13Z","body":"See 96a9d88"}}