Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fcntl not defined (for Win 10/64) for console.py #135

Closed
CoyotePace opened this issue Dec 15, 2017 · 0 comments
Closed

fcntl not defined (for Win 10/64) for console.py #135

CoyotePace opened this issue Dec 15, 2017 · 0 comments

Comments

@CoyotePace
Copy link

installed eyed3 0.8.4 on Win 10/64, python 3.6.3 with libmagic dlls (and maybe there's the problem) but just running eyed3 somefile.mp3 throws an exception
File "c:\users\billh\appdata\local\programs\python\python36\lib\site-packages\eyed3\utils\console.py", line 500, in getTtySize data = fcntl.ioctl(fd, termios.TIOCGWINSZ, '\0' * 4) NameError: name 'fcntl' is not defined
as fcntl isn't defined under Windows (at least with the libraries here...), but happily:

adding NameError to the exceptions list for that try in eyed3\utils\console.py fixes the problem, allowing the pass and fallthru to the other console size tests:
if check_tty: try: data = fcntl.ioctl(fd, termios.TIOCGWINSZ, '\0' * 4) hw = struct.unpack("hh", data) except (OSError, IOError, NameError): pass

@nicfit nicfit closed this as completed in 06d9f16 Mar 27, 2018
nicfit added a commit that referenced this issue Mar 28, 2018
commit e01d4e4
Author: Travis Shirk <travis@pobox.com>
Date:   Tue Mar 27 18:39:15 2018 -0600

    py27 "fixes"

commit 77066ab
Author: Travis Shirk <travis@pobox.com>
Date:   Tue Mar 27 18:33:35 2018 -0600

    Release prep.. !wip

commit db3a369
Author: Travis Shirk <travis@pobox.com>
Date:   Tue Mar 27 18:08:07 2018 -0600

    new: dev: New test and prep. Closes #76

commit 1d3eb74
Author: Travis Shirk <travis@pobox.com>
Date:   Tue Mar 27 18:07:18 2018 -0600

    new: Mp3AudioFile.initTag now returns the new tag.

commit 06d9f16
Author: Travis Shirk <travis@pobox.com>
Date:   Tue Mar 27 17:07:53 2018 -0600

    fix: Handle missing `fcntl` on Windows. Fixes #135.

commit a91f2f8
Merge: 92150a0 8cc5690
Author: Travis Shirk <travis@pobox.com>
Date:   Mon Mar 26 22:48:56 2018 -0600

    Merge branch 'master' of github.com:nicfit/eyeD3

    * 'master' of github.com:nicfit/eyeD3:
      Update pytest from 3.4.2 to 3.5.0 (#175)
      Update twine from 1.10.0 to 1.11.0 (#173)
      Update sphinx from 1.7.1 to 1.7.2 (#174)
      Update sphinxcontrib-paverutils from 1.16.0 to 1.17.0 (#172)
      Update pytest-runner from 4.0 to 4.2 (#171)

commit 92150a0
Author: Travis Shirk <travis@pobox.com>
Date:   Mon Mar 26 21:10:25 2018 -0600

    fix: In addition to None, "" will now clear dates.

commit 8cc5690
Author: pyup.io bot <github-bot@pyup.io>
Date:   Fri Mar 23 20:50:38 2018 +0100

    Update pytest from 3.4.2 to 3.5.0 (#175)

commit f9130a8
Author: pyup.io bot <github-bot@pyup.io>
Date:   Fri Mar 23 00:07:53 2018 +0100

    Update twine from 1.10.0 to 1.11.0 (#173)

commit 28c3d1f
Author: pyup.io bot <github-bot@pyup.io>
Date:   Fri Mar 23 00:07:37 2018 +0100

    Update sphinx from 1.7.1 to 1.7.2 (#174)

commit 58ff1b9
Author: pyup.io bot <github-bot@pyup.io>
Date:   Thu Mar 22 18:01:40 2018 +0100

    Update sphinxcontrib-paverutils from 1.16.0 to 1.17.0 (#172)

commit c8a0a4a
Author: pyup.io bot <github-bot@pyup.io>
Date:   Sun Mar 18 17:25:58 2018 +0100

    Update pytest-runner from 4.0 to 4.2 (#171)

commit f877ae4
Merge: da02459 bc16a97
Author: Travis Shirk <travis@pobox.com>
Date:   Sat Mar 10 08:28:39 2018 -0700

    Merge branch 'master' of github.com:nicfit/eyeD3

    * 'master' of github.com:nicfit/eyeD3:
      Update twine from 1.9.1 to 1.10.0 (#168)
      Update pytest from 3.4.1 to 3.4.2 (#167)

commit da02459
Author: Travis Shirk <travis@pobox.com>
Date:   Sat Mar 3 22:44:48 2018 -0700

    Clean pytest_cache
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant