From ab5486614a94582c29c970d15bbde28e6b4ad942 Mon Sep 17 00:00:00 2001 From: Jeremy Tuloup Date: Thu, 15 Jul 2021 15:17:32 +0200 Subject: [PATCH 1/5] Add CHANGELOG.md --- CHANGELOG.md | 126 +++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 126 insertions(+) create mode 100644 CHANGELOG.md diff --git a/CHANGELOG.md b/CHANGELOG.md new file mode 100644 index 0000000..b8f9773 --- /dev/null +++ b/CHANGELOG.md @@ -0,0 +1,126 @@ +# Changelog + + + +## [v3.0.11-2](https://github.com/jupyterlab/galata/tree/v3.0.11-2) + +[Full Changelog](https://github.com/jupyterlab/galata/compare/v3.0.11-1...v3.0.11-2) + +### Changes + +- Bump postcss from 7.0.35 to 7.0.36 [\#64](https://github.com/jupyterlab/galata/pull/64) (@dependabot[bot]) +- increment version for 3.0.11-2 release [\#63](https://github.com/jupyterlab/galata/pull/63) (@mbektas) +- fix jlpm build output dir [\#62](https://github.com/jupyterlab/galata/pull/62) (@mbektas) +- Wait fixes [\#61](https://github.com/jupyterlab/galata/pull/61) (@mbektas) +- Allow for custom tab bar and nb toolbar item ids [\#48](https://github.com/jupyterlab/galata/pull/48) (@fcollonval) + + + +## [v3.0.11-1](https://github.com/jupyterlab/galata/tree/v3.0.11-1) + +[Full Changelog](https://github.com/jupyterlab/galata/compare/v3.0.7-7...v3.0.11-1) + +### Changes + +- Update to JupyterLab 3.0.11 and lerna [\#57](https://github.com/jupyterlab/galata/pull/57) (@jtpio) +- Update release instructions [\#56](https://github.com/jupyterlab/galata/pull/56) (@jtpio) +- Add linter [\#55](https://github.com/jupyterlab/galata/pull/55) (@fcollonval) + +## [v3.0.7-7](https://github.com/jupyterlab/galata/tree/v3.0.7-7) + +[Full Changelog](https://github.com/jupyterlab/galata/compare/v3.0.7-6...v3.0.7-7) + +### Changes + +- Update to 3.0.7-7 [\#52](https://github.com/jupyterlab/galata/pull/52) (@jtpio) +- Switch from npm to jlpm [\#50](https://github.com/jupyterlab/galata/pull/50) (@jtpio) +- Move the debugger sidebar to the left in moveAllTabsToLeft [\#45](https://github.com/jupyterlab/galata/pull/45) (@jtpio) + +## [v3.0.7-6](https://github.com/jupyterlab/galata/tree/v3.0.7-6) + +[Full Changelog](https://github.com/jupyterlab/galata/compare/v3.0.7-5...v3.0.7-6) + +### Changes + +- increment version for 3.0.7-6 release [\#44](https://github.com/jupyterlab/galata/pull/44) (@mbektas) +- fix notebook close issues [\#43](https://github.com/jupyterlab/galata/pull/43) (@mbektas) + +## [v3.0.7-5](https://github.com/jupyterlab/galata/tree/v3.0.7-5) + +[Full Changelog](https://github.com/jupyterlab/galata/compare/v3.0.7-4...v3.0.7-5) + +### Changes + +- increment version for 3.0.7-5 release [\#42](https://github.com/jupyterlab/galata/pull/42) (@mbektas) +- Add/set cell using UI actions [\#41](https://github.com/jupyterlab/galata/pull/41) (@mbektas) + +## [v3.0.7-4](https://github.com/jupyterlab/galata/tree/v3.0.7-4) + +[Full Changelog](https://github.com/jupyterlab/galata/compare/v3.0.7-3...v3.0.7-4) + +### Changes + +- increment version for 3.0.7-4 release [\#40](https://github.com/jupyterlab/galata/pull/40) (@mbektas) +- API enhancements [\#39](https://github.com/jupyterlab/galata/pull/39) (@mbektas) +- Add release instructions [\#38](https://github.com/jupyterlab/galata/pull/38) (@mbektas) + +## [v3.0.7-3](https://github.com/jupyterlab/galata/tree/v3.0.7-3) + +[Full Changelog](https://github.com/jupyterlab/galata/compare/v3.0.7-2...v3.0.7-3) + +### Changes + +- increment version for 3.0.7-3 release [\#37](https://github.com/jupyterlab/galata/pull/37) (@mbektas) + +## [v3.0.7-2](https://github.com/jupyterlab/galata/tree/v3.0.7-2) + +[Full Changelog](https://github.com/jupyterlab/galata/compare/v3.0.7-1...v3.0.7-2) + +### Changes + +- increment version for 3.0.7-2 release [\#35](https://github.com/jupyterlab/galata/pull/35) (@mbektas) +- add theme API & configuration [\#33](https://github.com/jupyterlab/galata/pull/33) (@mbektas) +- update Mehmet's github handle [\#31](https://github.com/jupyterlab/galata/pull/31) (@mbektas) + +## [v3.0.7-1](https://github.com/jupyterlab/galata/tree/v3.0.7-1) + +[Full Changelog](https://github.com/jupyterlab/galata/compare/v3.0.3-3...v3.0.7-1) + +### Changes + +- Enhancements to handle end-to-end JupyterLab UI testing [\#36](https://github.com/jupyterlab/galata/pull/36) (@mbektas) +- upgrade to jupyterlab 3.0.7 [\#29](https://github.com/jupyterlab/galata/pull/29) (@mbektas) +- close all tabs more reliably [\#28](https://github.com/jupyterlab/galata/pull/28) (@mbektas) +- Rename report.html to index.html [\#27](https://github.com/jupyterlab/galata/pull/27) (@jtpio) +- Create reference and output dirs if they don't exist [\#26](https://github.com/jupyterlab/galata/pull/26) (@martinRenou) +- switch workflow to main branch [\#22](https://github.com/jupyterlab/galata/pull/22) (@mbektas) +- upgrade ansi\_up dependency to 5.0.0 to resolve vulnerability [\#20](https://github.com/jupyterlab/galata/pull/20) (@mbektas) + +## [v3.0.3-3](https://github.com/jupyterlab/galata/tree/v3.0.3-3) + +[Full Changelog](https://github.com/jupyterlab/galata/compare/v3.0.3-2...v3.0.3-3) + +### Changes + +- Publish 3.0.3-3 for security patch [\#19](https://github.com/jupyterlab/galata/pull/19) (@mbektas) +- upgrade axios package to resolve security vulnerability [\#18](https://github.com/jupyterlab/galata/pull/18) (@mbektas) +- Add getting started section [\#17](https://github.com/jupyterlab/galata/pull/17) (@mbektas) + +## [v3.0.3-2](https://github.com/jupyterlab/galata/tree/v3.0.3-2) + +[Full Changelog](https://github.com/jupyterlab/galata/compare/31767100603daa49e2cb6b7466451be5f76f4ac2...v3.0.3-2) + +### Changes + +- publish 3.0.3-2 [\#16](https://github.com/jupyterlab/galata/pull/16) (@mbektas) +- Update authors and acknowledgement [\#15](https://github.com/jupyterlab/galata/pull/15) (@jtpio) +- Add link to the Jupyter Code of Conduct [\#13](https://github.com/jupyterlab/galata/pull/13) (@jtpio) +- Add jlab wait [\#12](https://github.com/jupyterlab/galata/pull/12) (@mbektas) +- Playwright [\#11](https://github.com/jupyterlab/galata/pull/11) (@mbektas) +- Rename jlt to galata, detect image size differences [\#10](https://github.com/jupyterlab/galata/pull/10) (@mbektas) +- Enforce version match [\#9](https://github.com/jupyterlab/galata/pull/9) (@mbektas) +- properly exit process after flushing logs [\#8](https://github.com/jupyterlab/galata/pull/8) (@mbektas) +- Add workflow to run galata tests on CI [\#7](https://github.com/jupyterlab/galata/pull/7) (@jtpio) +- Provide default path to chromium on Linux [\#6](https://github.com/jupyterlab/galata/pull/6) (@jtpio) +- Add a screencast to README.md to demo Galata [\#5](https://github.com/jupyterlab/galata/pull/5) (@jtpio) +- Update to JupyterLab 3 and webpack 5 [\#2](https://github.com/jupyterlab/galata/pull/2) (@jtpio) From 88447991790feb48dd45dcf5b1f8ed78d59d1791 Mon Sep 17 00:00:00 2001 From: Jeremy Tuloup Date: Thu, 15 Jul 2021 15:22:15 +0200 Subject: [PATCH 2/5] Add check-release CI workflow --- .github/workflows/check-release.yml | 50 +++++++++++++++++++++++++++++ 1 file changed, 50 insertions(+) create mode 100644 .github/workflows/check-release.yml diff --git a/.github/workflows/check-release.yml b/.github/workflows/check-release.yml new file mode 100644 index 0000000..630a4df --- /dev/null +++ b/.github/workflows/check-release.yml @@ -0,0 +1,50 @@ +name: Check Release +on: + push: + branches: + - "*" + pull_request: + branches: + - "*" + +permissions: + contents: + write + +jobs: + check_release: + runs-on: ubuntu-latest + steps: + - name: Checkout + uses: actions/checkout@v2 + - name: Install Python + uses: actions/setup-python@v2 + with: + python-version: 3.9 + architecture: "x64" + - name: Install node + uses: actions/setup-node@v2 + with: + node-version: '14.x' + - name: Get pip cache dir + id: pip-cache + run: | + echo "::set-output name=dir::$(pip cache dir)" + - name: Cache pip + uses: actions/cache@v1 + with: + path: ${{ steps.pip-cache.outputs.dir }} + key: ${{ runner.os }}-pip-${{ hashFiles('setup.py') }} + restore-keys: | + ${{ runner.os }}-pip- + - name: Cache checked links + uses: actions/cache@v2 + with: + path: ~/.cache/pytest-link-check + key: ${{ runner.os }}-linkcheck-${{ hashFiles('**/.md') }}-md-links + restore-keys: | + ${{ runner.os }}-linkcheck- + - name: Check Release + uses: jupyter-server/jupyter_releaser/.github/actions/check-release@v1 + with: + token: ${{ secrets.GITHUB_TOKEN }} \ No newline at end of file From b0b291db653e6e28cde50676e3925b4ab32ab17e Mon Sep 17 00:00:00 2001 From: Jeremy Tuloup Date: Thu, 15 Jul 2021 15:29:01 +0200 Subject: [PATCH 3/5] Switch to yarn to simplify --- .github/workflows/main.yml | 10 +++++----- README.md | 16 ++++++++-------- RELEASE.md | 6 +++--- lerna.json | 2 +- package.json | 2 +- packages/galata/package.json | 4 ++-- 6 files changed, 20 insertions(+), 20 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 33d49cc..b768d44 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -27,14 +27,14 @@ jobs: python -m pip install jupyterlab~=3.0.11 - name: Install & lint run: | - jlpm - jlpm eslint:check + yarn + yarn eslint:check - name: Build run: | - jlpm run build + yarn run build - name: Launch JupyterLab run: | - jlpm run start:detached + yarn run start:detached - name: Wait for JupyterLab uses: ifaxity/wait-on-action@v1 with: @@ -42,4 +42,4 @@ jobs: timeout: 20000 - name: Test run: | - jlpm run test:ci + yarn run test:ci diff --git a/README.md b/README.md index 3d15d99..bcc74e0 100644 --- a/README.md +++ b/README.md @@ -33,13 +33,13 @@ git clone https://github.com/jupyterlab/galata.git cd galata/packages/galata-example # install dependencies -jlpm +yarn # build -jlpm run build +yarn run build # run test suites using `test` script which calls `galata` CLI script -jlpm run test +yarn run test ``` Galata should generate console output similar to following @@ -51,7 +51,7 @@ Galata should generate console output similar to following ``` -You can edit the test suite file [`galata-example/tests/test.test.ts`](packages/galata-example/tests/test.test.ts) or add more test suites to the [`galata-example/tests`](packages/galata-example/tests/) directory. You can pass additional [command-line options](#command-line-options) to Galata by appending them to the `jlpm run test` command such as `jlpm run test -- --no-headless`. +You can edit the test suite file [`galata-example/tests/test.test.ts`](packages/galata-example/tests/test.test.ts) or add more test suites to the [`galata-example/tests`](packages/galata-example/tests/) directory. You can pass additional [command-line options](#command-line-options) to Galata by appending them to the `yarn run test` command such as `yarn run test -- --no-headless`. Additional test suite examples are available in [`galata/tests`](packages/galata/tests/). They contain examples of creating notebooks, uploading notebooks to JupyterLab, running notebooks and taking screenshots. @@ -68,8 +68,8 @@ Galata package is versioned with the same major, minor and patch versions as the Install dependencies and build ``` -jlpm -jlpm run build +yarn +yarn run build ``` For tests to be run, a JupyterLab instance must be up and running. Launch it without credentials. Tests expect to connect JupyterLab from `localhost:8888` by default. If a different URL is to be used, it can be specified using Galata's `--jlab-base-url` command line argument. If your tests are modifying files (upload / rename / delete), or taking captures that include file explorer then it is suggested to launch JupyterLab from inside an empty directory. @@ -81,11 +81,11 @@ Galata uses headless browser to launch JupyterLab and runs tests in. Browser can Galata can also connect to Browser via a remote debugging URL. It can be specified using `--browser-url`. ## Running tests -There are two projects in this mono-repo. `galata` core project and `galata-example` project which is a boilerplate project that shows how `galata` can be integrated into a node project. Both of these projects contain some test suites that serve as unit tests and examples. You can run them using `lerna run test` or `jlpm run test` in each project's root directory. It is suggested to run tests in each projects directory as below. Otherwise you need to run `lerna run test --stream` to see detailed result of each test in a test suite. +There are two projects in this mono-repo. `galata` core project and `galata-example` project which is a boilerplate project that shows how `galata` can be integrated into a node project. Both of these projects contain some test suites that serve as unit tests and examples. You can run them using `lerna run test` or `yarn run test` in each project's root directory. It is suggested to run tests in each projects directory as below. Otherwise you need to run `lerna run test --stream` to see detailed result of each test in a test suite. ``` cd packages/galata -jlpm run test +yarn run test ``` ## Configuration diff --git a/RELEASE.md b/RELEASE.md index 2ab6377..6714033 100644 --- a/RELEASE.md +++ b/RELEASE.md @@ -9,14 +9,14 @@ 2. Re-install dependencies and rebuild. ``` -jlpm -jlpm run build +yarn +yarn run build ``` 3. Run tests and make sure that all pass. Before running tests, JupyterLab must be up and running. You can use the launch command described in `Launch JupyterLab` section of [README.md](README.md#launch-jupyterlab) ``` -jlpm run test +yarn run test ``` 4. Commit your version changes. diff --git a/lerna.json b/lerna.json index 5c85477..89c5be3 100644 --- a/lerna.json +++ b/lerna.json @@ -1,5 +1,5 @@ { "version": "independent", - "npmClient": "jlpm", + "npmClient": "yarn", "useWorkspaces": true } diff --git a/package.json b/package.json index 9128851..73bbf35 100644 --- a/package.json +++ b/package.json @@ -7,7 +7,7 @@ "eslint:check": "eslint . --ext .js,.ts,.tsx", "install": "lerna bootstrap", "start": "jupyter lab --config ./jupyter_server_config.py", - "start:detached": "(jlpm run start&)", + "start:detached": "(yarn run start&)", "test": "lerna run test --stream", "test:ci": "lerna run test --stream --scope @jupyterlab/galata" }, diff --git a/packages/galata/package.json b/packages/galata/package.json index 9a0fe16..918755d 100644 --- a/packages/galata/package.json +++ b/packages/galata/package.json @@ -16,8 +16,8 @@ "build:galata": "tsc", "save-jlab-version": "node ./bin/buildutil.js --save-jlab-version", "enforce-version-match": "node ./bin/buildutil.js --enforce-version-match", - "build": "jlpm run clean && jlpm run save-jlab-version && jlpm run build:inpage && jlpm run build:galata", - "prepublishOnly": "jlpm run build && jlpm run enforce-version-match", + "build": "yarn run clean && yarn run save-jlab-version && yarn run build:inpage && yarn run build:galata", + "prepublishOnly": "yarn run build && yarn run enforce-version-match", "test": "node ./bin/cli.js" }, "files": [ From c78a822815daac7110e3ae067f3e9444feb7edc0 Mon Sep 17 00:00:00 2001 From: Jeremy Tuloup Date: Thu, 15 Jul 2021 15:34:18 +0200 Subject: [PATCH 4/5] Use the same version everywhere --- lerna.json | 2 +- packages/galata-example/package.json | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/lerna.json b/lerna.json index 89c5be3..a7293c1 100644 --- a/lerna.json +++ b/lerna.json @@ -1,5 +1,5 @@ { - "version": "independent", + "version": "3.0.11-2", "npmClient": "yarn", "useWorkspaces": true } diff --git a/packages/galata-example/package.json b/packages/galata-example/package.json index 54bcebf..8c753b7 100644 --- a/packages/galata-example/package.json +++ b/packages/galata-example/package.json @@ -1,6 +1,6 @@ { "name": "galata-example", - "version": "1.0.0", + "version": "3.0.11-2", "description": "Galata Example", "private": true, "scripts": { From 7c967047cb2c5b9f1ae772738aa0fcebd781e767 Mon Sep 17 00:00:00 2001 From: Jeremy Tuloup Date: Thu, 15 Jul 2021 15:50:20 +0200 Subject: [PATCH 5/5] Add releaser hooks and options --- .github/workflows/check-release.yml | 4 +++- package.json | 15 ++++++++++++++- packages/galata/package.json | 6 +++--- 3 files changed, 20 insertions(+), 5 deletions(-) diff --git a/.github/workflows/check-release.yml b/.github/workflows/check-release.yml index 630a4df..8503ae3 100644 --- a/.github/workflows/check-release.yml +++ b/.github/workflows/check-release.yml @@ -47,4 +47,6 @@ jobs: - name: Check Release uses: jupyter-server/jupyter_releaser/.github/actions/check-release@v1 with: - token: ${{ secrets.GITHUB_TOKEN }} \ No newline at end of file + token: ${{ secrets.GITHUB_TOKEN }} + env: + RH_VERSION_SPEC: 3.0.0-1 \ No newline at end of file diff --git a/package.json b/package.json index 73bbf35..d326d4c 100644 --- a/package.json +++ b/package.json @@ -1,5 +1,6 @@ { - "name": "root", + "name": "@jupyterlab/galata-root", + "version": "0.1.0", "private": true, "scripts": { "build": "lerna run build", @@ -24,5 +25,17 @@ "packages": [ "packages/*" ] + }, + "jupyter-releaser": { + "hooks": { + "before-build-npm": [ + "yarn run build" + ] + }, + "options": { + "version-cmd": [ + "yarn run lerna version --force-publish --no-push --no-git-tag-version --exact --yes" + ] + } } } diff --git a/packages/galata/package.json b/packages/galata/package.json index 918755d..3505717 100644 --- a/packages/galata/package.json +++ b/packages/galata/package.json @@ -52,6 +52,7 @@ "ansi_up": "^5.0.0", "axios": "^0.21.1", "chalk": "^4.0.0", + "cross-spawn": "^6.0.5", "dateformat": "^3.0.3", "ejs": "^3.0.1", "events": "^3.0.0", @@ -61,14 +62,13 @@ "jest": "^25.1.0", "js-beautify": "^1.10.3", "meow": "^6.0.1", + "open": "^7.0.4", "pixelmatch": "^5.1.0", - "pngjs": "^3.4.0", "playwright": "^1.9.1", + "pngjs": "^3.4.0", "semver": "^7.3.2", "ts-jest": "^25.2.0", "typescript": "^3.7.4", - "cross-spawn": "^6.0.5", - "open": "^7.0.4", "uuid": "^3.4.0" }, "devDependencies": {