Package Details: python-huggingface-hub 1:0.26.2-1

Git Clone URL: https://aur.archlinux.org/python-huggingface-hub.git (read-only, click to copy)
Package Base: python-huggingface-hub
Description: All the open source things related to the Hugging Face Hub
Upstream URL: https://github.com/huggingface/huggingface_hub
Licenses: Apache-2.0
Submitter: hottea
Maintainer: hottea (lilac)
Last Packager: lilac
Votes: 5
Popularity: 0.41
First Submitted: 2021-12-09 05:59 (UTC)
Last Updated: 2024-10-28 20:33 (UTC)

Sources (1)

Latest Comments

hottea commented on 2024-08-20 15:45 (UTC)

@Strykar You need to install https://aur.archlinux.org/packages/python-hf-transfer. and some other deps. see also the setup.py.

Strykar commented on 2024-08-20 13:52 (UTC)

Hi, thanks for maintaining this! My upstream tooling to manage models fails with "ModuleNotFoundError: No module named 'hf_transfer'". What's missing to add the equivalent of "pip install huggingface_hub[cli,hf_transfer]" to this PKGBUILD?

hottea commented on 2024-01-09 03:34 (UTC)

@dreieck For the first warning, report to upstream. I'll switch to PEP 517 as arch wiki describes.

dreieck commented on 2024-01-08 16:00 (UTC)

I get the following two warnings during build:

==> Starting build()...
[...]
writing manifest file 'src/huggingface_hub.egg-info/SOURCES.txt'
[01/08/24 16:57:38] ERROR    listing git files failed - pretending there aren't any                                                                 git.py:24
reading manifest file 'src/huggingface_hub.egg-info/SOURCES.txt'
reading manifest template 'MANIFEST.in'
adding license file 'LICENSE'
writing manifest file 'src/huggingface_hub.egg-info/SOURCES.txt'
/usr/lib/python3.11/site-packages/setuptools/command/build_py.py:207: _Warning: Package 'huggingface_hub.templates' is absent from the `packages` configuration.
!!

        ********************************************************************************
        ############################
        # Package would be ignored #
        ############################
        Python recognizes 'huggingface_hub.templates' as an importable package[^1],
        but it is absent from setuptools' `packages` configuration.

        This leads to an ambiguous overall configuration. If you want to distribute this
        package, please make sure that 'huggingface_hub.templates' is explicitly added
        to the `packages` configuration field.

        Alternatively, you can also rely on setuptools' discovery methods
        (for example by using `find_namespace_packages(...)`/`find_namespace:`
        instead of `find_packages(...)`/`find:`).

        You can read more about "package discovery" on setuptools documentation page:

        - https://setuptools.pypa.io/en/latest/userguide/package_discovery.html

        If you don't want 'huggingface_hub.templates' to be distributed and are
        already explicitly excluding 'huggingface_hub.templates' via
        `find_namespace_packages(...)/find_namespace` or `find_packages(...)/find`,
        you can try to use `exclude_package_data`, or `include-package-data=False` in
        combination with a more fine grained `package-data` configuration.

        You can read more about "package data files" on setuptools documentation page:

        - https://setuptools.pypa.io/en/latest/userguide/datafiles.html


        [^1]: For Python, any directory (with suitable naming) can be imported,
              even if it does not contain any `.py` files.
              On the other hand, currently there is no concept of package data
              directory, all directories are treated like packages.
        ********************************************************************************

!!
  check.warn(importable)
creating build/lib/huggingface_hub/templates
copying src/huggingface_hub/templates/datasetcard_template.md -> build/lib/huggingface_hub/templates
copying src/huggingface_hub/templates/modelcard_template.md -> build/lib/huggingface_hub/templates
==> Starting package()...
running install
/usr/lib/python3.11/site-packages/setuptools/_distutils/cmd.py:66: SetuptoolsDeprecationWarning: setup.py install is deprecated.
!!

        ********************************************************************************
        Please avoid running ``setup.py`` directly.
        Instead, use pypa/build, pypa/installer or other
        standards-based tools.

        See https://blog.ganssle.io/articles/2021/10/setup-py-deprecated.html for details.
        ********************************************************************************

!!
  self.initialize_options()
[...]

The second one tells that setup.py should no longet be called directly, but you should use python -m build and python -m installer instead (with appropriate make dependencies), as it is laid out in the Python Packaging Guidelines ArchWiki-page.

Regards and thanks for the package!

daskol commented on 2023-02-18 08:41 (UTC)

I think that depends or at least optdepends should be updated with git since the core API of huggingface-hub uses git to manage users' dataset or model repositories. Also, it would be great to describe other optional packages.

xiota commented on 2023-01-18 23:16 (UTC)

namcap reports the following missing dependencies: python-tensorflow, python-pytorch, and python-jinja

hottea commented on 2022-12-19 00:52 (UTC)

@daskol see here.

daskol commented on 2022-12-18 21:37 (UTC)

Why do you use epoch in PKGBUILD? It seems that it is not needed and breaks dependencies.