FEAT Uniformize `hf_api` a bit and add support for Spaces (#792)
* this was'nt used anymore, and is not listed in __init__ => just remove it
* Add `SpaceInfo` + refactor a bit
* just reorder methods
* `space_info`
* `list_repo_files` supports Spaces
* expose
* Add hf.co commit-sha header in anticipation of next PR
* prevent (very small IMO) potential BC
For me this is slightly less clean, but will defer to others
* new methods are `kwonly` by default
h/t @adrinjalali
Co-authored-by: Adrin Jalali <adrin.jalali@gmail.com>
* Table this header const for another PR
* Revert "prevent (very small IMO) potential BC"
This reverts commit 1d1ec51ac0818c3ccb7e3a320d6c1ec6ee6a71c3.
* Also expose those for consistency
* kwonly methods
* some docstrings
* docstring args
* Added documentation + missing decorators
* Decorators & style
* Address comments
* Address comments
Co-authored-by: Adrin Jalali <adrin.jalali@gmail.com>
* Wrap-up
* Patch test
* Revert token retrieval
* Apply suggestions from code review
Co-authored-by: Adrin Jalali <adrin.jalali@gmail.com>
* Documentation for kwargs
* Replace token retrieval
* Revert token retrieval
Co-authored-by: Adrin Jalali <adrin.jalali@gmail.com>
Co-authored-by: Lysandre Debut <lysandre.debut@reseau.eseo.fr>