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

error: legacy-install-failure (Watchdog) #932

Closed
bugsbunny110 opened this issue Dec 4, 2022 · 2 comments
Closed

error: legacy-install-failure (Watchdog) #932

bugsbunny110 opened this issue Dec 4, 2022 · 2 comments

Comments

@bugsbunny110
Copy link

Hello,

When I am trying to install functions-framework, I got an error legacy-install-failure related to watchdog. I read some articles about that but I do not understand how to fix that.

Thanks in advanced

MacBook:Google-Cloud-Function-alpaca karimayad$ pip install functions-framework
Collecting functions-framework
Using cached functions_framework-3.2.1-py3-none-any.whl (30 kB)
Collecting flask<3.0,>=1.0
Using cached Flask-2.2.2-py3-none-any.whl (101 kB)
Requirement already satisfied: click<9.0,>=7.0 in /Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/site-packages (from functions-framework) (8.1.3)
Collecting watchdog>=1.0.0
Using cached watchdog-2.1.9.tar.gz (119 kB)
Preparing metadata (setup.py) ... done
Collecting cloudevents<2.0.0,>=1.2.0
Using cached cloudevents-1.7.1-py3-none-any.whl (46 kB)
Collecting gunicorn<21.0,>=19.2.0
Using cached gunicorn-20.1.0-py3-none-any.whl (79 kB)
Collecting deprecation<3.0,>=2.0
Using cached deprecation-2.1.0-py2.py3-none-any.whl (11 kB)
Requirement already satisfied: Werkzeug>=2.2.2 in /Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/site-packages (from flask<3.0,>=1.0->functions-framework) (2.2.2)
Requirement already satisfied: Jinja2>=3.0 in /Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/site-packages (from flask<3.0,>=1.0->functions-framework) (3.1.2)
Collecting itsdangerous>=2.0
Using cached itsdangerous-2.1.2-py3-none-any.whl (15 kB)
Requirement already satisfied: setuptools>=3.0 in /Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/site-packages (from gunicorn<21.0,>=19.2.0->functions-framework) (65.6.3)
Requirement already satisfied: packaging in /Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/site-packages (from deprecation<3.0,>=2.0->cloudevents<2.0.0,>=1.2.0->functions-framework) (21.3)
Requirement already satisfied: MarkupSafe>=2.0 in /Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/site-packages (from Jinja2>=3.0->flask<3.0,>=1.0->functions-framework) (2.1.1)
Requirement already satisfied: pyparsing!=3.0.5,>=2.0.2 in /Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/site-packages (from packaging->deprecation<3.0,>=2.0->cloudevents<2.0.0,>=1.2.0->functions-framework) (3.0.9)
Building wheels for collected packages: watchdog
Building wheel for watchdog (setup.py) ... error
error: subprocess-exited-with-error

× python setup.py bdist_wheel did not run successfully.
│ exit code: 1
╰─> [53 lines of output]
running bdist_wheel
running build
running build_py
creating build
creating build/lib.macosx-10.9-universal2-cpython-311
creating build/lib.macosx-10.9-universal2-cpython-311/watchdog
copying src/watchdog/watchmedo.py -> build/lib.macosx-10.9-universal2-cpython-311/watchdog
copying src/watchdog/version.py -> build/lib.macosx-10.9-universal2-cpython-311/watchdog
copying src/watchdog/events.py -> build/lib.macosx-10.9-universal2-cpython-311/watchdog
copying src/watchdog/init.py -> build/lib.macosx-10.9-universal2-cpython-311/watchdog
creating build/lib.macosx-10.9-universal2-cpython-311/watchdog/utils
copying src/watchdog/utils/patterns.py -> build/lib.macosx-10.9-universal2-cpython-311/watchdog/utils
copying src/watchdog/utils/init.py -> build/lib.macosx-10.9-universal2-cpython-311/watchdog/utils
copying src/watchdog/utils/dirsnapshot.py -> build/lib.macosx-10.9-universal2-cpython-311/watchdog/utils
copying src/watchdog/utils/delayed_queue.py -> build/lib.macosx-10.9-universal2-cpython-311/watchdog/utils
copying src/watchdog/utils/platform.py -> build/lib.macosx-10.9-universal2-cpython-311/watchdog/utils
copying src/watchdog/utils/process_watcher.py -> build/lib.macosx-10.9-universal2-cpython-311/watchdog/utils
copying src/watchdog/utils/bricks.py -> build/lib.macosx-10.9-universal2-cpython-311/watchdog/utils
copying src/watchdog/utils/echo.py -> build/lib.macosx-10.9-universal2-cpython-311/watchdog/utils
creating build/lib.macosx-10.9-universal2-cpython-311/watchdog/observers
copying src/watchdog/observers/fsevents.py -> build/lib.macosx-10.9-universal2-cpython-311/watchdog/observers
copying src/watchdog/observers/inotify.py -> build/lib.macosx-10.9-universal2-cpython-311/watchdog/observers
copying src/watchdog/observers/init.py -> build/lib.macosx-10.9-universal2-cpython-311/watchdog/observers
copying src/watchdog/observers/api.py -> build/lib.macosx-10.9-universal2-cpython-311/watchdog/observers
copying src/watchdog/observers/inotify_buffer.py -> build/lib.macosx-10.9-universal2-cpython-311/watchdog/observers
copying src/watchdog/observers/winapi.py -> build/lib.macosx-10.9-universal2-cpython-311/watchdog/observers
copying src/watchdog/observers/read_directory_changes.py -> build/lib.macosx-10.9-universal2-cpython-311/watchdog/observers
copying src/watchdog/observers/kqueue.py -> build/lib.macosx-10.9-universal2-cpython-311/watchdog/observers
copying src/watchdog/observers/inotify_c.py -> build/lib.macosx-10.9-universal2-cpython-311/watchdog/observers
copying src/watchdog/observers/polling.py -> build/lib.macosx-10.9-universal2-cpython-311/watchdog/observers
copying src/watchdog/observers/fsevents2.py -> build/lib.macosx-10.9-universal2-cpython-311/watchdog/observers
creating build/lib.macosx-10.9-universal2-cpython-311/watchdog/tricks
copying src/watchdog/tricks/init.py -> build/lib.macosx-10.9-universal2-cpython-311/watchdog/tricks
running egg_info
writing src/watchdog.egg-info/PKG-INFO
writing dependency_links to src/watchdog.egg-info/dependency_links.txt
writing entry points to src/watchdog.egg-info/entry_points.txt
writing requirements to src/watchdog.egg-info/requires.txt
writing top-level names to src/watchdog.egg-info/top_level.txt
reading manifest file 'src/watchdog.egg-info/SOURCES.txt'
reading manifest template 'MANIFEST.in'
warning: no files found matching '*.h' under directory 'src'
adding license file 'LICENSE'
adding license file 'COPYING'
adding license file 'AUTHORS'
writing manifest file 'src/watchdog.egg-info/SOURCES.txt'
running build_ext
building '_watchdog_fsevents' extension
creating build/temp.macosx-10.9-universal2-cpython-311
creating build/temp.macosx-10.9-universal2-cpython-311/src
clang -Wsign-compare -Wunreachable-code -fno-common -dynamic -DNDEBUG -g -fwrapv -O3 -Wall -arch arm64 -arch x86_64 -g -DWATCHDOG_VERSION_STRING="2.1.9" -DWATCHDOG_VERSION_MAJOR=2 -DWATCHDOG_VERSION_MINOR=1 -DWATCHDOG_VERSION_BUILD=9 -I/Library/Frameworks/Python.framework/Versions/3.11/include/python3.11 -c src/watchdog_fsevents.c -o build/temp.macosx-10.9-universal2-cpython-311/src/watchdog_fsevents.o -std=c99 -pedantic -Wall -Wextra -fPIC -Wno-nullability-completeness -Wno-nullability-extension -Wno-newline-eof -Wno-error=unused-command-line-argument
xcrun: error: invalid active developer path (/Library/Developer/CommandLineTools), missing xcrun at: /Library/Developer/CommandLineTools/usr/bin/xcrun
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 watchdog
Running setup.py clean for watchdog
Failed to build watchdog
Installing collected packages: watchdog, itsdangerous, gunicorn, flask, deprecation, cloudevents, functions-framework
Running setup.py install for watchdog ... error
error: subprocess-exited-with-error

× Running setup.py install for watchdog did not run successfully.
│ exit code: 1
╰─> [55 lines of output]
running install
/Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/site-packages/setuptools/command/install.py:34: SetuptoolsDeprecationWarning: setup.py install is deprecated. Use build and pip and other standards-based tools.
warnings.warn(
running build
running build_py
creating build
creating build/lib.macosx-10.9-universal2-cpython-311
creating build/lib.macosx-10.9-universal2-cpython-311/watchdog
copying src/watchdog/watchmedo.py -> build/lib.macosx-10.9-universal2-cpython-311/watchdog
copying src/watchdog/version.py -> build/lib.macosx-10.9-universal2-cpython-311/watchdog
copying src/watchdog/events.py -> build/lib.macosx-10.9-universal2-cpython-311/watchdog
copying src/watchdog/init.py -> build/lib.macosx-10.9-universal2-cpython-311/watchdog
creating build/lib.macosx-10.9-universal2-cpython-311/watchdog/utils
copying src/watchdog/utils/patterns.py -> build/lib.macosx-10.9-universal2-cpython-311/watchdog/utils
copying src/watchdog/utils/init.py -> build/lib.macosx-10.9-universal2-cpython-311/watchdog/utils
copying src/watchdog/utils/dirsnapshot.py -> build/lib.macosx-10.9-universal2-cpython-311/watchdog/utils
copying src/watchdog/utils/delayed_queue.py -> build/lib.macosx-10.9-universal2-cpython-311/watchdog/utils
copying src/watchdog/utils/platform.py -> build/lib.macosx-10.9-universal2-cpython-311/watchdog/utils
copying src/watchdog/utils/process_watcher.py -> build/lib.macosx-10.9-universal2-cpython-311/watchdog/utils
copying src/watchdog/utils/bricks.py -> build/lib.macosx-10.9-universal2-cpython-311/watchdog/utils
copying src/watchdog/utils/echo.py -> build/lib.macosx-10.9-universal2-cpython-311/watchdog/utils
creating build/lib.macosx-10.9-universal2-cpython-311/watchdog/observers
copying src/watchdog/observers/fsevents.py -> build/lib.macosx-10.9-universal2-cpython-311/watchdog/observers
copying src/watchdog/observers/inotify.py -> build/lib.macosx-10.9-universal2-cpython-311/watchdog/observers
copying src/watchdog/observers/init.py -> build/lib.macosx-10.9-universal2-cpython-311/watchdog/observers
copying src/watchdog/observers/api.py -> build/lib.macosx-10.9-universal2-cpython-311/watchdog/observers
copying src/watchdog/observers/inotify_buffer.py -> build/lib.macosx-10.9-universal2-cpython-311/watchdog/observers
copying src/watchdog/observers/winapi.py -> build/lib.macosx-10.9-universal2-cpython-311/watchdog/observers
copying src/watchdog/observers/read_directory_changes.py -> build/lib.macosx-10.9-universal2-cpython-311/watchdog/observers
copying src/watchdog/observers/kqueue.py -> build/lib.macosx-10.9-universal2-cpython-311/watchdog/observers
copying src/watchdog/observers/inotify_c.py -> build/lib.macosx-10.9-universal2-cpython-311/watchdog/observers
copying src/watchdog/observers/polling.py -> build/lib.macosx-10.9-universal2-cpython-311/watchdog/observers
copying src/watchdog/observers/fsevents2.py -> build/lib.macosx-10.9-universal2-cpython-311/watchdog/observers
creating build/lib.macosx-10.9-universal2-cpython-311/watchdog/tricks
copying src/watchdog/tricks/init.py -> build/lib.macosx-10.9-universal2-cpython-311/watchdog/tricks
running egg_info
writing src/watchdog.egg-info/PKG-INFO
writing dependency_links to src/watchdog.egg-info/dependency_links.txt
writing entry points to src/watchdog.egg-info/entry_points.txt
writing requirements to src/watchdog.egg-info/requires.txt
writing top-level names to src/watchdog.egg-info/top_level.txt
reading manifest file 'src/watchdog.egg-info/SOURCES.txt'
reading manifest template 'MANIFEST.in'
warning: no files found matching '*.h' under directory 'src'
adding license file 'LICENSE'
adding license file 'COPYING'
adding license file 'AUTHORS'
writing manifest file 'src/watchdog.egg-info/SOURCES.txt'
running build_ext
building '_watchdog_fsevents' extension
creating build/temp.macosx-10.9-universal2-cpython-311
creating build/temp.macosx-10.9-universal2-cpython-311/src
clang -Wsign-compare -Wunreachable-code -fno-common -dynamic -DNDEBUG -g -fwrapv -O3 -Wall -arch arm64 -arch x86_64 -g -DWATCHDOG_VERSION_STRING="2.1.9" -DWATCHDOG_VERSION_MAJOR=2 -DWATCHDOG_VERSION_MINOR=1 -DWATCHDOG_VERSION_BUILD=9 -I/Library/Frameworks/Python.framework/Versions/3.11/include/python3.11 -c src/watchdog_fsevents.c -o build/temp.macosx-10.9-universal2-cpython-311/src/watchdog_fsevents.o -std=c99 -pedantic -Wall -Wextra -fPIC -Wno-nullability-completeness -Wno-nullability-extension -Wno-newline-eof -Wno-error=unused-command-line-argument
xcrun: error: invalid active developer path (/Library/Developer/CommandLineTools), missing xcrun at: /Library/Developer/CommandLineTools/usr/bin/xcrun
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: legacy-install-failure

× Encountered error while trying to install package.
╰─> watchdog

note: This is an issue with the package mentioned above, not pip.
hint: See above for output from the failure.
MacBook:Google-Cloud-Function-alpaca karimayad$

@BoboTiG BoboTiG added the bug label Dec 5, 2022
@BoboTiG
Copy link
Collaborator

BoboTiG commented Dec 5, 2022

Hello,

We do not ship wheels for Python 3.11 yet. I'm on it!

@BoboTiG
Copy link
Collaborator

BoboTiG commented Dec 5, 2022

Done with fe4a111.

Wheels are online with the version 2.2.0.

@BoboTiG BoboTiG closed this as completed Dec 5, 2022
@BoboTiG BoboTiG added improvement and removed bug labels Dec 6, 2022
netbsd-srcmastr pushed a commit to NetBSD/pkgsrc that referenced this issue May 5, 2023
3.0.0
~~~~~

- Drop support for Python 3.6.
- ``watchdog`` is now PEP 561 compatible, and tested with ``mypy``
- Fix missing ``>`` in ``FileSystemEvent.__repr__()``  (`#980 <https://github.com/gorakhargosh/watchdog/pull/980>`__)
- [ci] Lots of improvements
- [inotify] Return from ``InotifyEmitter.queue_events()`` if not launched when thread is inactive (`#963 <https://github.com/gorakhargosh/watchdog/pull/963>`__)
- [tests] Stability improvements
- [utils] Remove handling of ``threading.Event.isSet`` spelling (`#962 <https://github.com/gorakhargosh/watchdog/pull/962>`__)
- [watchmedo] Fixed tricks YAML generation (`#965 <https://github.com/gorakhargosh/watchdog/pull/965>`__)
- Thanks to our beloved contributors: @kurtmckee, @altendky, @agroszer, @BoboTiG

2.3.1
~~~~~

- Run ``black`` on the entire source code
- Bundle the ``requirements-tests.txt`` file in the source distribution (`#939 <https://github.com/gorakhargosh/watchdog/pull/939>`__)
- [watchmedo] Exclude ``FileOpenedEvent`` events from ``AutoRestartTrick``, and ``ShellCommandTrick``, to restore watchdog < 2.3.0 behavior. A better solution should be found in the future. (`#949 <https://github.com/gorakhargosh/watchdog/pull/949>`__)
- [watchmedo] Log ``FileOpenedEvent``, and ``FileClosedEvent``, events in ``LoggerTrick``
- Thanks to our beloved contributors: @BoboTiG

2.3.0
~~~~~

- [inotify] Add support for ``IN_OPEN`` events: a ``FileOpenedEvent`` event will be fired (`#941 <https://github.com/gorakhargosh/watchdog/pull/941>`__)
- [watchmedo] Add optional event debouncing for ``auto-restart``, only restarting once if many events happen in quick succession (``--debounce-interval``) (`#940 <https://github.com/gorakhargosh/watchdog/pull/940>`__)
- [watchmedo] Exit gracefully on ``KeyboardInterrupt`` exception (Ctrl+C) (`#945 <https://github.com/gorakhargosh/watchdog/pull/945>`__)
- [watchmedo] Add option to not auto-restart the command after it exits (``--no-restart-on-command-exit``) (`#946 <https://github.com/gorakhargosh/watchdog/pull/946>`__)
- Thanks to our beloved contributors: @BoboTiG, @dstaple, @taleinat, @cernekj

2.2.1
~~~~~

- Enable ``mypy`` to discover type hints as specified in PEP 561 (`#933 <https://github.com/gorakhargosh/watchdog/pull/933>`__)
- [ci] Set the expected Python version when building release files
- [ci] Update actions versions in use
- [watchmedo] [regression] Fix usage of missing ``signal.SIGHUP`` attribute on non-Unix OSes (`#935 <https://github.com/gorakhargosh/watchdog/pull/935>`__)
- Thanks to our beloved contributors: @BoboTiG, @simon04, @piotrpdev

2.2.0
~~~~~

- [build] Wheels are now available for Python 3.11 (`#932 <https://github.com/gorakhargosh/watchdog/pull/932>`__)
- [documentation] HTML documentation builds are now tested for errors (`#902 <https://github.com/gorakhargosh/watchdog/pull/902>`__)
- [documentation] Fix typos here, and there (`#910 <https://github.com/gorakhargosh/watchdog/pull/910>`__)
- [fsevents2] The ``fsevents2`` observer is now deprecated (`#909 <https://github.com/gorakhargosh/watchdog/pull/909>`__)
- [tests] The error message returned by musl libc for error code ``-1`` is now allowed (`#923 <https://github.com/gorakhargosh/watchdog/pull/923>`__)
- [utils] Remove unnecessary code in ``dirsnapshot.py`` (`#930 <https://github.com/gorakhargosh/watchdog/pull/930>`__)
- [watchmedo] Handle shutdown events from ``SIGHUP`` (`#912 <https://github.com/gorakhargosh/watchdog/pull/912>`__)
- Thanks to our beloved contributors: @kurtmckee, @babymastodon, @QuantumEnergyE, @timgates42, @BoboTiG
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants