Salamek / cron-descriptor

A Python library that converts cron expressions into human readable strings.
MIT License
155 stars 38 forks source link

Error installing 1.2.9 on pyhton 3.4 #18

Closed guysoft closed 7 years ago

guysoft commented 7 years ago

Hey, Installing on a raspberrypi raspbian I get:

From pip3 install -r requirements.txt

Downloading/unpacking cron-descriptor (from -r requirements.txt (line 6))
  Downloading cron_descriptor-1.2.9.tar.gz
  Running setup.py (path:/tmp/pip-build-m6nvvpb9/cron-descriptor/setup.py) egg_info for package cron-descriptor
    Traceback (most recent call last):
      File "<string>", line 17, in <module>
      File "/tmp/pip-build-m6nvvpb9/cron-descriptor/setup.py", line 30, in <module>
        long_description=open('README.md').read(),
      File "/usr/lib/python3.4/encodings/ascii.py", line 26, in decode
        return codecs.ascii_decode(input, self.errors)[0]
    UnicodeDecodeError: 'ascii' codec can't decode byte 0xc4 in position 2514: ordinal not in range(128)
    Complete output from command python setup.py egg_info:
    Traceback (most recent call last):

  File "<string>", line 17, in <module>

  File "/tmp/pip-build-m6nvvpb9/cron-descriptor/setup.py", line 30, in <module>

    long_description=open('README.md').read(),

  File "/usr/lib/python3.4/encodings/ascii.py", line 26, in decode

    return codecs.ascii_decode(input, self.errors)[0]

UnicodeDecodeError: 'ascii' codec can't decode byte 0xc4 in position 2514: ordinal not in range(128)

----------------------------------------
Cleaning up...
Salamek commented 7 years ago

@guysoft I'm unable to reproduce this error...

  1. What version of raspian you are using ?
  2. What is your output of:
    import sys
    print(sys.getdefaultencoding())
guysoft commented 7 years ago

Using latets raspbian, in a chroot (its part of CustomPiOS)

Python 3.4.2 (default, Oct 19 2014, 13:31:11) 
[GCC 4.9.1] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import sys
>>> print(sys.getdefaultencoding())
utf-8
guysoft commented 7 years ago

The character is crashes on is the İ in Turkish ([Mustafa SADEDİL](https://github.com/sadedil))

The following way fixes it in python 3, but would break python 2: long_description=open('README.md', encoding="utf-8").read()