Spaces:
Running
Running
| title: GitHub Notebook Fixer | |
| emoji: π§ | |
| colorFrom: blue | |
| colorTo: indigo | |
| sdk: gradio | |
| sdk_version: "6.9.0" | |
| app_file: app.py | |
| pinned: false | |
| license: mit | |
| short_description: Fix .ipynb files that show "Invalid Notebook" on GitHub | |
| # π§ GitHub Notebook Fixer | |
| Upload a `.ipynb` notebook and this Space will: | |
| 1. **Predict** if it will render on GitHub or fail | |
| 2. **Diagnose** every issue (missing widget state, oversized outputs, bad metadata) | |
| 3. **Return a fixed `.ipynb`** ready to push | |
| ## Why do notebooks break on GitHub? | |
| The most common cause is **Google Colab saving widget metadata without the required `state` key**. GitHub's nbconvert renderer requires `metadata.widgets["application/vnd.jupyter.widget-state+json"]["state"]` to exist β if it doesn't, you get the dreaded: | |
| > **Invalid Notebook** β the 'state' key is missing from 'metadata.widgets' | |
| Other causes include oversized cell outputs (>500 KB), giant base64 images, and missing `kernelspec` metadata. | |
| ## How to use | |
| 1. Upload your `.ipynb` file | |
| 2. Click **Analyze & Fix** | |
| 3. Read the diagnosis report | |
| 4. Download the fixed notebook | |
| 5. Push to GitHub β it will render! | |
| ## π Privacy & Data | |
| **Your files are never stored.** | |
| - Your `.ipynb` file is read **in memory** only β it never touches a database or persistent storage. | |
| - A short-lived OS temp file is created so you can download the fixed notebook, then it is automatically deleted. | |
| - No personal information, file content, or usage data is logged or shared with third parties. | |
| - Once your session ends, every trace of your file is gone. | |
| ## Run locally | |
| ```bash | |
| pip install gradio | |
| python app.py | |
| ``` | |