diff --git a/.github/commands.json b/.github/commands.json index 38da97915a..2d8c21b0da 100644 --- a/.github/commands.json +++ b/.github/commands.json @@ -261,7 +261,7 @@ "action": "close", "reason": "not_planned", "addLabel": "*caused-by-extension", - "comment": "It looks like this is caused by the Jupyter extension. Please file the issue to the [Jupyter extension repository](https://github.com/microsoft/vscode-jupyter). Make sure to check their issue reporting template and provide them relevant information such as the extension version you're using. See also our [issue reporting guidelines](https://aka.ms/vscodeissuereporting) for more information.\n\nHappy Coding!" + "comment": "It looks like this is caused by the Jupyter extension. Please file the issue to the [Jupyter extension repository](https://github.com/deepnote/vscode-deepnote). Make sure to check their issue reporting template and provide them relevant information such as the extension version you're using. See also our [issue reporting guidelines](https://aka.ms/vscodeissuereporting) for more information.\n\nHappy Coding!" }, { "type": "comment", diff --git a/.github/endgame_plan.md b/.github/endgame_plan.md deleted file mode 100644 index 8c243d4ade..0000000000 --- a/.github/endgame_plan.md +++ /dev/null @@ -1,115 +0,0 @@ -* [Endgame Template](https://github.com/microsoft/vscode-jupyter/blob/main/.github/endgame_plan.md) - -## Thursday -- [ ] Ensure that any CI test failures have issues assigned to that area's owner. -- [ ] Work with the build champ to drive the build to green by fixing/disabling tests or pinging area owners to do so. - -## Friday -- [ ] Review [Component Governance](https://dev.azure.com/monacotools/Monaco/_componentGovernance/191876) (Click on "microsoft/vscode-jupyter" on that page) and resolve all High/Severe issues. - - [ ] Focus on resolving `Critical` and `High` priority issues as others will be addressed in the `debt` week. - - [ ] Manually add any repository dependencies (if you can't add manually, refer [here](https://docs.opensource.microsoft.com/tools/cg/features/cgmanifest/)). Only add a cgmanifest.json if the components are not NPM or are not dev only. - Instructions on updating `npm` dependencies in `package.json` & `package-lock.json` can be found [here](https://github.com/microsoft/vscode-jupyter/wiki/Resolving-Component-Governance-and-Dependabot-issues-(updating-package-lock.json)). -- [ ] Create new release branch with format `release/release-YYYY.MM`. - * Note: The release branch is now ready for to be published (or hotfixed) -- [ ] Back on the `main` branch, bump the version in `package.json`. - - [ ] The version number will be the next monthly ("YYYY.M.0") version number (e.g. if the latest is `2022.2.0`, bump it to `2022.3.0`). - - [ ] `npm install` to update `package-lock.json` as well - -## Monday (Debt/Release week) -- [ ] Obtain VS Code [stable RC](https://builds.code.visualstudio.com/builds/stable) for sanity testing -- [ ] Manually run the [Stable pipeline](https://dev.azure.com/monacotools/Monaco/_build?definitionId=284) against the `release/release-YYYY.MM` branch - - Enable `Publish Extension`, you do not need an approval to build the VSIX. - - DO NOT ask for approval for the extension publish step, this step should only be done after sanity testing is done and ready to release. -- [ ] Sanity test release candidate VSIX against VS Code RC - Tip: You can use the dev containers in the this repo for testing against linux (just open the repo and use thd command `Dev Containers: Reopen in Container`) - - [ ] Windows - - [ ] win32-x64 - - [ ] win32-arm64 - - [ ] macOS - - [ ] darwin-x64 - - [ ] darwin-arm64 - - [ ] Linux - - [ ] linux-arm64 - - [ ] linux-armhf - - [ ] linux-x64 - - [ ] alpine-arm64 - - [ ] alpine-x64 -- [ ] Test web by going to insiders.vscode.dev and test the latest pre-release of jupyter -- [ ] Candidate bug fixes found from sanity test should be checked into `main` and cherry-picked to `release` branch - - After a candidate fix is merged, a pre-release build can be released by manually running [the pre-release devops pipeline](https://dev.azure.com/monacotools/Monaco/_build?definitionId=283) against the release branch. - -### Satelite extensions/npm packages -- [ ] Reach out to the owners of each of these to coordinate the releases (if any). - - If there are no releases for each of the following, then mark them as done. - - Else the ownsers of each to mark as done when they are done. -- [ ] JupyterHub (@DonJayamanne) - - No need to pin VS Code engine - - Release directly from main branch ([pipeline](https://dev.azure.com/monacotools/Monaco/_build?definitionId=521&_a=summary)) - - PreRelease directly from main branch manually ([pipeline](https://dev.azure.com/monacotools/Monaco/_build?definitionId=520)) -- [ ] Jupyter (Notebook) Renderers (@DonJayamanne) - - No need to pin VS Code engine (unless you want to test something against VS Code insiders and not ship to stable users) - - Release directly from main branch ([pipeline](https://dev.azure.com/monacotools/Monaco/_build?definitionId=285)) -- [ ] Jupyter Powertoys (@DonJayamanne) - - No need to pin VS Code engine (unless you want to test something against VS Code insiders and not ship to stable users, e.g. depends on some new Jupyter Extension API) - - Release directly from main branch ([pipeline](https://dev.azure.com/monacotools/Monaco/_build?definitionId=305)) -- [ ] Jupyter Cell Tags (@rebornix) - - No need to pin VS Code engine - - Release directly from main branch ([pipeline](https://dev.azure.com/monacotools/Monaco/_build?definitionId=388)) -- [ ] Jupyter Slideshow (@rebornix) - - No need to pin VS Code engine - - Release directly from main branch ([pipeline](https://dev.azure.com/monacotools/Monaco/_build?definitionId=387)) -- [ ] Jupyter KeyMap (@rebornix) - - No need to pin VS Code engine - - Release directly from main branch ([pipeline](https://dev.azure.com/monacotools/Monaco/_build?definitionId=260)) -- [ ] Tensorboard (@DonJayamanne) - - No need to pin VS Code engine - - Release directly from main branch ([pipeline](https://dev.azure.com/monacotools/Monaco/_build?definitionId=531)) - - PreRelease directly from main branch manually ([pipeline](https://dev.azure.com/monacotools/Monaco/_build?definitionId=530)) -- [ ] zeromq-prebuilt (@DonJayamanne) - - Release directly from main branch ([pipeline](https://dev.azure.com/monacotools/Monaco/_build?definitionId=466)) - - Release by adding a git tag and pushing it upstream (e.g. 6.0.0-beta.16.8) - - Can test bundles by manually running and publishing releases to github releases (download and test the bundles manually from github releases) -- [ ] @vscode/zeromq (@DonJayamanne) - - To be done after relesing `zeromq-prebuilt` - - Release directly from main branch ([pipeline](https://dev.azure.com/monacotools/Monaco/_build?definitionId=469)) -- [ ] @vscode/jupyter-extension (@DonJayamanne) - - Release directly from main/relese branch ([pipeline](https://dev.azure.com/monacotools/Monaco/_build?definitionId=519&_a=summary)) -- [ ] Gather (@DonJayamanne) - - No need to pin VS Code engine - - Release directly from main branch ([pipeline](https://dev.azure.com/monacotools/Monaco/_build?definitionId=290)) - -## Tuesday -- [ ] Make sure [Component Governance](https://dev.azure.com/monacotools/Monaco/_componentGovernance/191876) is happy -- [ ] Release - - [ ] Verify the PR Pipeline on Github actions is green against the release branch. - - [ ] Approve the `Publish` stage of the last [Stable pipeline](https://dev.azure.com/monacotools/Monaco/_build?definitionId=284) that's successfully sanity tested. - - [ ] Ensure a tag with the released version number on the commit that was released was created. - * This step occurs in the `Publish` Stage of the stable pipeline linked above. - - [ ] If any steps were unclear or changed in this endgame plan please update the `endgame_plan.md` file to make it clear for the next release - -## Wednesday/Thursday (Day of VS Code releasing the next insider version) -- [ ] Bump the engines.vscode version on the `main` branch to point to the next version. For example, from `1.58.0` to `1.59.0` - -## As needed -- [ ] Determine if a hotfix is needed - - Use the same `release/release-YYYY.MM` branch -- [ ] Ensure the version in package.json is updated as follows: - * If released version is `YYYY.MM.0`, then hot fix will be `YYYY.MM.1` - * If released version is `YYYY.MM.1`, then hot fix will be `YYYY.MM.2` -- [ ] Verify all candidate issues -- [ ] Sanity test release candidate VSIX against VS Code RC - Tip: You can use the dev containers in the this repo for testing against linux (just open the repo and use thd command `Dev Containers: Reopen in Container`) - - [ ] Windows - - [ ] win32-x64 - - [ ] win32-arm64 - - [ ] macOS - - [ ] darwin-x64 - - [ ] darwin-arm64 - - [ ] Linux - - [ ] linux-arm64 - - [ ] linux-armhf - - [ ] linux-x64 - - [ ] alpine-arm64 - - [ ] alpine-x64 -- [ ] Ensure that another tag was created for the new version's commit. - * If a tag was not pushed, investigate in the `Publish` Stage of the stable pipeline linked above, and manually add one using: `git tag -a YYYY.MM -m YYYY.MM -s -f` diff --git a/.vscode/launch.json b/.vscode/launch.json index 7cce9db61d..9c47f90ff8 100644 --- a/.vscode/launch.json +++ b/.vscode/launch.json @@ -127,7 +127,7 @@ } }, { - // Run this first: https://github.com/microsoft/vscode-jupyter/blob/main/src/test/datascience/setupTestEnvs.cmd + // Run this first: https://github.com/deepnote/vscode-deepnote/blob/main/src/test/datascience/setupTestEnvs.cmd // Then specify either a grep below or mark a test as 'test.only' to run the test that's failing. "name": "Tests (Jupyter+Python Extension installed, *.vscode.test.ts)", "type": "extensionHost", diff --git a/.vscode/notebooks/CITestResults.ipynb b/.vscode/notebooks/CITestResults.ipynb deleted file mode 100644 index e9642a08a3..0000000000 --- a/.vscode/notebooks/CITestResults.ipynb +++ /dev/null @@ -1,385 +0,0 @@ -{ - "cells": [ - { - "cell_type": "markdown", - "metadata": {}, - "source": [ - "# Python dependencies" - ] - }, - { - "cell_type": "code", - "execution_count": null, - "metadata": {}, - "outputs": [], - "source": [ - "%pip install requests\n", - "%pip install pandas\n", - "%pip install datetime" - ] - }, - { - "cell_type": "markdown", - "metadata": {}, - "source": [ - "# Configuration\n", - "\n", - "Settings to be configured per individual. \n", - "\n", - "TODO: configure these settings outside of the notebook so they don't mess with source control. (environment variables?)" - ] - }, - { - "cell_type": "code", - "execution_count": null, - "metadata": {}, - "outputs": [], - "source": [ - "try:\n", - " with open('.github_token', 'r') as f:\n", - " authtoken = f.read()\n", - "except FileNotFoundError:\n", - " # get an auth token using the steps here: https://docs.github.com/en/authentication/keeping-your-account-and-data-secure/creating-a-personal-access-token\n", - " authtoken = input('Please enter your GitHub token: ')\n", - " with open('.github_token', 'w') as f:\n", - " f.write(authtoken)" - ] - }, - { - "cell_type": "code", - "execution_count": null, - "metadata": {}, - "outputs": [], - "source": [ - "import os\n", - "\n", - "resultsDownloadLocation = 'c:\\\\temp\\\\testResults'\n", - "if (not os.path.exists(resultsDownloadLocation)):\n", - " os.makedirs(resultsDownloadLocation)\n" - ] - }, - { - "cell_type": "markdown", - "metadata": {}, - "source": [ - "# Retrieving Data\n", - "\n", - "The github action \"Aggregate Test Results\" runs daily and collects all the results for the previous day into a single json file.\n", - "\n", - "These steps will:\n", - "\n", - "- Find the last 50 runs (you can increase this if you want to look back further\n", - "- Download the artifacts from those runs into memory\n", - "- Write the .json file from within the artifact to disk (only if there isn't already an up to date file on disk)\n", - "- Load all results into a pandas DataFrame" - ] - }, - { - "cell_type": "code", - "execution_count": null, - "metadata": {}, - "outputs": [], - "source": [ - "import requests\n", - "\n", - "\n", - "def getRuns():\n", - " runsResponse = requests.get(\n", - " \"https://api.github.com/repos/microsoft/vscode-jupyter/actions/workflows/aggregate-test-results.yml/runs?per_page=50\",\n", - " headers={\n", - " \"Accept\": \"application/vnd.github+json\",\n", - " \"Authorization\": f\"Bearer {authtoken}\",\n", - " }, \n", - " )\n", - " \n", - " if runsResponse.status_code != 200:\n", - " print(f\"Error {runsResponse.status_code}\")\n", - " raise Exception(\"Error getting runs\")\n", - "\n", - " print(f\"Found {len(runsResponse.json()['workflow_runs'])} runs\")\n", - "\n", - " return runsResponse.json()[\"workflow_runs\"]\n", - "\n", - "runs = getRuns()" - ] - }, - { - "cell_type": "code", - "execution_count": null, - "metadata": {}, - "outputs": [], - "source": [ - "from datetime import datetime\n", - "\n", - "alreadyDownloaded = {}\n", - "for file in os.listdir(resultsDownloadLocation):\n", - " path = os.path.join(resultsDownloadLocation, file)\n", - " lastModified = datetime.fromtimestamp(os.path.getmtime(path))\n", - " alreadyDownloaded[file] = lastModified\n", - "\n", - "print(f\"Already downloaded {len(alreadyDownloaded)} result files, they will be skipped unless there is a newer version\")\n", - "\n", - "def shouldDownload(name, timestamp):\n", - " fileDate = datetime.strptime(timestamp, \"%Y-%m-%dT%H:%M:%SZ\")\n", - " if name in alreadyDownloaded:\n", - " if alreadyDownloaded[name] >= fileDate:\n", - " return False\n", - " \n", - " alreadyDownloaded[name] = fileDate\n", - " return True\n", - " " - ] - }, - { - "cell_type": "code", - "execution_count": null, - "metadata": {}, - "outputs": [], - "source": [ - "import io\n", - "import json\n", - "import zipfile\n", - "\n", - "\n", - "def getArtifactData(id):\n", - " testResultsResponse = requests.get(\n", - " f\"https://api.github.com/repos/microsoft/vscode-jupyter/actions/artifacts/{id}/zip\",\n", - " headers={\n", - " \"Accept\": \"application/vnd.github+json\",\n", - " \"Authorization\": f\"Bearer {authtoken}\",\n", - " },\n", - " )\n", - "\n", - " if testResultsResponse.status_code != 200:\n", - " print(f\"Error {testResultsResponse.status_code} getting artifact {id}\")\n", - "\n", - " return testResultsResponse.content\n", - "\n", - "def saveResultsFile(zipData, timeStamp):\n", - " with zipfile.ZipFile(io.BytesIO(zipData)) as artifact:\n", - " for name in artifact.namelist():\n", - " print(f'checking {name} at {timeStamp}')\n", - " if shouldDownload(name, timeStamp):\n", - " content = artifact.read(name)\n", - " print(f\" saving {name}\")\n", - " with open(f'{resultsDownloadLocation}\\\\{name}', 'wb') as f:\n", - " f.write(content) \n", - "\n", - "print(f\"Getting artifacts from {len(runs)} runs\")\n", - "for run in runs:\n", - " artifactUrl = run[\"artifacts_url\"]\n", - " print(f\"Getting artifacts from {artifactUrl} from {run['created_at']}\")\n", - " artifactsResponse = requests.get(\n", - " artifactUrl, headers={\n", - " \"Accept\": \"application/vnd.github+json\",\n", - " \"Authorization\": f\"Bearer {authtoken}\",\n", - " }\n", - " )\n", - "\n", - " if artifactsResponse.status_code != 200:\n", - " print(f\"Error {artifactsResponse.status_code} getting artifact {id}\")\n", - " else:\n", - " artifacts = artifactsResponse.json()[\"artifacts\"]\n", - " for artifact in artifacts:\n", - " rawData = getArtifactData(artifact[\"id\"])\n", - " testRunResults = saveResultsFile(rawData, run[\"created_at\"])" - ] - }, - { - "cell_type": "code", - "execution_count": null, - "metadata": {}, - "outputs": [], - "source": [ - "from datetime import datetime, timedelta\n", - "\n", - "import pandas as pd\n", - "\n", - "testResults = []\n", - "for file in os.listdir(resultsDownloadLocation):\n", - " path = f'{resultsDownloadLocation}\\\\{file}'\n", - " if datetime.fromtimestamp(os.path.getmtime(path)) < datetime.now() - timedelta(days=50):\n", - " # limit the amount of results we load\n", - " continue\n", - "\n", - " with open(path, 'r') as f:\n", - " try:\n", - " df = pd.read_json(f)\n", - " testResults.append(df)\n", - " except Exception as e:\n", - " print(f'Error reading {file}: {e}')\n", - "\n", - "df = pd.concat(testResults)\n", - "# strip off the time to help grouping, but keep as datetime type\n", - "df[\"datetime\"] = pd.to_datetime(df[\"date\"])\n", - "df[\"date\"] = pd.to_datetime(df[\"date\"]).dt.date\n", - "\n", - "print(f\"{len(df)} test results collected between {df['date'].min()} and {df['date'].max()}\")\n", - "\n", - "df.head()" - ] - }, - { - "cell_type": "markdown", - "metadata": {}, - "source": [ - "# Reporting" - ] - }, - { - "cell_type": "code", - "execution_count": null, - "metadata": {}, - "outputs": [], - "source": [ - "from datetime import date, timedelta\n", - "\n", - "recentFailures = df[df['date'] > date.today() - timedelta(days=7)]\n", - "recentFailures = recentFailures[recentFailures['status'] == 'failed'].dropna()\n", - "# recentFailures = recentFailures[recentFailures['scenario'] != 'TestLogs-raw-nonConda-3.10---windows-latest']\n", - "recentFailures = recentFailures.groupby(['testName', 'suite']).agg(failureCount=('testName', 'count'))\n", - "\n", - "recentFailures.sort_values(by=['failureCount', 'suite'], ascending=False).head(20)" - ] - }, - { - "cell_type": "markdown", - "metadata": {}, - "source": [ - "## Failure of a specific test" - ] - }, - { - "cell_type": "code", - "execution_count": null, - "metadata": {}, - "outputs": [], - "source": [ - "testName= 'Cells from python files and the input box are executed in correct order'\n", - "\n", - "testData = df.where(df['testName'] == testName).dropna()\n", - "passes = testData.where(testData['status'] == 'passed').dropna()\n", - "fails = testData.where(testData['status'] == 'failed').dropna()\n", - "successRate = len(passes) / (len(passes) + len(fails))\n", - "print(f\"'{testName}' failed {len(fails)} times between {testData['date'].min()} and {testData['date'].max()}\")\n", - "print(f\"Success rate: {successRate}\")\n", - "\n", - "testData['fail'] = testData['status'] == 'failed'\n", - "testData['pass'] = testData['status'] == 'passed'\n", - "\n", - "passfailcounts = testData.groupby(['date']).sum()\n", - "\n", - "passfailcounts.sort_values(by=['date'], ascending=False).head(15)\n", - "\n", - "# line chart not working\n", - "# import matplotlib.pyplot as plt\n", - "# ax=testData.plot(kind='line', x='date', y='pass', color='Green')\n", - "\n", - "# ax2=testData.plot(kind='line', x='date', y='fail', secondary_y=True,color='Red', ax=ax)\n", - "\n", - "# ax.set_ylabel('Passes')\n", - "# ax2.set_ylabel('Failures')\n", - "# plt.tight_layout()\n", - "# plt.show()" - ] - }, - { - "cell_type": "code", - "execution_count": null, - "metadata": {}, - "outputs": [], - "source": [ - "failures = testData.where(testData['status'] == 'failed').dropna()\n", - "failures = failures[['date', 'status', 'scenario', 'runUrl']].sort_values(by=['date'], ascending=False).head(10)\n", - "\n", - "failureMessage = ''\n", - "for index, row in failures.iterrows():\n", - " print(f\"{row['date']} - {row['scenario']}\\n{row['runUrl']}\")\n", - " failureMessage += f\"{row['date']} - {row['scenario']}\\n{row['runUrl']}\"" - ] - }, - { - "cell_type": "code", - "execution_count": null, - "metadata": {}, - "outputs": [], - "source": [ - "import io\n", - "from urllib import request\n", - "\n", - "\n", - "# post to create new github issue\n", - "def createIssue(title, body):\n", - " print(\"Creating issue for \" + title)\n", - " url = 'https://api.github.com/repos/microsoft/vscode-jupyter/issues'\n", - " data = {\n", - " 'title': title,\n", - " 'body': body,\n", - " 'labels': ['flaky test']\n", - " }\n", - " headers = {\n", - " \"Accept\": \"application/vnd.github+json\",\n", - " \"Authorization\": f\"Bearer {authtoken}\",\n", - " }\n", - " data = json.dumps(data).encode('utf-8')\n", - " req = request.Request(url, data=data, headers=headers, method='POST')\n", - " response = request.urlopen(req)\n", - " print(response.read().decode('utf-8'))" - ] - }, - { - "cell_type": "code", - "execution_count": null, - "metadata": {}, - "outputs": [], - "source": [ - "import ipywidgets as widgets\n", - "\n", - "chk = widgets.Checkbox(\n", - " value=False,\n", - " description='Create issue on github?',\n", - " disabled=False,\n", - " indent=False\n", - ")\n", - "display(chk)" - ] - }, - { - "cell_type": "code", - "execution_count": null, - "metadata": {}, - "outputs": [], - "source": [ - "if (chk.value):\n", - " createIssue(f\"Test failure: {testName}\", failureMessage)" - ] - } - ], - "metadata": { - "kernelspec": { - "display_name": ".venv3", - "language": "python", - "name": "python3" - }, - "language_info": { - "codemirror_mode": { - "name": "ipython", - "version": 3 - }, - "file_extension": ".py", - "mimetype": "text/x-python", - "name": "python", - "nbconvert_exporter": "python", - "pygments_lexer": "ipython3", - "version": "3.9.13" - }, - "orig_nbformat": 4, - "vscode": { - "interpreter": { - "hash": "05cadb55cbb23d0d156eeac1bfe39405b391b4fa73e06b1a6140e7007eb56649" - } - } - }, - "nbformat": 4, - "nbformat_minor": 2 -} diff --git a/.vscode/notebooks/GithubLabels.ipynb b/.vscode/notebooks/GithubLabels.ipynb index 8dfc0ba84a..6d58e1d4a0 100644 --- a/.vscode/notebooks/GithubLabels.ipynb +++ b/.vscode/notebooks/GithubLabels.ipynb @@ -74,7 +74,7 @@ } ], "source": [ - "repo_jupyter = g.get_repo('microsoft/vscode-jupyter')\n", + "repo_jupyter = g.get_repo('deepnote/vscode-deepnote')\n", "\n", "for l in repo_jupyter.get_labels():\n", " if (l.color == 'c5def5'):\n", @@ -114,7 +114,7 @@ } ], "source": [ - "repo_jupyter_internal = g.get_repo('microsoft/vscode-jupyter-internal')\n", + "repo_jupyter_internal = g.get_repo('deepnote/vscode-deepnote-internal')\n", "\n", "for l in repo_jupyter_internal.get_labels():\n", " if (l.color == 'c5def5'):\n", diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 7804b104c3..f7ea61f258 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -5,7 +5,7 @@ | `main` branch | | ------------- | -## | ![Main Build](https://github.com/microsoft/vscode-jupyter/actions/workflows/build-test.yml/badge.svg?branch=main) +## | ![Main Build](https://github.com/deepnote/vscode-deepnote/actions/workflows/ci.yml/badge.svg?branch=main) [For contributing to the [Microsoft Python Language Server](https://github.com/Microsoft/python-language-server) see its own repo; for [Pylance](https://github.com/microsoft/pylance-release) see its own repo; for [debugpy](https://github.com/microsoft/debugpy) see its own repo] @@ -19,16 +19,16 @@ 4. Windows, macOS, or Linux 5. [Visual Studio Code](https://code.visualstudio.com/) 6. The following VS Code extensions: - - [ESLint](https://marketplace.visualstudio.com/items?itemName=dbaeumer.vscode-eslint) - - [Prettier](https://marketplace.visualstudio.com/items?itemName=esbenp.prettier-vscode) - - [EditorConfig for VS Code](https://marketplace.visualstudio.com/items?itemName=EditorConfig.EditorConfig) - - [Python Extension for VS Code](https://marketplace.visualstudio.com/items?itemName=ms-python.python) + - [ESLint](https://marketplace.visualstudio.com/items?itemName=dbaeumer.vscode-eslint) + - [Prettier](https://marketplace.visualstudio.com/items?itemName=esbenp.prettier-vscode) + - [EditorConfig for VS Code](https://marketplace.visualstudio.com/items?itemName=EditorConfig.EditorConfig) + - [Python Extension for VS Code](https://marketplace.visualstudio.com/items?itemName=ms-python.python) ### Setup ```shell -git clone https://github.com/microsoft/vscode-jupyter -cd vscode-jupyter +git clone https://github.com/deepnote/vscode-deepnote +cd vscode-deepnote ``` @@ -47,6 +47,7 @@ Then install all the extensions listed under "Workspace Recommendations". The `@deepnote/blocks` package is published on GitHub Packages. To install it, you'll need to authenticate with GitHub: 1. Create a GitHub Personal Access Token (classic) with `read:packages` scope: + - Go to https://github.com/settings/tokens - Click "Generate new token (classic)" - Select the `read:packages` scope @@ -178,8 +179,8 @@ you can do this by setting environment variables. The same variables work when running from the command line or launching from within VSCode, though the mechanism used to specify them changes a little. -- Setting `CI_PYTHON_PATH` lets you change the version of python the tests are executed with -- Setting `VSC_JUPYTER_CI_TEST_GREP` lets you filter the tests by name +- Setting `CI_PYTHON_PATH` lets you change the version of python the tests are executed with +- Setting `VSC_JUPYTER_CI_TEST_GREP` lets you filter the tests by name _`CI_PYTHON_PATH`_ @@ -201,7 +202,7 @@ be matched against suite and test "names" to be run. By default all tests are run. For example, to run only the tests in the `DataScience - Kernels Finder` suite (from -[`src/test/datascience/kernel-launcher/kernelFinder.vscode.test.ts`](https://github.com/microsoft/vscode-jupyter/blob/269e0790f9ef6f1571140f0650c6b5fb844f1940/src/test/datascience/kernel-launcher/kernelFinder.vscode.test.ts)) +[`src/test/datascience/kernel-launcher/kernelFinder.vscode.test.ts`](https://github.com/deepnote/vscode-deepnote/blob/269e0790f9ef6f1571140f0650c6b5fb844f1940/src/test/datascience/kernel-launcher/kernelFinder.vscode.test.ts)) you would set the value to `Kernels Finder`. Be sure to escape any grep-sensitive characters in your suite name. @@ -209,7 +210,7 @@ Be sure to escape any grep-sensitive characters in your suite name. In some rare cases in the "system" tests the `VSC_JUPYTER_CI_TEST_GREP` environment variable is ignored. If that happens then you will need to temporarily modify the `const defaultGrep =` line in -[`src/test/index.ts`](https://github.com/microsoft/vscode-jupyter/blob/de1bfe1cbebc0f4e570dc4ae7e1ca057abb0533e/src/test/index.ts#L62). +[`src/test/index.ts`](https://github.com/deepnote/vscode-deepnote/blob/de1bfe1cbebc0f4e570dc4ae7e1ca057abb0533e/src/test/index.ts#L62). _Launching from VSCode_ @@ -239,8 +240,8 @@ VSC_JUPYTER_CI_TEST_GREP=Sorting npm run testVSCode The extension has a number of scripts in ./pythonFiles. Tests for these scripts are found in ./pythonFiles/tests. To run those tests: -- `python2.7 pythonFiles/tests/run_all.py` -- `python3 -m pythonFiles.tests` +- `python2.7 pythonFiles/tests/run_all.py` +- `python3 -m pythonFiles.tests` By default, functional tests are included. To exclude them: @@ -269,7 +270,7 @@ well! ### Folder Structure -At a high level we have a bunch of folders. Each high level is described in this wiki [page](https://github.com/microsoft/vscode-jupyter/wiki/Source-Code-Organization) +At a high level we have a bunch of folders. Each high level is described in this wiki [page](https://github.com/deepnote/vscode-deepnote/wiki/Source-Code-Organization) ### Typical workflow @@ -282,16 +283,16 @@ Here's an example of a typical workflow: 1. Start VS code Insiders root 1. CTRL+SHIFT+B (run the task `compile`) 1. Make code changes -1. Write and [run](https://github.com/microsoft/vscode-jupyter/blob/29c4be79f64df1858692321b43c3079bb77bdd69/.vscode/launch.json#L252) unit tests if appropriate -1. Test with [`Extension`](https://github.com/microsoft/vscode-jupyter/blob/29c4be79f64df1858692321b43c3079bb77bdd69/.vscode/launch.json#L6) launch task +1. Write and [run](https://github.com/deepnote/vscode-deepnote/blob/29c4be79f64df1858692321b43c3079bb77bdd69/.vscode/launch.json#L252) unit tests if appropriate +1. Test with [`Extension`](https://github.com/deepnote/vscode-deepnote/blob/29c4be79f64df1858692321b43c3079bb77bdd69/.vscode/launch.json#L6) launch task 1. Repeat until works in normal extension -1. Test with [`Extension (web)`](https://github.com/microsoft/vscode-jupyter/blob/29c4be79f64df1858692321b43c3079bb77bdd69/.vscode/launch.json#L34) launch task -1. Run [jupyter notebook server](https://github.com/microsoft/vscode-jupyter/wiki/Connecting-to-a-remote-Jupyter-server-from-vscode.dev) to use in web testing +1. Test with [`Extension (web)`](https://github.com/deepnote/vscode-deepnote/blob/29c4be79f64df1858692321b43c3079bb77bdd69/.vscode/launch.json#L34) launch task +1. Run [jupyter notebook server](https://github.com/deepnote/vscode-deepnote/wiki/Connecting-to-a-remote-Jupyter-server-from-vscode.dev) to use in web testing 1. Repeat until works in web extension -1. Write integration tests and [run](https://github.com/microsoft/vscode-jupyter/blob/29c4be79f64df1858692321b43c3079bb77bdd69/.vscode/launch.json#L216) locally. +1. Write integration tests and [run](https://github.com/deepnote/vscode-deepnote/blob/29c4be79f64df1858692321b43c3079bb77bdd69/.vscode/launch.json#L216) locally. 1. Submit PR 1. Check PR output to make sure tests don't fail. -1. Debug [CI test failures](https://github.com/microsoft/vscode-jupyter/wiki/Tests) +1. Debug [CI test failures](https://github.com/deepnote/vscode-deepnote/wiki/Tests) ### Helping others @@ -321,7 +322,7 @@ All development is actively done in the `main` branch of the repository. This allows us to have a [development build](#development-build) which is expected to be stable at all times. Once we reach a release candidate, it becomes -our [release branch](https://github.com/microsoft/vscode-jupyter/branches). +our [release branch](https://github.com/deepnote/vscode-deepnote/branches). At that point only what is in the release branch will make it into the next release. diff --git a/api/package.json b/api/package.json index d6ff233f0a..2441717673 100644 --- a/api/package.json +++ b/api/package.json @@ -12,13 +12,13 @@ ], "types": "api.d.ts", "license": "MIT", - "homepage": "https://github.com/microsoft/vscode-jupyter", + "homepage": "https://github.com/deepnote/vscode-deepnote", "repository": { "type": "git", - "url": "https://github.com/Microsoft/vscode-jupyter" + "url": "https://github.com/deepnote/vscode-deepnote" }, "bugs": { - "url": "https://github.com/Microsoft/vscode-jupyter/issues" + "url": "https://github.com/deepnote/vscode-deepnote/issues" }, "scripts": { "buildStable": "npm run clean && node ./stable.js", diff --git a/build/verifyProposedApiUsage.ts b/build/verifyProposedApiUsage.ts index 50921b3253..ff57f33c0e 100644 --- a/build/verifyProposedApiUsage.ts +++ b/build/verifyProposedApiUsage.ts @@ -22,7 +22,7 @@ async function getPackageJsonInMainBranch( tag: string ): Promise<{ enabledApiProposals: string[]; engines: { vscode: string } }> { // If we can find the latest tag, thats even better. - const url = `https://raw.githubusercontent.com/microsoft/vscode-jupyter/${tag}/package.json`; + const url = `https://raw.githubusercontent.com/deepnote/vscode-deepnote/${tag}/package.json`; const response = await fetch(url); return await response.json(); } diff --git a/pythonFiles/aggregateTestResults.py b/pythonFiles/aggregateTestResults.py index 728aac4aa8..24d0b26092 100644 --- a/pythonFiles/aggregateTestResults.py +++ b/pythonFiles/aggregateTestResults.py @@ -14,7 +14,7 @@ # %% def getRuns(createdDate): runsResponse = requests.get( - "https://api.github.com/repos/microsoft/vscode-jupyter/actions/workflows/build-test.yml/runs", + "https://api.github.com/repos/deepnote/vscode-deepnote/actions/workflows/ci.yml/runs", params={"created": createdDate, "branch": "main"}, headers={ "Accept": "application/vnd.github+json", @@ -36,7 +36,7 @@ def getRuns(createdDate): def getArtifactData(id): testResultsResponse = requests.get( - f"https://api.github.com/repos/microsoft/vscode-jupyter/actions/artifacts/{id}/zip", + f"https://api.github.com/repos/deepnote/vscode-deepnote/actions/artifacts/{id}/zip", headers={ "Accept": "application/vnd.github+json", "Authorization": f"Bearer {authtoken}", diff --git a/pythonFiles/vscode_datascience_helpers/kernel/addRunCellHook.py b/pythonFiles/vscode_datascience_helpers/kernel/addRunCellHook.py index c7237da305..0a1393f057 100644 --- a/pythonFiles/vscode_datascience_helpers/kernel/addRunCellHook.py +++ b/pythonFiles/vscode_datascience_helpers/kernel/addRunCellHook.py @@ -8,7 +8,7 @@ # This function computes the hash for the code. It must follow the same algorithm as in use here: -# https://github.com/microsoft/vscode-jupyter/blob/312511f3cbd8b2bb5bc70fa9b771429e22d0c258/src/client/datascience/editor-integration/cellhashprovider.ts#L181 +# https://github.com/deepnote/vscode-deepnote/blob/312511f3cbd8b2bb5bc70fa9b771429e22d0c258/src/client/datascience/editor-integration/cellhashprovider.ts#L181 def __VSCODE_compute_hash(code, number=0): hash_digest = _VSCODE_hashlib.sha1(code.encode("utf-8")).hexdigest() return "".format(number, hash_digest[:12]) diff --git a/src/platform/common/utils/localize.ts b/src/platform/common/utils/localize.ts index 3d34f5f221..82d3aa0f78 100644 --- a/src/platform/common/utils/localize.ts +++ b/src/platform/common/utils/localize.ts @@ -519,7 +519,7 @@ export namespace DataScience { ); export const jupyterDebuggerOutputParseError = (output: string) => l10n.t( - 'Unable to parse {0} output, please log an issue with https://github.com/microsoft/vscode-jupyter', + 'Unable to parse {0} output, please log an issue with https://github.com/deepnote/vscode-deepnote', output ); export const cellStopOnErrorMessage = l10n.t('Cell was canceled due to an error in a previous cell.'); diff --git a/src/test/datascience/notebook/withMixedMimeTypeOutput.ipynb b/src/test/datascience/notebook/withMixedMimeTypeOutput.ipynb index 6c7dbfb948..05fc9ccd07 100644 --- a/src/test/datascience/notebook/withMixedMimeTypeOutput.ipynb +++ b/src/test/datascience/notebook/withMixedMimeTypeOutput.ipynb @@ -179,7 +179,7 @@ ], "source": [ "from IPython.core.display import Image, display\n", - "display(Image('https://raw.githubusercontent.com/microsoft/vscode-jupyter/main/icon.png'))" + "display(Image('https://raw.githubusercontent.com/deepnote/vscode-deepnote/main/icon.png'))" ] }, { diff --git a/src/test/standalone/api/unstable/api.jupyterProvider.vscode.test.ts b/src/test/standalone/api/unstable/api.jupyterProvider.vscode.test.ts index febaf2afa6..1792d57041 100644 --- a/src/test/standalone/api/unstable/api.jupyterProvider.vscode.test.ts +++ b/src/test/standalone/api/unstable/api.jupyterProvider.vscode.test.ts @@ -45,6 +45,7 @@ suite('Jupyter Provider Tests', function () { } if (IS_CONDA_TEST()) { // Due to upstream issue documented here https://github.com/microsoft/vscode-jupyter/issues/14338 + // Note: This issue was closed in Dec 2023. This skip may no longer be necessary and should be tested. return this.skip(); } this.timeout(120_000);