Skip to content

Commit 79a8470

Browse files
committed
Merge remote-tracking branch 'origin/main' into tomaskislan/deepnote-notebook-management
Signed-off-by: Tomas Kislan <[email protected]>
2 parents 81344ca + 71dffde commit 79a8470

File tree

88 files changed

+8895
-1107
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

88 files changed

+8895
-1107
lines changed

.devcontainer/dev-with-python/devcontainer.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@
3333

3434
"mounts": ["source=${localWorkspaceFolder},target=/workspaces/local,type=bind,consistency=cached"],
3535
// Use 'postCreateCommand' to run commands after the container is created.
36-
// "postCreateCommand": "npm ci",
36+
// "postCreateCommand": "npm install",
3737
// Comment out connect as root instead. More info: https://aka.ms/vscode-remote/containers/non-root.
3838
"remoteUser": "vscode"
3939
}

.devcontainer/dev/devcontainer.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919
},
2020
"mounts": ["source=${localWorkspaceFolder},target=/workspaces/local,type=bind,consistency=cached"]
2121
// Use 'postCreateCommand' to run commands after the container is created.
22-
// "postCreateCommand": "npm ci",
22+
// "postCreateCommand": "npm install",
2323
// Comment out connect as root instead. More info: https://aka.ms/vscode-remote/containers/non-root.
2424
// , "remoteUser": "vscode"
2525
}

.eslintrc.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@ module.exports = {
7474
'import/no-unresolved': [
7575
'error',
7676
{
77-
ignore: ['monaco-editor', 'vscode', 'error-boundary']
77+
ignore: ['monaco-editor', 'vscode', 'react-error-boundary']
7878
}
7979
],
8080
'import/prefer-default-export': 'off',

.github/CODEOWNERS

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
# Default owners for everything in the repository
2-
* @saltenasl @jamesbhobbs @Artmann @andyjakubowski
2+
* @deepnote/oss-maintainers

.github/actions/create-venv-for-tests/action.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ runs:
1616
using: 'composite'
1717
steps:
1818
- name: Install uv
19-
uses: astral-sh/setup-uv@d0cc045d04ccac9d8b7881df0226f9e82c39688e # v6
19+
uses: astral-sh/setup-uv@2ddd2b9cb38ad8efd50337e8ab201519a34c9f24 # v7
2020

2121
# Used by tests for installation of ipykernel.
2222
# Create a venv & register it as a kernel.

.github/workflows/ci.yml

Lines changed: 40 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,6 @@ on:
77
branches: [main]
88
workflow_dispatch:
99

10-
env:
11-
NODE_VERSION: 22.x
12-
1310
permissions:
1411
actions: read
1512
contents: read
@@ -29,10 +26,10 @@ jobs:
2926
uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5
3027

3128
- name: Setup Node.js
32-
uses: actions/setup-node@a0853c24544627f65ddf259abe73b1d18a591444 # v5
29+
uses: actions/setup-node@2028fbc5c25fe9cf00d9f06a71cc4710d4507903 # v6
3330
with:
3431
cache: 'npm'
35-
node-version: ${{ env.NODE_VERSION }}
32+
node-version-file: '.nvmrc'
3633
registry-url: 'https://npm.pkg.github.com'
3734
scope: '@deepnote'
3835

@@ -56,10 +53,10 @@ jobs:
5653
uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5
5754

5855
- name: Setup Node.js
59-
uses: actions/setup-node@a0853c24544627f65ddf259abe73b1d18a591444 # v5
56+
uses: actions/setup-node@2028fbc5c25fe9cf00d9f06a71cc4710d4507903 # v6
6057
with:
6158
cache: 'npm'
62-
node-version: ${{ env.NODE_VERSION }}
59+
node-version-file: '.nvmrc'
6360
registry-url: 'https://npm.pkg.github.com'
6461
scope: '@deepnote'
6562

@@ -78,10 +75,12 @@ jobs:
7875

7976
steps:
8077
- name: Checkout code
81-
uses: actions/checkout@ff7abcd0c3c05ccf6adc123a8cd1fd4fb30fb493
78+
uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5
79+
with:
80+
fetch-depth: 0
8281

8382
- name: Install qlty
84-
uses: qltysh/qlty-action/install@a19242102d17e497f437d7466aa01b528537e899
83+
uses: qltysh/qlty-action/install@92420f3093ba65970fed22ce5f162ecb8a5c1700
8584

8685
- name: Run qlty check
8786
run: qlty check
@@ -102,10 +101,10 @@ jobs:
102101
uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5
103102

104103
- name: Setup Node.js
105-
uses: actions/setup-node@a0853c24544627f65ddf259abe73b1d18a591444 # v5
104+
uses: actions/setup-node@2028fbc5c25fe9cf00d9f06a71cc4710d4507903 # v6
106105
with:
107106
cache: 'npm'
108-
node-version: ${{ env.NODE_VERSION }}
107+
node-version-file: '.nvmrc'
109108
registry-url: 'https://npm.pkg.github.com'
110109
scope: '@deepnote'
111110

@@ -152,10 +151,10 @@ jobs:
152151
uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5
153152

154153
- name: Setup Node.js
155-
uses: actions/setup-node@a0853c24544627f65ddf259abe73b1d18a591444 # v5
154+
uses: actions/setup-node@2028fbc5c25fe9cf00d9f06a71cc4710d4507903 # v6
156155
with:
157156
cache: 'npm'
158-
node-version: ${{ env.NODE_VERSION }}
157+
node-version-file: '.nvmrc'
159158
registry-url: 'https://npm.pkg.github.com'
160159
scope: '@deepnote'
161160

@@ -167,6 +166,30 @@ jobs:
167166
- name: Check Licenses
168167
run: npm run check-licenses
169168

169+
spell-check:
170+
name: Spell Check
171+
runs-on: ubuntu-latest
172+
timeout-minutes: 15
173+
steps:
174+
- name: Checkout
175+
uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5
176+
177+
- name: Setup Node.js
178+
uses: actions/setup-node@2028fbc5c25fe9cf00d9f06a71cc4710d4507903 # v6
179+
with:
180+
cache: 'npm'
181+
node-version-file: '.nvmrc'
182+
registry-url: 'https://npm.pkg.github.com'
183+
scope: '@deepnote'
184+
185+
- name: Install dependencies
186+
run: npm ci --prefer-offline --no-audit
187+
env:
188+
NODE_AUTH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
189+
190+
- name: Run spell check
191+
run: npm run spell-check
192+
170193
audit-prod:
171194
name: Audit - Production
172195
runs-on: ubuntu-latest
@@ -176,10 +199,10 @@ jobs:
176199
uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5
177200

178201
- name: Setup Node.js
179-
uses: actions/setup-node@a0853c24544627f65ddf259abe73b1d18a591444 # v5
202+
uses: actions/setup-node@2028fbc5c25fe9cf00d9f06a71cc4710d4507903 # v6
180203
with:
181204
cache: 'npm'
182-
node-version: ${{ env.NODE_VERSION }}
205+
node-version-file: '.nvmrc'
183206
registry-url: 'https://npm.pkg.github.com'
184207
scope: '@deepnote'
185208

@@ -200,10 +223,10 @@ jobs:
200223
uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5
201224

202225
- name: Setup Node.js
203-
uses: actions/setup-node@a0853c24544627f65ddf259abe73b1d18a591444 # v5
226+
uses: actions/setup-node@2028fbc5c25fe9cf00d9f06a71cc4710d4507903 # v6
204227
with:
205228
cache: 'npm'
206-
node-version: ${{ env.NODE_VERSION }}
229+
node-version-file: '.nvmrc'
207230
registry-url: 'https://npm.pkg.github.com'
208231
scope: '@deepnote'
209232

.github/workflows/copilot-setup-steps.yml

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,6 @@ on:
1212
- .github/workflows/copilot-setup-steps.yml
1313

1414
env:
15-
NODE_VERSION: 22.15.1
1615
NPM_VERSION: 10.9.2
1716
PYTHON_VERSION: 3.12
1817
DENO_VERSION: '~1.37'
@@ -40,9 +39,9 @@ jobs:
4039
uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5
4140

4241
- name: Use Node ${{env.NODE_VERSION}}
43-
uses: actions/setup-node@a0853c24544627f65ddf259abe73b1d18a591444 # v5
42+
uses: actions/setup-node@2028fbc5c25fe9cf00d9f06a71cc4710d4507903 # v6
4443
with:
45-
node-version: ${{env.NODE_VERSION}}
44+
node-version-file: '.nvmrc'
4645
registry-url: 'https://npm.pkg.github.com'
4746
scope: '@deepnote'
4847

@@ -79,7 +78,7 @@ jobs:
7978
continue-on-error: true
8079

8180
- name: Install uv
82-
uses: astral-sh/setup-uv@3259c6206f993105e3a61b142c2d97bf4b9ef83d # v7
81+
uses: astral-sh/setup-uv@2ddd2b9cb38ad8efd50337e8ab201519a34c9f24 # v7
8382

8483
- name: Setup Venv
8584
run: |

.github/workflows/deps.yml

Lines changed: 4 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,6 @@ on:
66
- cron: '0 9 * * 1'
77
workflow_dispatch:
88

9-
env:
10-
NODE_VERSION: 22.x
11-
129
permissions:
1310
actions: read
1411
contents: read
@@ -27,10 +24,10 @@ jobs:
2724
uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5
2825

2926
- name: Setup Node.js
30-
uses: actions/setup-node@a0853c24544627f65ddf259abe73b1d18a591444 # v5
27+
uses: actions/setup-node@2028fbc5c25fe9cf00d9f06a71cc4710d4507903 # v6
3128
with:
3229
cache: 'npm'
33-
node-version: ${{ env.NODE_VERSION }}
30+
node-version-file: '.nvmrc'
3431
registry-url: 'https://npm.pkg.github.com'
3532
scope: '@deepnote'
3633

@@ -60,9 +57,9 @@ jobs:
6057
uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5
6158

6259
- name: Setup Node.js
63-
uses: actions/setup-node@a0853c24544627f65ddf259abe73b1d18a591444 # v5
60+
uses: actions/setup-node@2028fbc5c25fe9cf00d9f06a71cc4710d4507903 # v6
6461
with:
65-
node-version: ${{ env.NODE_VERSION }}
62+
node-version-file: '.nvmrc'
6663
cache: 'npm'
6764

6865
- name: Install dependencies

.github/workflows/package.yml

Lines changed: 104 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,104 @@
1+
name: CD
2+
3+
on:
4+
push:
5+
branches: [main]
6+
pull_request:
7+
branches: [main]
8+
workflow_dispatch:
9+
10+
permissions:
11+
contents: read
12+
packages: read
13+
14+
concurrency:
15+
group: ${{ github.workflow }}-${{ github.ref }}
16+
cancel-in-progress: true
17+
18+
jobs:
19+
package:
20+
name: Build & Package Extension
21+
runs-on: ubuntu-latest
22+
timeout-minutes: 20
23+
steps:
24+
- name: Checkout
25+
uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5
26+
27+
- name: Setup Node.js
28+
uses: actions/setup-node@2028fbc5c25fe9cf00d9f06a71cc4710d4507903 # v6
29+
with:
30+
cache: 'npm'
31+
node-version-file: '.nvmrc'
32+
registry-url: 'https://npm.pkg.github.com'
33+
scope: '@deepnote'
34+
35+
- name: Install dependencies
36+
run: npm ci --prefer-offline --no-audit
37+
env:
38+
NODE_AUTH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
39+
40+
- name: Install vsce
41+
run: npm install -g @vscode/vsce
42+
43+
- name: Extract version from package.json
44+
id: package-version
45+
run: |
46+
VERSION=$(node -p "require('./package.json').version")
47+
echo "version=$VERSION" >> $GITHUB_OUTPUT
48+
echo "Extension version: $VERSION"
49+
50+
- name: Extract and sanitize branch name
51+
id: branch-name
52+
env:
53+
UNTRUSTED_HEAD_REF: ${{ github.head_ref }}
54+
EVENT_NAME: ${{ github.event_name }}
55+
run: |
56+
# Get branch name from ref (use env vars to avoid direct interpolation)
57+
if [[ "$EVENT_NAME" == "pull_request" ]]; then
58+
BRANCH="$UNTRUSTED_HEAD_REF"
59+
else
60+
BRANCH="${GITHUB_REF#refs/heads/}"
61+
fi
62+
# Sanitize branch name for filename (replace / with -)
63+
SAFE_BRANCH=$(printf '%s' "$BRANCH" | sed 's/\//-/g')
64+
printf 'branch=%s\n' "$SAFE_BRANCH" >> "$GITHUB_OUTPUT"
65+
printf 'Branch name: %s (sanitized: %s)\n' "$BRANCH" "$SAFE_BRANCH"
66+
67+
- name: Package extension
68+
run: npm run package
69+
70+
- name: Rename VSIX file
71+
run: |
72+
# The package script creates vscode-deepnote-insiders.vsix
73+
# Rename it to include version and branch
74+
mv vscode-deepnote-insiders.vsix "vscode-deepnote-${{ steps.package-version.outputs.version }}-${{ steps.branch-name.outputs.branch }}.vsix"
75+
ls -lh *.vsix
76+
77+
- name: Upload VSIX artifact
78+
uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4
79+
with:
80+
name: vscode-deepnote-${{ steps.package-version.outputs.version }}-${{ steps.branch-name.outputs.branch }}
81+
path: vscode-deepnote-*.vsix
82+
retention-days: 30
83+
if-no-files-found: error
84+
85+
- name: Add summary
86+
run: |
87+
echo "## 📦 Extension Packaged Successfully" >> $GITHUB_STEP_SUMMARY
88+
echo "" >> $GITHUB_STEP_SUMMARY
89+
echo "**Version:** ${{ steps.package-version.outputs.version }}" >> $GITHUB_STEP_SUMMARY
90+
echo "**Branch:** ${{ steps.branch-name.outputs.branch }}" >> $GITHUB_STEP_SUMMARY
91+
echo "" >> $GITHUB_STEP_SUMMARY
92+
echo "### Installation Instructions" >> $GITHUB_STEP_SUMMARY
93+
echo "1. Download the artifact from the Actions tab" >> $GITHUB_STEP_SUMMARY
94+
echo "2. Extract the .vsix file from the zip" >> $GITHUB_STEP_SUMMARY
95+
echo "3. Install in VS Code:" >> $GITHUB_STEP_SUMMARY
96+
echo " - Open VS Code" >> $GITHUB_STEP_SUMMARY
97+
echo " - Go to Extensions view (Ctrl+Shift+X / Cmd+Shift+X)" >> $GITHUB_STEP_SUMMARY
98+
echo " - Click the '...' menu → 'Install from VSIX...'" >> $GITHUB_STEP_SUMMARY
99+
echo " - Select the downloaded .vsix file" >> $GITHUB_STEP_SUMMARY
100+
echo "" >> $GITHUB_STEP_SUMMARY
101+
echo "Alternatively, use the command line:" >> $GITHUB_STEP_SUMMARY
102+
echo "\`\`\`bash" >> $GITHUB_STEP_SUMMARY
103+
echo "code --install-extension vscode-deepnote-${{ steps.package-version.outputs.version }}-${{ steps.branch-name.outputs.branch }}.vsix" >> $GITHUB_STEP_SUMMARY
104+
echo "\`\`\`" >> $GITHUB_STEP_SUMMARY

.husky/post-checkout

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
npm ci
1+
npm install

0 commit comments

Comments
 (0)