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

Fix Datasets API getVersionFiles endpoint content type filtering #10017

Merged
merged 1 commit into from
Oct 16, 2023

Conversation

GPortas
Copy link
Contributor

@GPortas GPortas commented Oct 16, 2023

What this PR does / why we need it:

DatasetsIT.getVersionFiles fails intermittently as it sometimes finds out unordered files when sorting by content type.

A second orderBy condition has been added to force that when sorting by content type, files are also sorted by name.

New order example:

  • test_5.png
  • test_1.txt
  • test_2.txt
  • test_3.txt

Suggestions on how to test this:

Get dataset files via curl using contentType query param:

curl "https://demo.dataverse.org/api/datasets/24/versions/1.0/files?contentType=image/png"

@GPortas GPortas marked this pull request as ready for review October 16, 2023 16:03
Copy link
Contributor

@landreev landreev left a comment

Choose a reason for hiding this comment

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

Perfect, thank you for a quick fix!

@landreev landreev added this to Ready for Review ⏩ in IQSS/dataverse (TO BE RETIRED / DELETED in favor of project 34) via automation Oct 16, 2023
@landreev landreev moved this from Ready for Review ⏩ to Ready for QA ⏩ in IQSS/dataverse (TO BE RETIRED / DELETED in favor of project 34) Oct 16, 2023
@github-actions
Copy link

📦 Pushed preview images as

ghcr.io/gdcc/dataverse:fix-integration-test-getversionfiles
ghcr.io/gdcc/configbaker:fix-integration-test-getversionfiles

🚢 See on GHCR. Use by referencing with full name as printed above, mind the registry name.

@kcondon kcondon self-assigned this Oct 16, 2023
@kcondon kcondon merged commit 1889394 into develop Oct 16, 2023
16 of 17 checks passed
IQSS/dataverse (TO BE RETIRED / DELETED in favor of project 34) automation moved this from Ready for QA ⏩ to Done 🚀 Oct 16, 2023
@kcondon kcondon deleted the fix/integration_test_getversionfiles branch October 16, 2023 18:01
@pdurbin pdurbin added this to the 6.1 milestone Jan 5, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
No open projects
Development

Successfully merging this pull request may close these issues.

None yet

4 participants