|
1 | | -# Deepnote Extension for Visual Studio Code |
| 1 | +# Deepnote for Visual Studio Code |
| 2 | + |
| 3 | + |
2 | 4 |
|
3 | 5 | [](https://github.com/deepnote/vscode-deepnote/actions/workflows/ci.yml) |
4 | 6 | [](https://codecov.io/gh/deepnote/vscode-deepnote) |
| 7 | +[](https://opensource.org/licenses/MIT) |
| 8 | +[](https://marketplace.visualstudio.com/items?itemName=Deepnote.vscode-deepnote) |
| 9 | + |
| 10 | +A powerful [Visual Studio Code](https://code.visualstudio.com/) extension that brings [Deepnote](https://deepnote.com/) notebook capabilities directly into your favorite editor. Work with enhanced data science notebooks featuring SQL blocks, database integrations, and collaborative features - all within VS Code. |
5 | 11 |
|
6 | | -A [Visual Studio Code](https://code.visualstudio.com/) extension that provides support for [Deepnote notebooks](https://deepnote.com/) directly within VS Code. This extension allows you to work with Deepnote notebooks in VS Code, bringing the rich data science capabilities of Deepnote to your favorite editor. |
| 12 | +## 🚀 Features |
7 | 13 |
|
8 | 14 |  |
9 | 15 |
|
10 | | -This extension allows you to work with Deepnote notebooks in VS Code. Deepnote notebooks provide enhanced data science capabilities beyond traditional Jupyter notebooks: |
| 16 | +### Enhanced Notebook Experience |
| 17 | + |
| 18 | +Deepnote notebooks extend traditional Jupyter notebooks with powerful data science features: |
| 19 | + |
| 20 | +- **🔢 Multiple Block Types** - Work with Python code, SQL queries, Markdown documentation, and specialized data science blocks |
| 21 | +- **🔄 Seamless Language Switching** - Switch between Python and SQL within the same notebook without context switching |
| 22 | +- **🗄️ Database Integrations** - Connect directly to PostgreSQL, BigQuery, Snowflake, and other data sources with secure credential management |
| 23 | +- **⚡ Init Notebooks** - Automatically run initialization code (dependencies, environment setup) before notebook execution |
| 24 | +- **📦 Automatic Requirements** - Generate `requirements.txt` from your project settings for reproducible environments |
| 25 | +- **🎨 Rich Outputs** - View data visualizations, tables, and interactive outputs directly in VS Code |
| 26 | +- **🔐 Secure Credential Storage** - Safely store and manage database credentials using VS Code's encrypted SecretStorage API |
| 27 | + |
| 28 | +### Jupyter Kernel Support |
| 29 | + |
| 30 | +Built on top of robust Jupyter infrastructure: |
| 31 | + |
| 32 | +- **🐍 Python Kernel** - Full Python support with IPython features |
| 33 | +- **🔌 Custom Deepnote Kernel** - Enhanced kernel with Deepnote-specific features and integrations |
| 34 | +- **📊 Interactive Debugging** - Debug notebooks cell-by-cell with VS Code's debugger |
| 35 | +- **🔄 Kernel Management** - Easy kernel selection, restart, and interrupt capabilities |
| 36 | + |
| 37 | +### Project Management |
| 38 | + |
| 39 | +- **📁 Project Explorer** - Browse and manage Deepnote projects directly from VS Code's sidebar |
| 40 | +- **📓 Multi-Notebook Support** - Work with multiple notebooks from the same project |
| 41 | +- **🔍 Quick Navigation** - Jump between notebooks and files with command palette integration |
| 42 | +- **♻️ Auto-Refresh** - Automatic detection of project file changes |
| 43 | + |
| 44 | +## 📋 Requirements |
| 45 | + |
| 46 | +- **Visual Studio Code** 1.103.0 or higher |
| 47 | +- **Python** 3.8 or higher (for running notebooks) |
| 48 | +- **Node.js** 22.15.1 or higher (for development) |
| 49 | + |
| 50 | +## 🎯 Getting Started |
11 | 51 |
|
12 | | -- **More block types** - Choose from SQL blocks, chart blocks, and more specialized data science blocks |
13 | | -- **Seamless language switching** - Switch between Python and SQL seamlessly within the same notebook |
14 | | -- **Database integrations** - Connect directly to Postgres, Snowflake, BigQuery and more data sources |
15 | | -- **Init notebooks** - Automatically runs initialization code (like dependency installation) before your notebooks execute |
16 | | -- **Project requirements** - Automatically creates `requirements.txt` from your project settings for easy dependency management |
| 52 | +### Installation |
17 | 53 |
|
18 | | -## Useful commands |
| 54 | +1. Open VS Code |
| 55 | +2. Press `Ctrl+P` / `Cmd+P` to open Quick Open |
| 56 | +3. Type `ext install Deepnote.vscode-deepnote` |
| 57 | +4. Press Enter |
19 | 58 |
|
20 | | -Open the Command Palette (Command+Shift+P on macOS and Ctrl+Shift+P on Windows/Linux) and type in one of the following commands: |
| 59 | +Or install from the [VS Code Marketplace](https://marketplace.visualstudio.com/items?itemName=Deepnote.vscode-deepnote) |
| 60 | + |
| 61 | +### Opening Your First Deepnote Notebook |
| 62 | + |
| 63 | +1. Open a folder containing `.deepnote` project files |
| 64 | +2. Look for the Deepnote icon in the Activity Bar (sidebar) |
| 65 | +3. Click on a notebook in the Deepnote Explorer to open it |
| 66 | +4. Select a Python kernel when prompted |
| 67 | +5. Start coding! |
| 68 | + |
| 69 | +## 📖 Usage |
| 70 | + |
| 71 | +### Command Palette |
| 72 | + |
| 73 | +Open the Command Palette (`Cmd+Shift+P` on macOS, `Ctrl+Shift+P` on Windows/Linux) and type `Deepnote` to see all available commands: |
21 | 74 |
|
22 | 75 | | Command | Description | |
23 | 76 | | ---------------------------------- | -------------------------------------------------- | |
24 | 77 | | `Deepnote: Refresh Explorer` | Refresh the Deepnote project explorer | |
25 | 78 | | `Deepnote: Open Notebook` | Open a specific notebook from a Deepnote project | |
26 | 79 | | `Deepnote: Open File` | Open the raw .deepnote project file | |
27 | 80 | | `Deepnote: Reveal in Explorer` | Show active notebook information in the explorer | |
| 81 | +| `Deepnote: Manage Integrations` | Configure database connections and credentials | |
| 82 | +| `Deepnote: New Project` | Create a new Deepnote project | |
| 83 | +| `Deepnote: Import Notebook` | Import an existing notebook into your project | |
28 | 84 | | `Notebook: Select Notebook Kernel` | Select or switch kernels within your notebook | |
29 | 85 | | `Notebook: Change Cell Language` | Change the language of the cell currently in focus | |
30 | 86 |
|
31 | | -To see all available Deepnote commands, open the Command Palette and type `Deepnote`. |
| 87 | +### Database Integrations |
| 88 | + |
| 89 | +Configure database connections for SQL blocks: |
| 90 | + |
| 91 | +1. Open Command Palette |
| 92 | +2. Run `Deepnote: Manage Integrations` |
| 93 | +3. Add your database credentials (PostgreSQL, BigQuery, etc.) |
| 94 | +4. Use SQL blocks in your notebooks with the configured integrations |
| 95 | + |
| 96 | +Credentials are securely stored using VS Code's encrypted storage and never leave your machine. |
| 97 | + |
| 98 | +### Working with SQL Blocks |
| 99 | + |
| 100 | +SQL blocks allow you to query databases directly from your notebooks: |
| 101 | + |
| 102 | +```sql |
| 103 | +-- Query your PostgreSQL database |
| 104 | +SELECT * FROM users WHERE created_at > '2024-01-01' |
| 105 | +``` |
| 106 | + |
| 107 | +Results are displayed as interactive tables that you can explore and export. |
| 108 | + |
| 109 | +## 🛠️ Development |
| 110 | + |
| 111 | +Want to contribute? Check out our [Contributing Guide](CONTRIBUTING.md) for detailed setup instructions. |
| 112 | + |
| 113 | +### Quick Start for Developers |
| 114 | + |
| 115 | +```bash |
| 116 | +# Clone the repository |
| 117 | +git clone https://github.com/deepnote/vscode-deepnote.git |
| 118 | +cd vscode-deepnote |
| 119 | + |
| 120 | +# Install dependencies |
| 121 | +npm install |
| 122 | + |
| 123 | +# Setup pre-commit hooks |
| 124 | +npm run setup-precommit-hook |
| 125 | + |
| 126 | +# Compile and watch for changes |
| 127 | +npm run watch |
| 128 | + |
| 129 | +# Run tests |
| 130 | +npm run test:unittests |
| 131 | +``` |
| 132 | + |
| 133 | +See [CONTRIBUTING.md](CONTRIBUTING.md) for more details on: |
| 134 | +- Setting up your development environment |
| 135 | +- Running tests |
| 136 | +- Building the extension |
| 137 | +- Submitting pull requests |
| 138 | + |
| 139 | +## 📚 Documentation |
| 140 | + |
| 141 | +- **[Architecture](architecture.md)** - Technical architecture and design decisions |
| 142 | +- **[Deepnote Kernel Implementation](DEEPNOTE_KERNEL_IMPLEMENTATION.md)** - Details on the custom Jupyter kernel |
| 143 | +- **[Integrations & Credentials](INTEGRATIONS_CREDENTIALS.md)** - How database integrations work |
| 144 | +- **[Contributing Guide](CONTRIBUTING.md)** - How to contribute to the project |
| 145 | + |
| 146 | +## 🤝 Contributing |
| 147 | + |
| 148 | +We welcome contributions! Please see our [Contributing Guide](CONTRIBUTING.md) for details on: |
| 149 | + |
| 150 | +- Code of conduct |
| 151 | +- Development setup |
| 152 | +- Coding standards |
| 153 | +- Pull request process |
| 154 | +- Testing requirements |
| 155 | + |
| 156 | +## 📄 License |
| 157 | + |
| 158 | +This project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details. |
| 159 | + |
| 160 | +## 🐛 Issues & Support |
| 161 | + |
| 162 | +- **Bug Reports**: [GitHub Issues](https://github.com/deepnote/vscode-deepnote/issues) |
| 163 | +- **Feature Requests**: [GitHub Discussions](https://github.com/deepnote/vscode-deepnote/discussions) |
| 164 | +- **Questions**: [GitHub Discussions](https://github.com/deepnote/vscode-deepnote/discussions) |
| 165 | + |
| 166 | +## 🔗 Related Projects |
| 167 | + |
| 168 | +- [Deepnote](https://deepnote.com/) - Collaborative data science notebook platform |
| 169 | +- [Jupyter](https://jupyter.org/) - Open-source notebook ecosystem |
| 170 | +- [VS Code Python Extension](https://marketplace.visualstudio.com/items?itemName=ms-python.python) - Python language support for VS Code |
| 171 | + |
| 172 | +## 🌟 Keywords |
| 173 | + |
| 174 | +`deepnote` `jupyter` `notebook` `data-science` `python` `sql` `database` `postgresql` `bigquery` `vscode-extension` `data-analysis` `machine-learning` `interactive-computing` `ipython` `jupyter-notebook` `collaborative-notebooks` |
| 175 | + |
| 176 | +--- |
| 177 | + |
| 178 | +Made with ❤️ by the Deepnote team |
0 commit comments