- HfApi doesn't have search_models method
- Use list_models instead with search parameter
- Fix 'HfApi' object has no attribute 'search_models' error
- Update parameter names to match list_models API
- Add try/catch around API info calls
- Try ModelCard first, then API fallback, then minimal info
- Better error messages and logging
- Prevent complete failure when one method fails
- Always return some model info instead of errors
- Change from .utils to ..utils for resolve_huggingface_api_key
- utils.py is directly in server/ not in server/utils/
- Fix 'No module named server.routes.utils' error
- Restore button functionality
- Change from ..utils to .utils for resolve_huggingface_api_key
- Fix import errors that were breaking extension
- All routes now import from correct location
- Restore button functionality
- Add try/except for relative imports
- Fallback to absolute imports for testing
- Fix import errors that were breaking the extension
- Restore button functionality
- Set nsfw=True as default value
- Users don't need to enable it every time
- Can still be disabled by setting nsfw=false
- Better user experience for model discovery
- Remove complex Civitai-style logic
- Use huggingface_hub ModelCard to read model cards
- Extract base_model, tags, license from YAML frontmatter
- Get description from model card text
- Much cleaner and more accurate for HuggingFace models
- Use HuggingFace API to get popular base models
- Add common base models like SDXL, SD1.5, FLUX
- Keep hardcoded list as fallback
- Better base model filtering for search
- Don't construct URL when target_filename is None
- Let huggingface_hub handle repo downloads
- Prevent 404 errors with resolve/main/None
- Better handling for repo vs file downloads
- Add proper handling for target_filename = None
- Use model name as folder name for repo downloads
- Prevent TypeError when os.path.basename(None)
- Better logic for repo vs file downloads
- Skip API calls for public repos entirely
- Use API only for private repos to get model info
- Always use huggingface_hub for downloads
- Let huggingface_hub auto-detect files
- Much cleaner and more reliable approach
- When HF API fails to find model info, use parsed name from model_id
- Added debug output for fallback path
- This handles cases where HF models don't have proper model cards
- Ensures model name is always available even for obscure models
- Updated all HuggingFace routes to use /api/huggingface/ prefix
- This fixes 405 Method Not Allowed errors for all endpoints
- Frontend and backend paths now match consistently
- All API calls should work correctly now
- Changed route from /huggingface/get_model_details to /api/huggingface/get_model_details
- This fixes the 405 Method Not Allowed error
- Frontend was calling /api/ but route was registered without /api/
- Now frontend and backend paths match
- Added debug output for direct download path
- Shows when model name is extracted from model_id
- Helps identify why model name might not be set correctly
- More comprehensive debugging for direct download scenario
- Added debug output for response data huggingface_model_name
- Will show what name is being sent to frontend
- Helps identify if frontend receives the correct model name
- More comprehensive debugging for model name issue
- Added JSON parsing for model_info when it's a string
- Backend was sending model_info as JSON string instead of dict
- Now correctly extracts 'name' field from parsed JSON
- This should fix the model name display issue
- Added debug output for response data model_name
- Will show what name is being sent to frontend
- Helps identify if parsing works but frontend doesn't display it
- More comprehensive debugging for model name issue
- Added detailed debug output for model_info and target_model_id
- Shows which path is taken for name extraction
- Will help identify why model name parsing fails
- Debug output will show the final model_display_name
1. Fixed placeholder image paths to be relative to JS file location
2. Enhanced model name extraction from model_id when API fails
3. Now shows 'wan2.2-2-Remix' instead of 'Unknown Model'
4. All paths now work correctly for ComfyUI serving
Final fixes for complete functionality!
1. Changed placeholder paths to relative './' instead of absolute
2. Enhanced model name parsing to use model_info['name'] when available
3. Fallback to model_id parsing for better display names
4. Should show 'wan2.2-Remix' instead of 'Unknown Model' when possible
1. Force single connection for HF downloads (like Civitai)
2. Placeholder image already configured correctly
3. Extract model name from model_id (e.g. 'wan2.2-Remix' from 'FX-FeiHou/wan2.2-Remix')
4. Better display names in status and UI
More reliable and user-friendly downloads!
- Updated all references to use 'HF token' instead of 'API Key'
- Clarified that token is only for private repositories
- Updated environment variable name to HUGGINGFACE_TOKEN
- More accurate documentation of token purpose
- Added get_model_version_info() method for compatibility
- Added 'url' field to download_info for ChunkDownloader
- This should fix both the AttributeError and 'Invalid URL None' errors
- Downloads should now work properly with huggingface_hub fallback
- Changed response status from 'started' to 'queued'
- Frontend expects 'queued' to show download in status tab
- This ensures downloads appear in the queue visualization
- Auto-open status tab should now work correctly
- Use parsed_filename instead of hardcoded 'model.safetensors'
- This ensures the full path from URL is used
- Fixes 'Invalid URL None' error
- Direct downloads should now work with proper file paths
- Added output_path field to download_info dict
- ChunkDownloader requires output_path parameter
- This was causing TypeError: NoneType error
- Download should now work properly
- DownloadManager uses add_to_queue() not start_download()
- This was causing AttributeError
- Download should now start properly
- Fixed method call to match actual DownloadManager API
- Skip model info/file listing for direct URLs
- Fallback to direct download when API fails
- Handle models that don't support tree endpoint
- This should fix the 404 errors for Wan 2.2 models
- Direct downloads should now work without API dependencies
- Replaced CIVITAI_API_KEY with HUGGINGFACE_API_KEY
- Removed select_primary_file import (not implemented for HF)
- Added simple file selection logic for HF
- Fixed utils.py imports and function calls
- Updated JavaScript references
This should restore the HuggingFace button in ComfyUI
- Rewrote parse_huggingface_input() for HF URLs
- Support direct download URLs with /resolve/main/
- Simplified DownloadModel.py for HF API
- Proper model ID extraction (username/repo format)
- File selection logic for .safetensors or largest file
- Fixed API calls to use correct HF endpoints
Should now handle URLs like:
https://huggingface.co/FX-FeiHou/wan2.2-Remix/resolve/main/NSFW/file.safetensors
- Renamed CIVITAI_API_TYPE_MAP to HUGGINGFACE_API_TYPE_MAP
- Updated all Python imports
- Fixed config.py variable name
- This should resolve the missing button issue by fixing imports
Extension should now load correctly in ComfyUI
- Updated all file references from placeholder.jpeg to placeholder.jpg
- Fixed JavaScript files
- Fixed Python files
- Fixed config.py
- Image now loads correctly in UI
This should fix missing placeholder images in the interface
- Replaced all remaining 'Civicomfy' references with 'HuggingFace'
- Updated JavaScript extension name and button text
- Fixed all UI component references
- Updated console logs and error messages
- Changed extension registration name
- Updated CSS and image paths
This should fix the missing button issue in ComfyUI
- Converted CivitaiAPI to HuggingFaceAPI
- Updated all references from civitai to huggingface
- Renamed web files (CSS/JS)
- Implemented core HF API methods:
* search_models()
* get_model_info()
* get_model_files()
* download_file()
- Clean API structure for HuggingFace integration
Next: Update server routes and helpers for HF endpoints