pynfc icon indicating copy to clipboard operation
pynfc copied to clipboard

Problem with instalation this library

Open TomHyhlik opened this issue 8 years ago • 2 comments

Hi. When I am trying to install it with a command: pip install pynfc It reports: TypeError: 'encoding' is an invalid keyword argument for this function

Cleaning up... Command python setup.py egg_info failed with error code 1 in /tmp/pip_build_root/pynfc Storing debug log for failure in /root/.pip/pip.log

Please help. Thanks

TomHyhlik avatar Dec 17 '16 00:12 TomHyhlik

I have run into the same problem, and it seems weird. The traceback I see is pointing to this line:

with open(path.join(path.abspath(path.dirname(__file__)), 'README.rst'), encoding='utf-8') as f:

The encoding parameter is in python3 but can be used in python2 in the io library (not the standard open() function) ... not sure if that file is including that. Looking at the source in github it appears that the setup.py file that pip is running is different than what I can see here. IDK

jtrip avatar May 07 '17 01:05 jtrip

@TomHyhlik as I mentioned I had the same problem when trying to install via PIP.

However I got it to install manually, hopefully it actually works too.

Just clone the repo, and in src/ run sudo python setup.py install and that should do it.

jtrip avatar May 07 '17 01:05 jtrip