Skip to content

Commit

Permalink
Merge branch 'develop' into wip/akirathan/12090-telemetry
Browse files Browse the repository at this point in the history
  • Loading branch information
Akirathan committed Mar 6, 2025
2 parents 6ecdd77 + a526b2b commit 0f3b719
Show file tree
Hide file tree
Showing 234 changed files with 13,670 additions and 2,884 deletions.
4 changes: 3 additions & 1 deletion .bazelignore
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@ app/ide-desktop/lib/esbuild-plugin-copy-directories/node_modules
app/ide-desktop/lib/icons/node_modules
app/ide-desktop/lib/ts-plugin-namespace-auto-import/node_modules
app/ide-desktop/node_modules
app/lang-markdown/node_modules
app/lezer-markdown/node_modules
app/rust-ffi/node_modules
app/ydoc-server/node_modules
app/ydoc-server-nodejs/node_modules
Expand All @@ -33,4 +35,4 @@ build-cache
.dist
target
build
.git
.git
4 changes: 4 additions & 0 deletions .prettierignore
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,10 @@ build.json
app/gui/playwright-report/
maven_install.json

# Git-subtree, upstream doesn't use prettier
app/lang-markdown
app/lezer-markdown

# Engine Builds can leave these nested working copies.
# TODO [mwu]: Adjust Engine build to not leave them.
ci-build/
Expand Down
6 changes: 6 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@
buttons][12341]
- [Cloud File Browser allows renaming existing directories in "writing"
components][12323]
- [New Component Browser displaying list of groups][12386]
- ["Insert link" button added to documentation panel][12365]
- [Cloud File Browser, when opened first time after opening project, shows and
highlights the currently set file][12184]
Expand All @@ -52,6 +53,7 @@
[12275]: https://github.com/enso-org/enso/pull/12275
[12341]: https://github.com/enso-org/enso/pull/12341
[12323]: https://github.com/enso-org/enso/pull/12323
[12386]: https://github.com/enso-org/enso/pull/12386
[12365]: https://github.com/enso-org/enso/pull/12365
[12184]: https://github.com/enso-org/enso/pull/12184

Expand Down Expand Up @@ -213,6 +215,7 @@
[11695]: https://github.com/enso-org/enso/pull/11695
[11715]: https://github.com/enso-org/enso/pull/11715
[11753]: https://github.com/enso-org/enso/pull/11753
[11755]: https://github.com/enso-org/enso/pull/11755
[11761]: https://github.com/enso-org/enso/pull/11761
[11768]: https://github.com/enso-org/enso/pull/11768
[11810]: https://github.com/enso-org/enso/pull/11810
Expand All @@ -236,6 +239,8 @@
- [The reload button clears the HTTP cache.][11673]
- [SQL Server Support for Aggregate][11811]
- [Added `Download_Mode` parameter to `Data.download`.][12017]
- [Added `Table.geo_distance` to calculate the distance between two
points.][12393]

[11235]: https://github.com/enso-org/enso/pull/11235
[11255]: https://github.com/enso-org/enso/pull/11255
Expand All @@ -248,6 +253,7 @@
[11673]: https://github.com/enso-org/enso/pull/11673
[11811]: https://github.com/enso-org/enso/pull/11811
[12017]: https://github.com/enso-org/enso/pull/12017
[12393]: https://github.com/enso-org/enso/pull/12393

#### Enso Language & Runtime

Expand Down
6 changes: 3 additions & 3 deletions MODULE.bazel.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion app/common/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
},
"main": "src/index.ts",
"scripts": {
"test": "vitest run",
"test:unit": "vitest run",
"compile": "tsc",
"lint": "eslint ./src --cache --max-warnings=0"
},
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
import * as v from 'vitest'

v.test('Test suite disabled (FIXME: #12426)', () => {})
/*
import { ZonedDateTime } from '@internationalized/date'
import * as v from 'vitest'
import { IanaTimeZone, toRfc3339 } from '../../../utilities/data/dateTime'
Expand Down Expand Up @@ -67,3 +71,4 @@ v.test.each([
v.expect(firstProjectExecutionOnOrAfter(info, current).toString()).toBe(next.toString())
},
)
*/
2 changes: 1 addition & 1 deletion app/common/src/text/english.json
Original file line number Diff line number Diff line change
Expand Up @@ -810,7 +810,7 @@
"settingsShortcut": "Settings",
"closeTabShortcut": "Close Tab",
"openShortcut": "Open",
"runShortcut": "Execute as Task",
"runShortcut": "Run Locally",
"closeShortcut": "Close",
"uploadToCloudShortcut": "Upload to Cloud",
"renameShortcut": "Rename",
Expand Down
2 changes: 1 addition & 1 deletion app/gui/.dev-env
15 changes: 0 additions & 15 deletions app/gui/integration-test/dashboard/actions/DrivePageActions.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@ import EditorPageActions from './EditorPageActions'
import { goToPageActions, type GoToPageActions } from './goToPageActions'
import NewDataLinkModalActions from './NewDataLinkModalActions'
import PageActions from './PageActions'
import StartModalActions from './StartModalActions'

const ASSET_ROW_SAFE_POSITION = { x: 150, y: 16 }

Expand Down Expand Up @@ -368,20 +367,6 @@ export default class DrivePageActions<Context> extends PageActions<Context> {
}
}

/** Open the "start" modal. */
openStartModal() {
return this.step('Open "start" modal', (page) =>
page.getByText(TEXT.startWithATemplate).click(),
).into(StartModalActions<Context>)
}

/** Expect the "start" modal to be visible. */
expectStartModal() {
return this.into(StartModalActions<Context>).withStartModal(async (startModal) => {
await expect(startModal).toBeVisible()
})
}

/** Clear trash. */
clearTrash() {
return this.step('Clear trash', async (page) => {
Expand Down
61 changes: 0 additions & 61 deletions app/gui/integration-test/dashboard/actions/StartModalActions.ts

This file was deleted.

12 changes: 4 additions & 8 deletions app/gui/integration-test/dashboard/actions/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@ import {
import DrivePageActions from './DrivePageActions'
import LATEST_GITHUB_RELEASES from './latestGithubReleases.json' with { type: 'json' }
import LoginPageActions from './LoginPageActions'
import StartModalActions from './StartModalActions'

/** An example password that does not meet validation requirements. */
export const INVALID_PASSWORD = 'password'
Expand Down Expand Up @@ -156,18 +155,15 @@ export function mockAll({ page, setupAPI }: MockParams) {
})
}

export interface MockAllAndLoginParams extends MockParams {}

/** Set up all mocks, and log in with dummy credentials. */
export function mockAllAndLogin({ page, setupAPI }: MockParams) {
export function mockAllAndLogin({ page, setupAPI }: MockAllAndLoginParams) {
const actions = mockAll({ page, setupAPI })

return actions
.step('Login', (page) => login({ page }))
.step('Wait for dashboard to load', waitForDashboardToLoad)
.step('Check if start modal is shown', async (page) => {
// @ts-expect-error This is the only place in which the private member `.context`
// should be accessed.
const context = actions.context
await new StartModalActions(page, context).close()
})
.into(DrivePageActions<Context>)
}

Expand Down
7 changes: 0 additions & 7 deletions app/gui/integration-test/dashboard/assetPanel.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -19,13 +19,6 @@ function locateAssetPanelDescription(page: Page) {
return locateAssetPanel(page).getByTestId('asset-panel-description')
}

/** Find asset permissions in an asset panel. */
// eslint-disable-next-line @typescript-eslint/no-unused-vars
function locateAssetPanelPermissions(page: Page) {
// This has no identifying features.
return locateAssetPanel(page).getByTestId('asset-panel-permissions').getByRole('button')
}

/** An example description for the asset selected in the asset panel. */
const DESCRIPTION = 'foo bar'
/** An example owner username for the asset selected in the asset panel. */
Expand Down
2 changes: 0 additions & 2 deletions app/gui/integration-test/dashboard/createAsset.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,6 @@ test('create folder', ({ page }) =>
test('create project', ({ page }) =>
mockAllAndLogin({ page })
.newEmptyProject()
// FIXME[sb]: https://github.com/enso-org/cloud-v2/issues/1615
// Uncomment once cloud execution in the browser is re-enabled.
.waitForEditorToLoad()
.goToPage.drive()
.driveTable.withRows((rows) => expect(rows).toHaveCount(1)))
Expand Down
5 changes: 0 additions & 5 deletions app/gui/integration-test/dashboard/delete.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -83,11 +83,6 @@ test('clear trash', ({ page }) =>
.clearTrash()
.driveTable.expectTrashPlaceholderRow()
.goToCategory.cloud()
.expectStartModal()
.withStartModal(async (startModal) => {
await expect(startModal).toBeVisible()
})
.close()
.driveTable.withRows(async (rows) => {
await expect(rows).toHaveCount(0)
}))
2 changes: 0 additions & 2 deletions app/gui/integration-test/dashboard/loginLogout.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,6 @@ test.use({ storageState: { cookies: [], origins: [] } })
test('login and logout', ({ page }) =>
mockAll({ page })
.login()
.expectStartModal()
.close()
.withDriveView(async (driveView) => {
await expect(driveView).toBeVisible()
})
Expand Down
31 changes: 0 additions & 31 deletions app/gui/integration-test/dashboard/startModal.spec.ts

This file was deleted.

34 changes: 31 additions & 3 deletions app/gui/integration-test/project-view/componentBrowser.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -189,7 +189,7 @@ test('Filling input with suggestion', async ({ page }) => {
await expect(locate.componentBrowserEntry(page)).toExist()

// Applying suggestion
await page.keyboard.press('Tab')
await page.keyboard.press('Shift+Enter')
await expect(locate.componentBrowser(page)).toExist()
await expect(locate.componentBrowserInput(page).locator('input')).toHaveValue('Data.read ')
})
Expand All @@ -202,6 +202,34 @@ test('Filtering list', async ({ page }) => {
await expect(segments).toHaveText(['Data.', 're', 'ad', '_te', 'xt'])
const highlighted = locate.componentBrowserEntry(page).locator('.component-label-segment.match')
await expect(highlighted).toHaveText(['re', '_te'])
// Filtered-out group are hidden, and the rest displays number of matched elements.
await expect(page.locator('.groupEntry')).toHaveText(['all (1)', 'Input (1)'])
})

test('Navigating groups', async ({ page }) => {
await actions.goToGraph(page)
await locate.addNewNodeButton(page).click()
await expect(locate.componentBrowserSelectedEntry(page)).toExist()
await expect(page.locator('.groupEntry')).toHaveText(['all', 'Input', 'Output'])
await expect(locate.componentBrowserEntryByLabel(page, 'Data.read')).toExist()
await expect(locate.componentBrowserEntryByLabel(page, 'Data.every_tag')).toExist()

// Hover first group: `Data.read` is filtered out
await page.locator('.groupEntry').nth(1).hover()
await expect(locate.componentBrowserEntryByLabel(page, 'Data.read')).toExist()
await expect(locate.componentBrowserEntryByLabel(page, 'Data.every_tag')).toHaveCount(0)
await expect(locate.componentBrowserSelectedEntry(page)).toExist() // component list didn't lose focus.

// Navigate to second group using arrows.
await page.keyboard.press('Tab')
await expect(locate.componentBrowserSelectedEntry(page)).toHaveCount(0)
await page.keyboard.press('ArrowDown')
await expect(locate.componentBrowserSelectedEntry(page)).toHaveCount(0)
await expect(page.locator('.groupEntry.selected')).toHaveText('Output')
await expect(locate.componentBrowserEntryByLabel(page, 'Data.read')).toHaveCount(0)
await expect(locate.componentBrowserEntryByLabel(page, 'Data.every_tag')).toExist()
await page.keyboard.press('Tab')
await expect(locate.componentBrowserSelectedEntry(page)).toExist()
})

test('Editing existing nodes', async ({ page }) => {
Expand Down Expand Up @@ -247,7 +275,7 @@ test('Visualization preview: type-based visualization selection', async ({ page
const input = locate.componentBrowserInput(page).locator('input')
await input.fill('Table.ne')
await expect(input).toHaveValue('Table.ne')
await locate.componentBrowser(page).getByTestId('switchToEditMode').click()
await page.keyboard.press(`Shift+Enter`)
await expect(locate.tableVisualization(page)).toBeVisible()
await page.keyboard.press('Escape')
await expect(locate.componentBrowser(page)).toBeHidden()
Expand All @@ -262,7 +290,7 @@ test('Visualization preview: user visualization selection', async ({ page }) =>
const input = locate.componentBrowserInput(page).locator('input')
await input.fill('4')
await expect(input).toHaveValue('4')
await locate.componentBrowser(page).getByTestId('switchToEditMode').click()
await page.keyboard.press(`Shift+Enter`)
await expect(locate.jsonVisualization(page)).toBeVisible()
await expect(locate.jsonVisualization(page)).toContainText('"visualizedExpr": "4"')
await locate.toggleVisualizationSelectorButton(page).click()
Expand Down
4 changes: 2 additions & 2 deletions app/gui/integration-test/project-view/locate.ts
Original file line number Diff line number Diff line change
Expand Up @@ -93,12 +93,12 @@ export const nodeCommentContent = componentLocator('.GraphNodeComment div[conten
* It may be covered by selected one due to way we display them.
*/
export function componentBrowserEntry(page: Locator | Page) {
return page.locator(`.ComponentBrowser .list-variant:not(.selected) .component`)
return page.locator(`.ComponentEntry`)
}

/** A selected variant of Component Browser Entry */
export function componentBrowserSelectedEntry(page: Locator | Page) {
return page.locator(`.ComponentBrowser .list-variant.selected .component`)
return page.locator(`.ComponentEntry.selected`)
}

/** A not-selected variant of Component Browser entry with given label */
Expand Down
Loading

0 comments on commit 0f3b719

Please sign in to comment.