Skip to content

Commit

Permalink
Optionally import cchardet if present
Browse files Browse the repository at this point in the history
  • Loading branch information
asvetlov committed Jun 22, 2015
1 parent afed165 commit 666e87e
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 3 deletions.
5 changes: 4 additions & 1 deletion aiohttp/client_reqrep.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,10 @@
import urllib.parse
import warnings

import chardet
try:
import cchardet as chardet
except ImportError:
import chardet

import aiohttp
from . import hdrs, helpers, streams
Expand Down
5 changes: 3 additions & 2 deletions tox.ini
Original file line number Diff line number Diff line change
@@ -1,14 +1,15 @@
[tox]

envlist = check, {old_asyncio,py33,py34}-{debug,release}-{cython,pure}, reportcov
envlist = check, {old_asyncio,py33,py34}-{debug,release}-{cchardet,cython,pure}, reportcov

[testenv]

deps =
nose
coverage
gunicorn
chardet
cchardet: cython
cchardet: cchardet
cython: cython
old_asyncio: asyncio==3.4.1

Expand Down

0 comments on commit 666e87e

Please sign in to comment.