huggingface-hub 0.34.0rc0__tar.gz → 0.34.2__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.

Potentially problematic release.


This version of huggingface-hub might be problematic. Click here for more details.

Files changed (173) hide show
  1. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/PKG-INFO +1 -1
  2. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/__init__.py +1 -1
  3. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/_local_folder.py +1 -1
  4. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/_oauth.py +5 -9
  5. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/cli/auth.py +3 -0
  6. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/cli/cache.py +4 -0
  7. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/cli/hf.py +2 -5
  8. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/cli/jobs.py +3 -0
  9. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/cli/repo.py +4 -0
  10. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/file_download.py +10 -8
  11. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub.egg-info/PKG-INFO +1 -1
  12. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/LICENSE +0 -0
  13. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/MANIFEST.in +0 -0
  14. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/README.md +0 -0
  15. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/pyproject.toml +0 -0
  16. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/setup.cfg +0 -0
  17. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/setup.py +0 -0
  18. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/_commit_api.py +0 -0
  19. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/_commit_scheduler.py +0 -0
  20. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/_inference_endpoints.py +0 -0
  21. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/_jobs_api.py +0 -0
  22. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/_login.py +0 -0
  23. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/_snapshot_download.py +0 -0
  24. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/_space_api.py +0 -0
  25. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/_tensorboard_logger.py +0 -0
  26. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/_upload_large_folder.py +0 -0
  27. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/_webhooks_payload.py +0 -0
  28. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/_webhooks_server.py +0 -0
  29. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/cli/__init__.py +0 -0
  30. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/cli/_cli_utils.py +0 -0
  31. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/cli/download.py +0 -0
  32. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/cli/lfs.py +0 -0
  33. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/cli/repo_files.py +0 -0
  34. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/cli/system.py +0 -0
  35. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/cli/upload.py +0 -0
  36. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/cli/upload_large_folder.py +0 -0
  37. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/commands/__init__.py +0 -0
  38. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/commands/_cli_utils.py +0 -0
  39. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/commands/delete_cache.py +0 -0
  40. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/commands/download.py +0 -0
  41. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/commands/env.py +0 -0
  42. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/commands/huggingface_cli.py +0 -0
  43. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/commands/lfs.py +0 -0
  44. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/commands/repo.py +0 -0
  45. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/commands/repo_files.py +0 -0
  46. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/commands/scan_cache.py +0 -0
  47. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/commands/tag.py +0 -0
  48. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/commands/upload.py +0 -0
  49. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/commands/upload_large_folder.py +0 -0
  50. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/commands/user.py +0 -0
  51. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/commands/version.py +0 -0
  52. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/community.py +0 -0
  53. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/constants.py +0 -0
  54. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/dataclasses.py +0 -0
  55. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/errors.py +0 -0
  56. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/fastai_utils.py +0 -0
  57. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/hf_api.py +0 -0
  58. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/hf_file_system.py +0 -0
  59. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/hub_mixin.py +0 -0
  60. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/inference/__init__.py +0 -0
  61. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/inference/_client.py +0 -0
  62. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/inference/_common.py +0 -0
  63. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/inference/_generated/__init__.py +0 -0
  64. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/inference/_generated/_async_client.py +0 -0
  65. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/inference/_generated/types/__init__.py +0 -0
  66. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/inference/_generated/types/audio_classification.py +0 -0
  67. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/inference/_generated/types/audio_to_audio.py +0 -0
  68. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/inference/_generated/types/automatic_speech_recognition.py +0 -0
  69. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/inference/_generated/types/base.py +0 -0
  70. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/inference/_generated/types/chat_completion.py +0 -0
  71. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/inference/_generated/types/depth_estimation.py +0 -0
  72. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/inference/_generated/types/document_question_answering.py +0 -0
  73. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/inference/_generated/types/feature_extraction.py +0 -0
  74. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/inference/_generated/types/fill_mask.py +0 -0
  75. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/inference/_generated/types/image_classification.py +0 -0
  76. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/inference/_generated/types/image_segmentation.py +0 -0
  77. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/inference/_generated/types/image_to_image.py +0 -0
  78. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/inference/_generated/types/image_to_text.py +0 -0
  79. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/inference/_generated/types/image_to_video.py +0 -0
  80. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/inference/_generated/types/object_detection.py +0 -0
  81. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/inference/_generated/types/question_answering.py +0 -0
  82. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/inference/_generated/types/sentence_similarity.py +0 -0
  83. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/inference/_generated/types/summarization.py +0 -0
  84. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/inference/_generated/types/table_question_answering.py +0 -0
  85. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/inference/_generated/types/text2text_generation.py +0 -0
  86. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/inference/_generated/types/text_classification.py +0 -0
  87. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/inference/_generated/types/text_generation.py +0 -0
  88. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/inference/_generated/types/text_to_audio.py +0 -0
  89. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/inference/_generated/types/text_to_image.py +0 -0
  90. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/inference/_generated/types/text_to_speech.py +0 -0
  91. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/inference/_generated/types/text_to_video.py +0 -0
  92. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/inference/_generated/types/token_classification.py +0 -0
  93. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/inference/_generated/types/translation.py +0 -0
  94. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/inference/_generated/types/video_classification.py +0 -0
  95. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/inference/_generated/types/visual_question_answering.py +0 -0
  96. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/inference/_generated/types/zero_shot_classification.py +0 -0
  97. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/inference/_generated/types/zero_shot_image_classification.py +0 -0
  98. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/inference/_generated/types/zero_shot_object_detection.py +0 -0
  99. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/inference/_mcp/__init__.py +0 -0
  100. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/inference/_mcp/_cli_hacks.py +0 -0
  101. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/inference/_mcp/agent.py +0 -0
  102. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/inference/_mcp/cli.py +0 -0
  103. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/inference/_mcp/constants.py +0 -0
  104. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/inference/_mcp/mcp_client.py +0 -0
  105. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/inference/_mcp/types.py +0 -0
  106. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/inference/_mcp/utils.py +0 -0
  107. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/inference/_providers/__init__.py +0 -0
  108. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/inference/_providers/_common.py +0 -0
  109. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/inference/_providers/black_forest_labs.py +0 -0
  110. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/inference/_providers/cerebras.py +0 -0
  111. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/inference/_providers/cohere.py +0 -0
  112. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/inference/_providers/fal_ai.py +0 -0
  113. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/inference/_providers/featherless_ai.py +0 -0
  114. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/inference/_providers/fireworks_ai.py +0 -0
  115. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/inference/_providers/groq.py +0 -0
  116. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/inference/_providers/hf_inference.py +0 -0
  117. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/inference/_providers/hyperbolic.py +0 -0
  118. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/inference/_providers/nebius.py +0 -0
  119. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/inference/_providers/novita.py +0 -0
  120. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/inference/_providers/nscale.py +0 -0
  121. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/inference/_providers/openai.py +0 -0
  122. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/inference/_providers/replicate.py +0 -0
  123. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/inference/_providers/sambanova.py +0 -0
  124. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/inference/_providers/together.py +0 -0
  125. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/inference_api.py +0 -0
  126. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/keras_mixin.py +0 -0
  127. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/lfs.py +0 -0
  128. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/py.typed +0 -0
  129. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/repocard.py +0 -0
  130. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/repocard_data.py +0 -0
  131. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/repository.py +0 -0
  132. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/serialization/__init__.py +0 -0
  133. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/serialization/_base.py +0 -0
  134. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/serialization/_dduf.py +0 -0
  135. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/serialization/_tensorflow.py +0 -0
  136. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/serialization/_torch.py +0 -0
  137. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/templates/datasetcard_template.md +0 -0
  138. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/templates/modelcard_template.md +0 -0
  139. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/utils/__init__.py +0 -0
  140. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/utils/_auth.py +0 -0
  141. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/utils/_cache_assets.py +0 -0
  142. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/utils/_cache_manager.py +0 -0
  143. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/utils/_chunk_utils.py +0 -0
  144. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/utils/_datetime.py +0 -0
  145. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/utils/_deprecation.py +0 -0
  146. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/utils/_dotenv.py +0 -0
  147. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/utils/_experimental.py +0 -0
  148. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/utils/_fixes.py +0 -0
  149. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/utils/_git_credential.py +0 -0
  150. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/utils/_headers.py +0 -0
  151. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/utils/_hf_folder.py +0 -0
  152. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/utils/_http.py +0 -0
  153. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/utils/_lfs.py +0 -0
  154. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/utils/_pagination.py +0 -0
  155. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/utils/_paths.py +0 -0
  156. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/utils/_runtime.py +0 -0
  157. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/utils/_safetensors.py +0 -0
  158. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/utils/_subprocess.py +0 -0
  159. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/utils/_telemetry.py +0 -0
  160. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/utils/_typing.py +0 -0
  161. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/utils/_validators.py +0 -0
  162. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/utils/_xet.py +0 -0
  163. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/utils/_xet_progress_reporting.py +0 -0
  164. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/utils/endpoint_helpers.py +0 -0
  165. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/utils/insecure_hashlib.py +0 -0
  166. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/utils/logging.py +0 -0
  167. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/utils/sha.py +0 -0
  168. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub/utils/tqdm.py +0 -0
  169. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub.egg-info/SOURCES.txt +0 -0
  170. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub.egg-info/dependency_links.txt +0 -0
  171. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub.egg-info/entry_points.txt +0 -0
  172. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub.egg-info/requires.txt +0 -0
  173. {huggingface_hub-0.34.0rc0 → huggingface_hub-0.34.2}/src/huggingface_hub.egg-info/top_level.txt +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: huggingface_hub
3
- Version: 0.34.0rc0
3
+ Version: 0.34.2
4
4
  Summary: Client library to download and publish models, datasets and other repos on the huggingface.co hub
5
5
  Home-page: https://github.com/huggingface/huggingface_hub
6
6
  Author: Hugging Face, Inc.
@@ -46,7 +46,7 @@ import sys
46
46
  from typing import TYPE_CHECKING
47
47
 
48
48
 
49
- __version__ = "0.34.0.rc0"
49
+ __version__ = "0.34.2"
50
50
 
51
51
  # Alphabetical order of definitions is ensured in tests
52
52
  # WARNING: any comment added in this dictionary definition will be lost when
@@ -90,7 +90,7 @@ class LocalDownloadFilePaths:
90
90
  resolved_path = str(path.resolve())
91
91
  # Some Windows versions do not allow for paths longer than 255 characters.
92
92
  # In this case, we must specify it as an extended path by using the "\\?\" prefix.
93
- if len(resolved_path) > 255 and not resolved_path.startswith("\\\\?\\"):
93
+ if os.name == "nt" and len(resolved_path) > 255 and not resolved_path.startswith("\\\\?\\"):
94
94
  path = Path("\\\\?\\" + resolved_path)
95
95
  return path
96
96
 
@@ -6,7 +6,7 @@ import time
6
6
  import urllib.parse
7
7
  import warnings
8
8
  from dataclasses import dataclass
9
- from typing import TYPE_CHECKING, Dict, List, Optional, Tuple, Union
9
+ from typing import TYPE_CHECKING, Dict, List, Literal, Optional, Tuple, Union
10
10
 
11
11
  from . import constants
12
12
  from .hf_api import whoami
@@ -39,10 +39,8 @@ class OAuthOrgInfo:
39
39
  Whether the org has a payment method set up. Hugging Face field.
40
40
  role_in_org (`Optional[str]`, *optional*):
41
41
  The user's role in the org. Hugging Face field.
42
- pending_sso (`Optional[bool]`, *optional*):
43
- Indicates if the user granted the OAuth app access to the org but didn't complete SSO. Hugging Face field.
44
- missing_mfa (`Optional[bool]`, *optional*):
45
- Indicates if the user granted the OAuth app access to the org but didn't complete MFA. Hugging Face field.
42
+ security_restrictions (`Optional[List[Literal["ip", "token-policy", "mfa", "sso"]]]`, *optional*):
43
+ Array of security restrictions that the user hasn't completed for this org. Possible values: "ip", "token-policy", "mfa", "sso". Hugging Face field.
46
44
  """
47
45
 
48
46
  sub: str
@@ -52,8 +50,7 @@ class OAuthOrgInfo:
52
50
  is_enterprise: bool
53
51
  can_pay: Optional[bool] = None
54
52
  role_in_org: Optional[str] = None
55
- pending_sso: Optional[bool] = None
56
- missing_mfa: Optional[bool] = None
53
+ security_restrictions: Optional[List[Literal["ip", "token-policy", "mfa", "sso"]]] = None
57
54
 
58
55
 
59
56
  @dataclass
@@ -221,8 +218,7 @@ def parse_huggingface_oauth(request: "fastapi.Request") -> Optional[OAuthInfo]:
221
218
  is_enterprise=org.get("isEnterprise"),
222
219
  can_pay=org.get("canPay"),
223
220
  role_in_org=org.get("roleInOrg"),
224
- pending_sso=org.get("pendingSSO"),
225
- missing_mfa=org.get("missingMFA"),
221
+ security_restrictions=org.get("securityRestrictions"),
226
222
  )
227
223
  for org in orgs_data
228
224
  ]
@@ -62,6 +62,9 @@ class AuthCommands(BaseHuggingfaceCLICommand):
62
62
  auth_parser = parser.add_parser("auth", help="Manage authentication (login, logout, etc.).")
63
63
  auth_subparsers = auth_parser.add_subparsers(help="Authentication subcommands")
64
64
 
65
+ # Show help if no subcommand is provided
66
+ auth_parser.set_defaults(func=lambda args: auth_parser.print_help())
67
+
65
68
  # Add 'login' as a subcommand of 'auth'
66
69
  login_parser = auth_subparsers.add_parser(
67
70
  "login", help="Log in using a token from huggingface.co/settings/tokens"
@@ -65,6 +65,10 @@ class CacheCommand(BaseHuggingfaceCLICommand):
65
65
  def register_subcommand(parser: _SubParsersAction):
66
66
  cache_parser = parser.add_parser("cache", help="Manage local cache directory.")
67
67
  cache_subparsers = cache_parser.add_subparsers(dest="cache_command", help="Cache subcommands")
68
+
69
+ # Show help if no subcommand is provided
70
+ cache_parser.set_defaults(func=lambda args: cache_parser.print_help())
71
+
68
72
  # Scan subcommand
69
73
  scan_parser = cache_subparsers.add_parser("scan", help="Scan cache directory.")
70
74
  scan_parser.add_argument(
@@ -47,10 +47,6 @@ def main():
47
47
  # LFS commands (hidden in --help)
48
48
  LfsCommands.register_subcommand(commands_parser)
49
49
 
50
- # Legacy commands
51
-
52
- # Experimental
53
-
54
50
  # Let's go
55
51
  args = parser.parse_args()
56
52
  if not hasattr(args, "func"):
@@ -59,7 +55,8 @@ def main():
59
55
 
60
56
  # Run
61
57
  service = args.func(args)
62
- service.run()
58
+ if service is not None:
59
+ service.run()
63
60
 
64
61
 
65
62
  if __name__ == "__main__":
@@ -58,6 +58,9 @@ class JobsCommands(BaseHuggingfaceCLICommand):
58
58
  jobs_parser = parser.add_parser("jobs", help="Run and manage Jobs on the Hub.")
59
59
  jobs_subparsers = jobs_parser.add_subparsers(help="huggingface.co jobs related commands")
60
60
 
61
+ # Show help if no subcommand is provided
62
+ jobs_parser.set_defaults(func=lambda args: jobs_parser.print_help())
63
+
61
64
  # Register commands
62
65
  InspectCommand.register_subcommand(jobs_subparsers)
63
66
  LogsCommand.register_subcommand(jobs_subparsers)
@@ -43,6 +43,10 @@ class RepoCommands(BaseHuggingfaceCLICommand):
43
43
  def register_subcommand(parser: _SubParsersAction):
44
44
  repo_parser = parser.add_parser("repo", help="Manage repos on the Hub.")
45
45
  repo_subparsers = repo_parser.add_subparsers(help="huggingface.co repos related commands")
46
+
47
+ # Show help if no subcommand is provided
48
+ repo_parser.set_defaults(func=lambda args: repo_parser.print_help())
49
+
46
50
  # CREATE
47
51
  repo_create_parser = repo_subparsers.add_parser("create", help="Create a new repo on huggingface.co")
48
52
  repo_create_parser.add_argument(
@@ -317,9 +317,6 @@ def _get_file_length_from_http_response(response: requests.Response) -> Optional
317
317
 
318
318
  This function extracts the file size from the HTTP response headers, either from the
319
319
  `Content-Range` or `Content-Length` header, if available (in that order).
320
- The HTTP response object containing the headers.
321
- `int` or `None`: The length of the file in bytes if the information is available,
322
- otherwise `None`.
323
320
 
324
321
  Args:
325
322
  response (`requests.Response`):
@@ -329,6 +326,15 @@ def _get_file_length_from_http_response(response: requests.Response) -> Optional
329
326
  `int` or `None`: The length of the file in bytes, or None if not available.
330
327
  """
331
328
 
329
+ # If HTTP response contains compressed body (e.g. gzip), the `Content-Length` header will
330
+ # contain the length of the compressed body, not the uncompressed file size.
331
+ # And at the start of transmission there's no way to know the uncompressed file size for gzip,
332
+ # thus we return None in that case.
333
+ content_encoding = response.headers.get("Content-Encoding", "identity").lower()
334
+ if content_encoding != "identity":
335
+ # gzip/br/deflate/zstd etc
336
+ return None
337
+
332
338
  content_range = response.headers.get("Content-Range")
333
339
  if content_range is not None:
334
340
  return int(content_range.rsplit("/")[-1])
@@ -422,11 +428,7 @@ def http_get(
422
428
  )
423
429
 
424
430
  hf_raise_for_status(r)
425
- content_length = _get_file_length_from_http_response(r)
426
-
427
- # NOTE: 'total' is the total number of bytes to download, not the number of bytes in the file.
428
- # If the file is compressed, the number of bytes in the saved file will be higher than 'total'.
429
- total = resume_size + int(content_length) if content_length is not None else None
431
+ total: Optional[int] = _get_file_length_from_http_response(r)
430
432
 
431
433
  if displayed_filename is None:
432
434
  displayed_filename = url
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: huggingface-hub
3
- Version: 0.34.0rc0
3
+ Version: 0.34.2
4
4
  Summary: Client library to download and publish models, datasets and other repos on the huggingface.co hub
5
5
  Home-page: https://github.com/huggingface/huggingface_hub
6
6
  Author: Hugging Face, Inc.