mozilla / django-browserid

Django application for adding BrowserID support.
Mozilla Public License 2.0
180 stars 80 forks source link

Install fails on Python 3.3.2. #184

Closed ubernostrum closed 10 years ago

ubernostrum commented 10 years ago

When trying to pip install django-browserid on Python 3.3.2:

(browserid-install)(13:54) james@copenhagen:~/dev/pyenvs/browserid-install $ pip install django-browserid Downloading/unpacking django-browserid Downloading django-browserid-0.8.tar.gz Running setup.py egg_info for package django-browserid Traceback (most recent call last): File "", line 16, in File "/Users/james/.pyenv/versions/browserid-install/build/django-browserid/setup.py", line 24, in version=find_version('django_browserid/init.py'), File "/Users/james/.pyenv/versions/browserid-install/build/django-browserid/setup.py", line 14, in find_version version_file, re.M) File "/Users/james/.pyenv/versions/browserid-install/lib/python3.3/re.py", line 161, in search return _compile(pattern, flags).search(string) TypeError: can't use a string pattern on a bytes-like object Complete output from command python setup.py egg_info: Traceback (most recent call last):

File "", line 16, in

File "/Users/james/.pyenv/versions/browserid-install/build/django-browserid/setup.py", line 24, in

version=find_version('django_browserid/__init__.py'),

File "/Users/james/.pyenv/versions/browserid-install/build/django-browserid/setup.py", line 14, in find_version

version_file, re.M)

File "/Users/james/.pyenv/versions/browserid-install/lib/python3.3/re.py", line 161, in search

return _compile(pattern, flags).search(string)

TypeError: can't use a string pattern on a bytes-like object

Cleaning up... Command python setup.py egg_info failed with error code 1 in /Users/james/.pyenv/versions/browserid-install/build/django-browserid Storing complete log in /Users/james/.pip/pip.log

Same thing occurs when trying to manually setup.py install from a downloaded copy of the package.

Issue seems to be the read() function in setup.py. Dropping the codec/encoding bits results in clean install, though I don't know if that's a perfect/portable solution.

Osmose commented 10 years ago

Hmm, this works locally for me, both from pip in a python3.3 virtualenv and from running setup.py install. I was also able to get this working with tox, which runs the package install as part of the tests. I'm closing this for now, but feel free to reopen if I'm wrong or if you're still seeing this.