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

feat: DIA-1924: "Import sample data" ability in the Data Import page #7206

Open
wants to merge 18 commits into
base: develop
Choose a base branch
from

Conversation

matt-bernstein
Copy link
Contributor

@matt-bernstein matt-bernstein commented Mar 11, 2025

[x] add sample data import component
[x] add configurable manifest file with sample data
[x] create default manifest file with data hosted on our s3

image

@github-actions github-actions bot added the feat label Mar 11, 2025
Copy link

netlify bot commented Mar 11, 2025

Deploy Preview for label-studio-docs-new-theme canceled.

Name Link
🔨 Latest commit e421f23
🔍 Latest deploy log https://app.netlify.com/sites/label-studio-docs-new-theme/deploys/67d45e55156c6f0008f07c78

Copy link

netlify bot commented Mar 11, 2025

Deploy Preview for heartex-docs canceled.

Name Link
🔨 Latest commit e421f23
🔍 Latest deploy log https://app.netlify.com/sites/heartex-docs/deploys/67d45e55f45114000911e61c

@nick-skriabin
Copy link
Member

nick-skriabin commented Mar 12, 2025

/fm sync

Workflow run

Copy link

codecov bot commented Mar 12, 2025

Codecov Report

Attention: Patch coverage is 66.66667% with 6 lines in your changes missing coverage. Please review.

Project coverage is 77.18%. Comparing base (0aec72b) to head (20008e0).
Report is 10 commits behind head on develop.

Files with missing lines Patch % Lines
label_studio/jwt_auth/views.py 20.00% 4 Missing ⚠️
label_studio/core/utils/sentry.py 0.00% 1 Missing ⚠️
label_studio/projects/functions/next_task.py 0.00% 1 Missing ⚠️
Additional details and impacted files
@@           Coverage Diff            @@
##           develop    #7206   +/-   ##
========================================
  Coverage    77.17%   77.18%           
========================================
  Files          187      187           
  Lines        14499    14504    +5     
========================================
+ Hits         11190    11195    +5     
  Misses        3309     3309           
Flag Coverage Δ
pytests 77.18% <66.66%> (+<0.01%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@nick-skriabin nick-skriabin force-pushed the fb-dia-1924/sample-imports branch from 7958c28 to 866cc83 Compare March 12, 2025 15:13
@@ -126,13 +128,29 @@ export const CreateProject = ({ onClose, redirect = true }) => {
}),
[name, description, config],
);
const uploadSample = useCallback(
Copy link
Contributor

Choose a reason for hiding this comment

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

I would suggest to adding the interaction with the API to a hook and using it the same way as line 109. Probably the hook should be located in labelstudio/src/hooks

@@ -30,6 +31,22 @@ export const Inner = () => {
return refresh(pathname);
}, [location, history]);

const uploadSample = useCallback(
Copy link
Contributor

Choose a reason for hiding this comment

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

I would use the same hook stated previously

Comment on lines +6 to +8
"dependencies": {
"@radix-ui/react-select": "^2.1.6"
},
Copy link
Contributor

Choose a reason for hiding this comment

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

Suggested change
"dependencies": {
"@radix-ui/react-select": "^2.1.6"
},
"dependencies": {},

This shouldn't have its own dependencies as it is a monorepo

Copy link
Contributor

@bmartel bmartel left a comment

Choose a reason for hiding this comment

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

small observation on the package.json, and I agree with the other feedback that we should look to make the hooks in the same way to align with the existing.

@nick-skriabin nick-skriabin force-pushed the fb-dia-1924/sample-imports branch from 2544ac0 to b5d8f7a Compare March 14, 2025 15:57
@matt-bernstein
Copy link
Contributor Author

Sample 1 (images) is not actually importing - looking into it. Sample 2 works.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants