Ошибка Nipype при импорте модуля: TypeError: «<» не поддерживается между экземплярами «int» и «str» - PullRequest
0 голосов
/ 03 апреля 2020

В последнее время я без проблем пишу много скриптов с интерфейсными функциями nipype. Сегодня, без каких-либо серьезных изменений в моей системе, простой импорт модуля выдает ошибку, и я ничего не могу запустить. Я попытался переустановить nipype с помощью «pip install --upgrade --force-reinstall nipype», но ошибка продолжала появляться.

In [1]: import nipype                                                                                                                                                                                       
---------------------------------------------------------------------------
TypeError                                 Traceback (most recent call last)
<ipython-input-1-1c5d8be96d21> in <module>
----> 1 import nipype

~/opt/anaconda3/lib/python3.7/site-packages/nipype/__init__.py in <module>
    129 
    130         if BaseInterface._etelemetry_version_data is None:
--> 131             BaseInterface._etelemetry_version_data = check_latest_version()

~/opt/anaconda3/lib/python3.7/site-packages/nipype/__init__.py in check_latest_version(raise_exception)
     96         if result:
     97             latest.update(**result)
---> 98             if LooseVersion(__version__) != LooseVersion(latest["version"]):
     99                 logger.info(
    100                     INIT_MSG(

~/opt/anaconda3/lib/python3.7/distutils/version.py in __eq__(self, other)
     44 
     45     def __eq__(self, other):
---> 46         c = self._cmp(other)
     47         if c is NotImplemented:
     48             return c

~/opt/anaconda3/lib/python3.7/distutils/version.py in _cmp(self, other)
    335         if self.version == other.version:
    336             return 0
--> 337         if self.version < other.version:
    338             return -1
    339         if self.version > other.version:

TypeError: '<' not supported between instances of 'int' and 'str'

...