nicfit / eyeD3

eyeD3 is a Python module and command line program for processing ID3 tags. Information about mp3 files (i.e bit rate, sample frequency, play time, etc.) is also provided. The formats supported are ID3v1 (1.0/1.1) and ID3v2 (2.3/2.4).
http://eyed3.nicfit.net/
GNU General Public License v3.0
547 stars 59 forks source link

distutils.errors.DistutilsFileError while importing eyed3 #331

Open pandaxzj opened 5 years ago

pandaxzj commented 5 years ago

Hello, I'am using python 3.7.3 from miniconda on vs 2019 on win10. I have installed eyeD3 and its requirements. Yet when I tried to import eyeD3 on cmd it ran errorly:

Python 3.7.3 (default, Mar 27 2019, 17:13:21) [MSC v.1915 64 bit (AMD64)] :: Anaconda, Inc. on win32 Type "help", "copyright", "credits" or "license" for more information.

import eyed3 Traceback (most recent call last): File "D:\Microsoft Visual Studio\2019 Community\Common7\IDE\Extensions\Microsoft\Python\Miniconda\Miniconda3-x64\Lib\distutils\dir_util.py", line 70, in mkpath os.mkdir(head, mode) FileNotFoundError: [WinError 206] 文件名或扩展名太长。: 'D:\Microsoft Visual Studio\2019 Community\Common7\IDE\Extensions\Microsoft\Python\Miniconda\Miniconda3-x 64\Lib\site-packages\magic\pycache\Release\Microsoft Visual Studio\2019 Community\Common7\IDE\Extensions\Microsoft\Python\Miniconda\Miniconda3-x64'

During handling of the above exception, another exception occurred:

Traceback (most recent call last): File "", line 1, in File "C:\Users\panda\AppData\Roaming\Python\Python37\site-packages\eyed3__init.py", line 32, in from .utils.log import log # noqa: E402 File "C:\Users\panda\AppData\Roaming\Python\Python37\site-packages\eyed3\utils__init.py", line 27, in import magic File "D:\Microsoft Visual Studio\2019 Community\Common7\IDE\Extensions\Microsoft\Python\Miniconda\Miniconda3-x64\Lib\site-packages\magic\init__.py", line 1, in from . import ffi File "D:\Microsoft Visual Studio\2019 Community\Common7\IDE\Extensions\Microsoft\Python\Miniconda\Miniconda3-x64\Lib\site-packages\magic\ffi.py", line 27, in ext_package="magic") File "D:\Microsoft Visual Studio\2019 Community\Common7\IDE\Extensions\Microsoft\Python\Miniconda\Miniconda3-x64\Lib\site-packages\cffi\api.py", line 437, in verify lib = self.verifier.load_library() File "D:\Microsoft Visual Studio\2019 Community\Common7\IDE\Extensions\Microsoft\Python\Miniconda\Miniconda3-x64\Lib\site-packages\cffi\verifier.py", line 113, in load_library self._compile_module() File "D:\Microsoft Visual Studio\2019 Community\Common7\IDE\Extensions\Microsoft\Python\Miniconda\Miniconda3-x64\Lib\site-packages\cffi\verifier.py", line 210, in _compile_module outputfilename = ffiplatform.compile(tmpdir, self.get_extension()) File "D:\Microsoft Visual Studio\2019 Community\Common7\IDE\Extensions\Microsoft\Python\Miniconda\Miniconda3-x64\Lib\site-packages\cffi\ffiplatform.py", line 29, in compile outputfilename = _build(tmpdir, ext, compiler_verbose) File "D:\Microsoft Visual Studio\2019 Community\Common7\IDE\Extensions\Microsoft\Python\Miniconda\Miniconda3-x64\Lib\site-packages\cffi\ffiplatform.py", line 55, in _build dist.run_command('build_ext') File "D:\Microsoft Visual Studio\2019 Community\Common7\IDE\Extensions\Microsoft\Python\Miniconda\Miniconda3-x64\Lib\distutils\dist.py", line 985, in run_command cmd_obj.run() File "D:\Microsoft Visual Studio\2019 Community\Common7\IDE\Extensions\Microsoft\Python\Miniconda\Miniconda3-x64\Lib\site-packages\setuptools\command\build_ext.py", line 78, in run _build_ext.run(self) File "D:\Microsoft Visual Studio\2019 Community\Common7\IDE\Extensions\Microsoft\Python\Miniconda\Miniconda3-x64\Lib\distutils\command\build_ext.py", line 340, in run self.build_extensions() File "D:\Microsoft Visual Studio\2019 Community\Common7\IDE\Extensions\Microsoft\Python\Miniconda\Miniconda3-x64\Lib\distutils\command\build_ext.py", line 449, in build_extensions self._build_extensions_serial() File "D:\Microsoft Visual Studio\2019 Community\Common7\IDE\Extensions\Microsoft\Python\Miniconda\Miniconda3-x64\Lib\distutils\command\build_ext.py", line 474, in _build_extensions_serial self.build_extension(ext) File "D:\Microsoft Visual Studio\2019 Community\Common7\IDE\Extensions\Microsoft\Python\Miniconda\Miniconda3-x64\Lib\site-packages\setuptools\command\build_ext.py", line 199, in build_extension _build_ext.build_extension(self, ext) File "D:\Microsoft Visual Studio\2019 Community\Common7\IDE\Extensions\Microsoft\Python\Miniconda\Miniconda3-x64\Lib\distutils\command\build_ext.py", line 534, in build_extension depends=ext.depends) File "D:\Microsoft Visual Studio\2019 Community\Common7\IDE\Extensions\Microsoft\Python\Miniconda\Miniconda3-x64\Lib\distutils_msvccompiler.py", line 348, in compile sources, depends, extra_postargs) File "D:\Microsoft Visual Studio\2019 Community\Common7\IDE\Extensions\Microsoft\Python\Miniconda\Miniconda3-x64\Lib\distutils\ccompiler.py", line 348, in _setup_compile self.mkpath(os.path.dirname(obj)) File "D:\Microsoft Visual Studio\2019 Community\Common7\IDE\Extensions\Microsoft\Python\Miniconda\Miniconda3-x64\Lib\distutils\ccompiler.py", line 915, in mkpath mkpath(name, mode, dry_run=self.dry_run) File "D:\Microsoft Visual Studio\2019 Community\Common7\IDE\Extensions\Microsoft\Python\Miniconda\Miniconda3-x64\Lib\distutils\dir_util.py", line 74, in mkpath "could not create '%s': %s" % (head, exc.args[-1])) distutils.errors.DistutilsFileError: could not create 'D:\Microsoft Visual Studio\2019 Community\Common7\IDE\Extensions\Microsoft\Python\Miniconda\Miniconda3-x64\Lib\site-packages\magic\pycache__\Release\Microsoft Visual Studio\2019 Community\Common7\IDE\Extensions\Microsoft\Python\Miniconda\Miniconda3-x64': 文件名或扩展名太长。

The Chinese "文件名或扩展名太长" means either a file name or an extension name is too long

nicfit commented 5 years ago

This may be an issue with #! interpreter length limits. If installed into a directory with a shorter path does the error still occur?