@vitalysokolov

Как установить APScheduler на mac m1?

Устанавливаю через pip в виртуальное окружение
pip install APScheduler

Ошибка с библиотекой backports.zoneinfo.
Collecting APScheduler<blockquote></blockquote>
  Using cached APScheduler-3.9.1-py2.py3-none-any.whl (59 kB)
Collecting tzlocal!=3.*,>=2.0
  Using cached tzlocal-4.2-py3-none-any.whl (19 kB)
Requirement already satisfied: six>=1.4.0 in ./venv/lib/python3.8/site-packages (from APScheduler) (1.16.0)
Collecting pytz
  Using cached pytz-2022.2.1-py2.py3-none-any.whl (500 kB)
Requirement already satisfied: setuptools>=0.7 in ./venv/lib/python3.8/site-packages (from APScheduler) (60.2.0)
Collecting backports.zoneinfo
  Using cached backports.zoneinfo-0.2.1.tar.gz (74 kB)
  Installing build dependencies ... done
  Getting requirements to build wheel ... done
  Preparing metadata (pyproject.toml) ... done
Collecting pytz-deprecation-shim
  Using cached pytz_deprecation_shim-0.1.0.post0-py2.py3-none-any.whl (15 kB)
Collecting tzdata
  Using cached tzdata-2022.2-py2.py3-none-any.whl (336 kB)
Building wheels for collected packages: backports.zoneinfo
  Building wheel for backports.zoneinfo (pyproject.toml) ... error
  error: subprocess-exited-with-error
  
  × Building wheel for backports.zoneinfo (pyproject.toml) did not run successfully.
  │ exit code: 1
  ╰─> [25 lines of output]
      running bdist_wheel
      running build
      running build_py
      running egg_info
      writing src/backports.zoneinfo.egg-info/PKG-INFO
      writing dependency_links to src/backports.zoneinfo.egg-info/dependency_links.txt
      writing requirements to src/backports.zoneinfo.egg-info/requires.txt
      writing top-level names to src/backports.zoneinfo.egg-info/top_level.txt
      reading manifest file 'src/backports.zoneinfo.egg-info/SOURCES.txt'
      reading manifest template 'MANIFEST.in'
      /private/var/folders/07/gxcrb9qd76lgrt90992jdn7c0000gn/T/pip-build-env-b93al4vk/overlay/lib/python3.8/site-packages/setuptools/config/setupcfg.py:508: SetuptoolsDeprecationWarning: The license_file parameter is deprecated, use license_files instead.
        warnings.warn(msg, warning_class)
      warning: no files found matching '*.png' under directory 'docs'
      warning: no files found matching '*.svg' under directory 'docs'
      no previously-included directories found matching 'docs/_build'
      no previously-included directories found matching 'docs/_output'
      adding license file 'LICENSE'
      adding license file 'licenses/LICENSE_APACHE'
      running build_ext
      building 'backports.zoneinfo._czoneinfo' extension
      lib/zoneinfo_module.c:1:10: fatal error: 'Python.h' file not found
      #include "Python.h"
               ^~~~~~~~~~
      1 error generated.
      error: command '/usr/bin/clang' failed with exit code 1
      [end of output]
  
  note: This error originates from a subprocess, and is likely not a problem with pip.
  ERROR: Failed building wheel for backports.zoneinfo
Failed to build backports.zoneinfo
ERROR: Could not build wheels for backports.zoneinfo, which is required to install pyproject.toml-based projects


Может у кого-то есть решение?
  • Вопрос задан
  • 266 просмотров
Решения вопроса 1
@yellowpearl
Аналогичная проблема, уже все перепробовал, все обновлено, pip, wheel, gcc, python3.8 стоит и все равно не хочет ставится, надеюсь кто-нибудь подскажет
Ответ написан
Пригласить эксперта
Ответы на вопрос 1
@DrPalmer
По той же причине, что и в этой статье, я полагаю:

I recently purchased a MacBook Pro 13" with the M1 chip and transferred all my data over using a Time Machine backup. Homebrew packages are currently installed in /usr/local/opt/ but it is my understanding that they should be under /opt/homebrew for Apple Silicon Macs.

Корневой путь на mac m1 другой, такая же проблема у меня была, когда в первый раз на Apple Silicon Mac пытался brew поставить
Ответ написан
Ваш ответ на вопрос

Войдите, чтобы написать ответ

Похожие вопросы
27 нояб. 2024, в 17:41
2000 руб./за проект
27 нояб. 2024, в 17:26
1 руб./за проект
27 нояб. 2024, в 17:17
3000 руб./за проект