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

Merge release/v0.24.1 to main #4460

Merged
merged 30 commits into from
Jun 11, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
30 commits
Select commit Hold shift + click to select a range
9b5ab39
Upgrade `jest`, `vite` and `vitest` (#4449)
benjaminpkane Jun 4, 2024
8471d1f
bump version for v0.24.1 (#4446)
imanjra Jun 4, 2024
d2ca5f7
fix operator prompt hidden for executing, output, and error (#4445)
imanjra Jun 4, 2024
cbb7c00
allow generated datasets to be directly created
brimoor May 23, 2024
6cd7b0c
load individual cvat job annotations instead of entire task
ehofesmann May 10, 2024
b726dcb
update test to create multiple jobs
ehofesmann May 10, 2024
88627a4
lint
ehofesmann May 10, 2024
584f6b6
add ultralytics yolov8 open images v7 pretrained models into zoo
brimoor Jun 5, 2024
8883b5a
handle partial maps when updating Scene asset paths
brimoor May 30, 2024
56fc86b
adding unit test for updating asset paths
brimoor May 30, 2024
3914ced
optimize 3D operations
brimoor Jun 3, 2024
1640696
consistent structure
brimoor Jun 3, 2024
6e663c3
cleanup
brimoor Jun 4, 2024
4d74e08
abspath vs realpath
brimoor Jun 5, 2024
1dd6b80
consistency
brimoor Jun 5, 2024
94c52ba
abspath
brimoor Jun 6, 2024
2350e74
updating Teams docs
brimoor Jun 6, 2024
74cc85d
fixing anomaly detection tutorial title level
brimoor May 31, 2024
1d76724
use existing merge branch (#4453)
benjaminpkane Jun 6, 2024
e17741c
Merge pull request #4455 from voxel51/cherry-pick-develop
brimoor Jun 6, 2024
1261349
adding 0.24.1 release notes
brimoor Jun 5, 2024
f692120
date
brimoor Jun 6, 2024
44c44e5
fixing docs bugs
brimoor Jun 6, 2024
5654647
Merge pull request #4456 from voxel51/notes-for-release
brimoor Jun 6, 2024
5c81022
Merge remote-tracking branch 'origin/release/v0.24.1' into merge/v0.2…
findtopher Jun 6, 2024
547a1ff
fix workspace persistence issue (#4471)
imanjra Jun 10, 2024
656a264
Refetch saved views on dataset change (#4469)
sashankaryal Jun 10, 2024
2e49b92
fix copy_files() (#4472)
brimoor Jun 10, 2024
58df963
updating release notes
brimoor Jun 11, 2024
5ba1a2f
Merge pull request #4476 from voxel51/update-release-notes
brimoor Jun 11, 2024
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
18 changes: 18 additions & 0 deletions .github/workflows/pr.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,24 @@ jobs:
e2e:
uses: ./.github/workflows/e2e.yml

teams:
runs-on: ubuntu-latest
if: github.base_ref == 'develop'
steps:
- uses: convictional/[email protected]
with:
owner: voxel51
repo: fiftyone-teams
github_token: ${{ secrets.FIFTYONE_GITHUB_TOKEN }}
github_user: voxel51-bot
workflow_file_name: merge-oss.yml
ref: develop
wait_interval: 20
client_payload: '{ "branch": "${{ github.head_ref || github.ref_name }}" }'
propagate_failure: true
trigger_workflow: true
wait_workflow: true

test:
uses: ./.github/workflows/test.yml

Expand Down
37 changes: 37 additions & 0 deletions .github/workflows/push-release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
name: Push Release

on:
push:
branches:
- main
- release/v[0-9]+.[0-9]+.[0-9]+
workflow_dispatch:
inputs:
ref_name:
type: string

jobs:
pr:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
ref: develop
fetch-depth: 0
- run: |
git config user.name 'voxel51-bot'
git config user.email '[email protected]'
git checkout merge/${{ inputs.ref_name || github.ref_name }} \
|| git checkout -b merge/${{ inputs.ref_name || github.ref_name }}
git push -u origin merge/${{ inputs.ref_name || github.ref_name }}
git checkout develop
git pull origin merge/${{ inputs.ref_name || github.ref_name }} --no-rebase
git pull origin ${{ inputs.ref_name || github.ref_name }} --no-rebase
- uses: peter-evans/create-pull-request@v6
with:
author: voxel51-bot <[email protected]>
token: ${{ secrets.FIFTYONE_GITHUB_TOKEN }}
base: develop
body: Merge `${{ inputs.ref_name || github.ref_name }}` to `develop`
branch: merge/${{ inputs.ref_name || github.ref_name }}
title: Merge `${{ inputs.ref_name || github.ref_name }}` to `develop`
4 changes: 2 additions & 2 deletions app/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -42,10 +42,10 @@
"typedoc": "^0.23.21",
"typescript": "^4.7.4",
"typescript-plugin-css-modules": "^5.0.2",
"vite": "^3.2.10",
"vite": "^5.2.12",
"vite-plugin-eslint": "^1.8.1",
"vite-plugin-relay": "^2.0.0",
"vitest": "^0.34.6"
"vitest": "^1.6.0"
},
"workspaces": [
"packages/*"
Expand Down
4 changes: 2 additions & 2 deletions app/packages/aggregations/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -23,10 +23,10 @@
"@babel/preset-typescript": "^7.17.12",
"@types/react": "^18.0.12",
"fs-extra": "^10.1.0",
"jest": "^28.1.1",
"jest": "^29.7.0",
"lodash": "^4.17.21",
"prettier": "2.2.1",
"typescript": "4.2.4",
"vite": "^3.2.10"
"vite": "^5.2.12"
}
}
2 changes: 1 addition & 1 deletion app/packages/app/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@
"rollup-plugin-polyfill-node": "^0.6.2",
"typescript": "^4.7.4",
"typescript-plugin-css-modules": "^5.0.2",
"vite": "^3.2.10",
"vite": "^5.2.12",
"vite-plugin-relay": "^1.0.7",
"vite-plugin-rewrite-all": "^1.0.2"
},
Expand Down
2 changes: 1 addition & 1 deletion app/packages/components/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@
"prettier": "^2.7.1",
"typescript": "^4.7.4",
"typescript-plugin-css-modules": "^5.0.2",
"vite": "^3.2.10"
"vite": "^5.2.12"
},
"peerDependencies": {
"re-resizable": "*",
Expand Down
2 changes: 1 addition & 1 deletion app/packages/core/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@
"rollup-plugin-polyfill-node": "^0.6.2",
"typescript": "^4.7.4",
"typescript-plugin-css-modules": "^5.0.2",
"vite": "^3.2.10",
"vite": "^5.2.12",
"vite-plugin-relay": "^1.0.7"
},
"peerDependencies": {
Expand Down
7 changes: 6 additions & 1 deletion app/packages/core/src/components/MainSpace/MainSpace.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -8,12 +8,17 @@ const { FIFTYONE_SPACE_ID } = constants;
function MainSpace() {
const [sessionSpaces, setSessionSpaces, sessionPanelsState] =
useSessionSpaces();
const { spaces, updateSpaces } = useSpaces(FIFTYONE_SPACE_ID, sessionSpaces);
const { spaces, updateSpaces, clearSpaces } = useSpaces(
FIFTYONE_SPACE_ID,
sessionSpaces
);
const [panelsState, setPanelsState] = usePanelsState();
const oldSpaces = useRef(spaces);
const oldPanelsState = useRef(panelsState);
const isMounted = useRef(false);

useEffect(() => clearSpaces, [clearSpaces]);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ensure the useEffect hook is correctly set up to call the clearSpaces function.

The useEffect hook should call the clearSpaces function, not just reference it. This might be causing the function not to execute as intended.

-  useEffect(() => clearSpaces, [clearSpaces]);
+  useEffect(() => { clearSpaces(); }, [clearSpaces]);
Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
useEffect(() => clearSpaces, [clearSpaces]);
useEffect(() => { clearSpaces(); }, [clearSpaces]);


useEffect(() => {
if (!spaces.equals(sessionSpaces)) {
updateSpaces(sessionSpaces);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,10 @@ export default function ViewSelection() {
[viewOptions, viewSearch]
);

useEffect(() => {
refetch({ name: datasetName });
}, [datasetName]);

useEffect(() => {
if (
selected &&
Expand Down
4 changes: 2 additions & 2 deletions app/packages/embeddings/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -23,9 +23,9 @@
"devDependencies": {
"@vitest/ui": "^0.34.6",
"typescript": "^4.7.4",
"vite": "^3.2.10",
"vite": "^5.2.12",
"vite-plugin-externals": "^0.5.0",
"vitest": "^0.34.6"
"vitest": "^1.6.0"
},
"fiftyone": {
"script": "dist/index.umd.js"
Expand Down
2 changes: 1 addition & 1 deletion app/packages/flashlight/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,6 @@
"prettier": "^2.7.1",
"typescript": "^4.7.4",
"typescript-plugin-css-modules": "^5.0.2",
"vite": "^3.2.10"
"vite": "^5.2.12"
}
}
4 changes: 2 additions & 2 deletions app/packages/looker-3d/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -34,9 +34,9 @@
"nodemon": "^3.0.3",
"rollup-plugin-external-globals": "^0.6.1",
"typescript": "^5.4.5",
"vite": "^3.2.10",
"vite": "^5.2.12",
"vite-plugin-externals": "^0.5.0",
"vitest": "^1.5.0"
"vitest": "^1.6.0"
},
"peerDependencies": {
"@mui/icons-material": "*",
Expand Down
2 changes: 1 addition & 1 deletion app/packages/looker/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,6 @@
"prettier": "^2.7.1",
"typescript": "^4.7.4",
"typescript-plugin-css-modules": "^5.0.2",
"vite": "^3.2.10"
"vite": "^5.2.12"
}
}
2 changes: 1 addition & 1 deletion app/packages/map/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@
"@types/react-map-gl": "^6.1.3",
"@types/robust-point-in-polygon": "^1.0.2",
"typescript": "^4.7.4",
"vite": "^3.2.10",
"vite": "^5.2.12",
"vite-plugin-externals": "^0.5.0"
},
"fiftyone": {
Expand Down
4 changes: 2 additions & 2 deletions app/packages/operators/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -21,10 +21,10 @@
"@babel/preset-typescript": "^7.17.12",
"@fiftyone/utilities": "workspace:^",
"@types/react": "^18.0.12",
"jest": "^28.1.1",
"jest": "^29.7.0",
"prettier": "2.2.1",
"typescript": "4.2.4",
"vite": "^3.2.10"
"vite": "^5.2.12"
},
"peerDependencies": {
"@mui/icons-material": "*",
Expand Down
10 changes: 8 additions & 2 deletions app/packages/operators/src/OperatorInvocationRequestExecutor.tsx
Original file line number Diff line number Diff line change
@@ -1,15 +1,21 @@
import { useEffect } from "react";
import { useEffect, useMemo } from "react";
import {
useInvocationRequestExecutor,
useInvocationRequestQueue,
} from "./state";
import { QueueItemStatus } from "./constants";

export default function OperatorInvocationRequestExecutor() {
const { requests, onSuccess, onError } = useInvocationRequestQueue();
const pendingRequests = useMemo(() => {
return requests.filter(
(queueItem) => queueItem.status === QueueItemStatus.Pending
);
}, [requests]);

Comment on lines +10 to +14
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ensure that the useMemo dependency array correctly reflects all variables used in the memoized value.

The dependency array for useMemo should include all variables that affect the returned value to avoid stale closures. Here, it should include QueueItemStatus.Pending to ensure the memoization updates correctly if the status enum changes.

-  }, [requests]);
+  }, [requests, QueueItemStatus.Pending]);
Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
const pendingRequests = useMemo(() => {
return requests.filter(
(queueItem) => queueItem.status === QueueItemStatus.Pending
);
}, [requests]);
const pendingRequests = useMemo(() => {
return requests.filter(
(queueItem) => queueItem.status === QueueItemStatus.Pending
);
}, [requests, QueueItemStatus.Pending]);

return (
<>
{requests.map((queueItem) => (
{pendingRequests.map((queueItem) => (
<RequestExecutor
key={queueItem.id}
queueItem={queueItem}
Expand Down
20 changes: 17 additions & 3 deletions app/packages/operators/src/OperatorPrompt/OperatorDrawerPrompt.tsx
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { Resizable } from "@fiftyone/components";
import { Resizable, scrollable } from "@fiftyone/components";
import { Close } from "@mui/icons-material";
import { Box, IconButton, Stack } from "@mui/material";
import { useState } from "react";
Expand Down Expand Up @@ -32,6 +32,7 @@ export default function OperatorDrawerPrompt(props: OperatorPromptPropsType) {
onResizeReset={() => {
setWidth(DEFAULT_WIDTH);
}}
data-cy="operators-prompt-drawer"
>
<IconButton
onClick={prompt.close}
Expand All @@ -42,8 +43,21 @@ export default function OperatorDrawerPrompt(props: OperatorPromptPropsType) {
<Box sx={{ p: 1 }}>
<OperatorPromptHeader title={title} />
</Box>
<OperatorPromptBody operatorPrompt={prompt} />
<Stack direction="row" spacing={1} justifyContent="center">
<Box
data-cy="operators-prompt-drawer-content"
sx={{ overflow: "auto" }}
className={scrollable}
>
<OperatorPromptBody operatorPrompt={prompt} />
</Box>
<Stack
direction="row"
spacing={1}
justifyContent="center"
alignItems="center"
data-cy="operators-prompt-drawer-footer"
sx={{ py: 1 }}
>
<OperatorPromptFooter {...otherConfigs} />
</Stack>
</Resizable>
Expand Down
22 changes: 3 additions & 19 deletions app/packages/operators/src/OperatorPrompt/OperatorModalPrompt.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -6,28 +6,12 @@ import { getOperatorPromptConfigs } from "../utils";

export default function OperatorModalPrompt(props: OperatorPromptPropsType) {
const { prompt } = props;
const {
title,
hasValidationErrors,
resolving,
pendingResolve,
validationErrorsStr,
...otherConfigs
} = getOperatorPromptConfigs(prompt);
const promptConfig = getOperatorPromptConfigs(prompt);
return (
<OperatorPalette
{...otherConfigs}
title={title}
onClose={otherConfigs.onCancel || prompt.close}
{...promptConfig}
submitOnControlEnter
disableSubmit={hasValidationErrors || resolving || pendingResolve}
disabledReason={
hasValidationErrors
? "Cannot execute operator with validation errors\n\n" +
validationErrorsStr
: "Cannot execute operator while validating form"
}
loading={resolving || pendingResolve}
dialogProps={{ PaperProps: { "data-cy": "operators-prompt-modal" } }}
>
<PaletteContentContainer>
<OperatorPromptBody operatorPrompt={prompt} />
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ export default function OperatorViewModal() {
onSubmit={io.hide}
onClose={io.hide}
submitButtonText="Done"
dialogProps={{ PaperProps: { "data-cy": "operators-prompt-view-modal" } }}
>
<PaletteContentContainer>
<OperatorIO schema={io.schema} data={io.data || {}} type={io.type} />
Expand Down
2 changes: 0 additions & 2 deletions app/packages/operators/src/OperatorPrompt/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -25,8 +25,6 @@ function DynamicOperatorPrompt() {
const target = getPromptTarget(prompt);
const Component = getPromptComponent(prompt);

if (!prompt.resolvedIO.input && !prompt.resolvedIO.output) return null;

return createPortal(<Component prompt={prompt} />, target);
}

Expand Down
6 changes: 6 additions & 0 deletions app/packages/operators/src/constants.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,3 +7,9 @@ export enum OPERATOR_PROMPT_AREAS {
DRAWER_LEFT = "operator_prompt_area_drawer_left",
DRAWER_RIGHT = "operator_prompt_area_drawer_right",
}
export enum QueueItemStatus {
Pending,
Executing,
Completed,
Failed,
}
11 changes: 1 addition & 10 deletions app/packages/operators/src/operators.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ import * as types from "./types";
import { stringifyError } from "./utils";
import { ValidationContext, ValidationError } from "./validation";
import { ExecutionCallback, OperatorExecutorOptions } from "./types-internal";
import { QueueItemStatus } from "./constants";

class InvocationRequest {
constructor(
Expand Down Expand Up @@ -747,16 +748,6 @@ export async function resolveLocalPlacements(ctx: ExecutionContext) {
return localPlacements;
}

// and allows for the execution of the requests in order of arrival
// and removing the requests that have been completed

enum QueueItemStatus {
Pending,
Executing,
Completed,
Failed,
}

class QueueItem {
constructor(
public id: string,
Expand Down
10 changes: 10 additions & 0 deletions app/packages/operators/src/utils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -77,6 +77,12 @@ export function getOperatorPromptConfigs(operatorPrompt: OperatorPromptType) {
const validationErrorsStr = formatValidationErrors(
operatorPrompt.validationErrors
);
const loading = resolving || pendingResolve;
const disableSubmit = hasValidationErrors || resolving || pendingResolve;
const disabledReason = hasValidationErrors
? "Cannot execute operator with validation errors\n\n" + validationErrorsStr
: "Cannot execute operator while validating form";
const onClose = onCancel || operatorPrompt.close;

return {
title,
Expand All @@ -99,6 +105,10 @@ export function getOperatorPromptConfigs(operatorPrompt: OperatorPromptType) {
cancelButtonText,
onSubmit,
onCancel,
loading,
disableSubmit,
disabledReason,
onClose,
};
}

Expand Down
4 changes: 2 additions & 2 deletions app/packages/plugins/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -22,10 +22,10 @@
"@babel/preset-typescript": "^7.17.12",
"@fiftyone/utilities": "workspace:^",
"@types/react": "^18.0.12",
"jest": "^28.1.1",
"jest": "^29.7.0",
"prettier": "2.2.1",
"typescript": "4.2.4",
"vite": "^3.2.10"
"vite": "^5.2.12"
},
"dependencies": {
"moment": "^2.29.4"
Expand Down
2 changes: 1 addition & 1 deletion app/packages/relay/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
"relay-compiler-language-typescript": "^15.0.1",
"relay-config": "^12.0.1",
"typescript": "^4.7.4",
"vite": "^3.2.10"
"vite": "^5.2.12"
},
"dependencies": {
"@recoiljs/refine": "^0.1.1",
Expand Down
Loading
Loading