-
Notifications
You must be signed in to change notification settings - Fork 2
feat: export all CSV matches via discovery_matches endpoint #297
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
Conversation
…ilenames Changed CSV export to download all matches using the discovery_matches endpoint with _format=csv parameter instead of the batch endpoints. Filenames now use i18n translations for entity names.
Removed old batch download functions (downloadIndividualCSV, downloadBiosampleCSV, downloadExperimentCSV) that are no longer used after switching to discovery_matches endpoint.
…xport - Use existing scopedAuthorizedRequestConfig utility instead of manually building params - Switch from fetch to axios for consistency with rest of codebase - Create useDownloadAllMatchesCSV hook to avoid passing state as parameter - Remove unused useAuthorizationHeader import
…quests - Create scopedAuthorizedRequestConfigFromParts to build config from auth + scope instead of full state - Update useDownloadAllMatchesCSV to only depend on auth and selectedScope (not entire state) - This prevents unnecessary callback recreation on unrelated Redux state changes - Improves performance by reducing re-renders
Without _page_size=0, the endpoint would only return the default page size instead of all matching results.
… types Since we're using the discovery_matches endpoint with _format=csv, export is automatically supported for all entity types (phenopackets, biosamples, experiments, experiment_results). No need for per-entity export configuration.
gsfk
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Working as expected.
The French filenames with English-only content are a little weird, but actual content of the csv is arguably out of scope here.
davidlougheed
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm
Summary
Changes
Test plan