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

[ENG-6800] Fix My Preprints Page #10893

Conversation

Vlad0n20
Copy link

@Vlad0n20 Vlad0n20 commented Jan 7, 2025

Purpose

Update preprints filtering for User preprints endpoint

Changes

Return only latest preprints

QA Notes

N/A

Documentation

N/A

Side Effects

N/A

Ticket

https://openscience.atlassian.net/browse/ENG-6800

Copy link
Collaborator

@cslzchen cslzchen left a comment

Choose a reason for hiding this comment

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

I took a further look into this. I think the preprint list by default should provide all the preprints (including versions) since this is how ember-osf-web and ember-osf-reviews relies on.

The fix should be in the place where the my projects page makes the API call. This is a legacy page so it is in this osf.io repo, you can find it by navigating from the website routes.py.

In addition, I think we need to add a filter/param for the list API to receive latest-only preprints.

Copy link
Collaborator

@cslzchen cslzchen left a comment

Choose a reason for hiding this comment

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

Looks good 🎆

Didn't notice this already moved into the UserPreprints endpoint and it uses the lateset_only param instead of set it default to True.

@cslzchen
Copy link
Collaborator

cslzchen commented Jan 7, 2025

In addition, will cherry pick and merge this along with #10892

@cslzchen
Copy link
Collaborator

cslzchen commented Jan 7, 2025

Merged in 7b16120

@cslzchen cslzchen closed this Jan 7, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants