Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use existing server settings when creating the ConfigSection #85

Merged
merged 7 commits into from
Feb 29, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
46 changes: 36 additions & 10 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,26 +8,52 @@

### Enhancements made

- Enhance tour version [#81](https://github.com/jupyterlab-contrib/jupyterlab-tour/pull/81) ([@fcollonval](https://github.com/fcollonval))
- Add support for notebook 7 [#75](https://github.com/jupyterlab-contrib/jupyterlab-tour/pull/75) ([@fcollonval](https://github.com/fcollonval))
- Add notebook tours, icons [#29](https://github.com/jupyterlab-contrib/jupyterlab-tour/pull/29) ([@bollwyvl](https://github.com/bollwyvl))
- Enhance tour version
[#81](https://github.com/jupyterlab-contrib/jupyterlab-tour/pull/81)
([@fcollonval](https://github.com/fcollonval))
- Add support for notebook 7
[#75](https://github.com/jupyterlab-contrib/jupyterlab-tour/pull/75)
([@fcollonval](https://github.com/fcollonval))
- Add notebook tours, icons
[#29](https://github.com/jupyterlab-contrib/jupyterlab-tour/pull/29)
([@bollwyvl](https://github.com/bollwyvl))

### Bugs fixed

- Fix internationalization [#74](https://github.com/jupyterlab-contrib/jupyterlab-tour/pull/74) ([@fcollonval](https://github.com/fcollonval))
- Fix internationalization
[#74](https://github.com/jupyterlab-contrib/jupyterlab-tour/pull/74)
([@fcollonval](https://github.com/fcollonval))

### Maintenance and upkeep improvements

- Bump @babel/traverse from 7.22.10 to 7.23.2 [#80](https://github.com/jupyterlab-contrib/jupyterlab-tour/pull/80) ([@dependabot](https://github.com/dependabot))
- Bump postcss from 8.4.27 to 8.4.31 [#79](https://github.com/jupyterlab-contrib/jupyterlab-tour/pull/79) ([@dependabot](https://github.com/dependabot))
- Bump postcss from 8.4.27 to 8.4.31 in /ui-tests [#78](https://github.com/jupyterlab-contrib/jupyterlab-tour/pull/78) ([@dependabot](https://github.com/dependabot))
- Bump systeminformation from 5.18.10 to 5.21.8 in /ui-tests [#77](https://github.com/jupyterlab-contrib/jupyterlab-tour/pull/77) ([@dependabot](https://github.com/dependabot))
- upgrade to jupyterlab4 [#71](https://github.com/jupyterlab-contrib/jupyterlab-tour/pull/71) ([@djangoliv](https://github.com/djangoliv))
- Bump @babel/traverse from 7.22.10 to 7.23.2
[#80](https://github.com/jupyterlab-contrib/jupyterlab-tour/pull/80)
([@dependabot](https://github.com/dependabot))
- Bump postcss from 8.4.27 to 8.4.31
[#79](https://github.com/jupyterlab-contrib/jupyterlab-tour/pull/79)
([@dependabot](https://github.com/dependabot))
- Bump postcss from 8.4.27 to 8.4.31 in /ui-tests
[#78](https://github.com/jupyterlab-contrib/jupyterlab-tour/pull/78)
([@dependabot](https://github.com/dependabot))
- Bump systeminformation from 5.18.10 to 5.21.8 in /ui-tests
[#77](https://github.com/jupyterlab-contrib/jupyterlab-tour/pull/77)
([@dependabot](https://github.com/dependabot))
- upgrade to jupyterlab4
[#71](https://github.com/jupyterlab-contrib/jupyterlab-tour/pull/71)
([@djangoliv](https://github.com/djangoliv))

### Contributors to this release

([GitHub contributors page for this release](https://github.com/jupyterlab-contrib/jupyterlab-tour/graphs/contributors?from=2021-10-31&to=2023-11-08&type=c))

[@bollwyvl](https://github.com/search?q=repo%3Ajupyterlab-contrib%2Fjupyterlab-tour+involves%3Abollwyvl+updated%3A2021-10-31..2023-11-08&type=Issues) | [@dependabot](https://github.com/search?q=repo%3Ajupyterlab-contrib%2Fjupyterlab-tour+involves%3Adependabot+updated%3A2021-10-31..2023-11-08&type=Issues) | [@djangoliv](https://github.com/search?q=repo%3Ajupyterlab-contrib%2Fjupyterlab-tour+involves%3Adjangoliv+updated%3A2021-10-31..2023-11-08&type=Issues) | [@fcollonval](https://github.com/search?q=repo%3Ajupyterlab-contrib%2Fjupyterlab-tour+involves%3Afcollonval+updated%3A2021-10-31..2023-11-08&type=Issues) | [@github-actions](https://github.com/search?q=repo%3Ajupyterlab-contrib%2Fjupyterlab-tour+involves%3Agithub-actions+updated%3A2021-10-31..2023-11-08&type=Issues)
[@bollwyvl](https://github.com/search?q=repo%3Ajupyterlab-contrib%2Fjupyterlab-tour+involves%3Abollwyvl+updated%3A2021-10-31..2023-11-08&type=Issues)
|
[@dependabot](https://github.com/search?q=repo%3Ajupyterlab-contrib%2Fjupyterlab-tour+involves%3Adependabot+updated%3A2021-10-31..2023-11-08&type=Issues)
|
[@djangoliv](https://github.com/search?q=repo%3Ajupyterlab-contrib%2Fjupyterlab-tour+involves%3Adjangoliv+updated%3A2021-10-31..2023-11-08&type=Issues)
|
[@fcollonval](https://github.com/search?q=repo%3Ajupyterlab-contrib%2Fjupyterlab-tour+involves%3Afcollonval+updated%3A2021-10-31..2023-11-08&type=Issues)
|
[@github-actions](https://github.com/search?q=repo%3Ajupyterlab-contrib%2Fjupyterlab-tour+involves%3Agithub-actions+updated%3A2021-10-31..2023-11-08&type=Issues)

<!-- <END NEW CHANGELOG ENTRY> -->
4 changes: 3 additions & 1 deletion src/__tests__/plugin.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ import { ISettingRegistry } from '@jupyterlab/settingregistry';
import { CommandRegistry } from '@lumino/commands';
import { ReadonlyJSONObject } from '@lumino/coreutils';
import { DocumentRegistry } from '@jupyterlab/docregistry';
import { ServerConnection } from '@jupyterlab/services';
import {
CodeMirrorEditorFactory,
CodeMirrorMimeTypeService,
Expand All @@ -34,7 +35,8 @@ function mockApp(): Partial<JupyterFrontEnd> {
return {
commands: new CommandRegistry(),
restored: Promise.resolve(),
docRegistry: new DocumentRegistry()
docRegistry: new DocumentRegistry(),
serviceManager: { serverSettings: ServerConnection.makeSettings() } as any
};
}

Expand Down
5 changes: 3 additions & 2 deletions src/plugin.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -55,13 +55,14 @@ function activate(
translator: ITranslator | null
): ITourManager {
const CONFIG_SECTION_NAME = corePlugin.id.replace(/[^\w]/g, '');
const { commands } = app;
const { commands, serviceManager } = app;

translator = translator ?? nullTranslator;

const restoreState = new PromiseDelegate<ITourState[]>();
const configReady = ConfigSection.create({
name: CONFIG_SECTION_NAME
name: CONFIG_SECTION_NAME,
serverSettings: serviceManager.serverSettings
}).catch(error => {
console.error('Failed to fetch state for jupyterlab-tour.', error);
});
Expand Down
3 changes: 1 addition & 2 deletions ui-tests/tests/notebook-tour.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -29,9 +29,8 @@ test('should run the notebook tour', async ({ page }) => {

const [notebookPage] = await Promise.all([
page.waitForEvent('popup'),
page.getByText('Notebook', { exact: true }).click()
page.getByText('Python 3 (ipykernel)').click()
]);
await notebookPage.getByRole('button', { name: 'Select Kernel' }).click();
await notebookPage.getByRole('button', { name: 'Start now' }).click();
await notebookPage.getByLabel('Next', { exact: true }).click();
await notebookPage.getByLabel('Next', { exact: true }).click();
Expand Down
4 changes: 2 additions & 2 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -10668,11 +10668,11 @@ __metadata:

"typescript@patch:typescript@~5.0.4#~builtin<compat/typescript>":
version: 5.0.4
resolution: "typescript@patch:typescript@npm%3A5.0.4#~builtin<compat/typescript>::version=5.0.4&hash=b5f058"
resolution: "typescript@patch:typescript@npm%3A5.0.4#~builtin<compat/typescript>::version=5.0.4&hash=85af82"
bin:
tsc: bin/tsc
tsserver: bin/tsserver
checksum: d26b6ba97b6d163c55dbdffd9bbb4c211667ebebc743accfeb2c8c0154aace7afd097b51165a72a5bad2cf65a4612259344ff60f8e642362aa1695c760d303ac
checksum: bb309d320c59a26565fb3793dba550576ab861018ff3fd1b7fccabbe46ae4a35546bc45f342c0a0b6f265c801ccdf64ffd68f548f117ceb7f0eac4b805cd52a9
languageName: node
linkType: hard

Expand Down
Loading