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

Implements nodes/download_formats endpoint for the REST API #71

Merged
merged 4 commits into from
Nov 20, 2024

Conversation

agoscinski
Copy link
Collaborator

@agoscinski agoscinski commented Jul 25, 2024

This is only implemented for the REST API side as it is not clear for me how one could profit from the flexibility of GraphQL with this endpoint. Also an implementation for the GraphQL side would need more time and to push the migration to this new API I would ignore it for the moment.

I moved part of the code of aiida.restapi.common.identifiers and aiida.restapi.common.exceptions to this repo that is required to get all download formats.

Fixes subpoints of issues #69 and #12

Question:
PR is ready for a review I only need to fix linter errors. I am getting a bit frustrated fixing linter errors. Can I just open another PR where I change the linter and formatter to ruff with settings of aiida-core so it can automatically fix most issues @eimrek @chrisjsewell? We have to do this at some point in any case when we merge this back to aiida-core.

@agoscinski agoscinski requested a review from eimrek July 25, 2024 16:37
@eimrek
Copy link
Member

eimrek commented Jul 26, 2024

thanks @agoscinski. I will test this out when i get a moment.

Regarding linting, yep, i think switching to ruff would be great, feel free to do it in a separate PR.

tests/test_nodes.py Outdated Show resolved Hide resolved
docs/source/user_guide/graphql.md Outdated Show resolved Hide resolved
aiida_restapi/models.py Outdated Show resolved Hide resolved
@agoscinski agoscinski changed the title Implement download_formats endpoint on FastAPI side Implements nodes/download_formats endpoint for the REST API Nov 20, 2024
@agoscinski agoscinski force-pushed the downloadable-formats branch 4 times, most recently from 34f8e2d to 159d8ea Compare November 20, 2024 09:58
aiida_restapi/identifiers.py Outdated Show resolved Hide resolved
aiida_restapi/identifiers.py Outdated Show resolved Hide resolved
aiida_restapi/identifiers.py Outdated Show resolved Hide resolved
aiida_restapi/identifiers.py Outdated Show resolved Hide resolved
aiida_restapi/identifiers.py Outdated Show resolved Hide resolved
Part of the code of aiida.restapi.common.identifiers and
aiida.restapi.common.exceptions that is required to implement
`get_all_download_formats` has been moved to this repo.
@agoscinski agoscinski merged commit e06f267 into aiidateam:master Nov 20, 2024
4 of 5 checks passed
@agoscinski agoscinski deleted the downloadable-formats branch November 20, 2024 15:56
agoscinski added a commit that referenced this pull request Nov 21, 2024
In PR #71 a streaming mechanism has been implemented for the endpoint
`/nodes/{nodes_id}/download`, this however is already taken care by
FastAPI StreamingResponse and is therefore redundant and can be removed.
agoscinski added a commit that referenced this pull request Nov 21, 2024
In PR #71 a streaming mechanism has been implemented for the endpoint
`/nodes/{nodes_id}/download`, this however is already taken care by
FastAPI StreamingResponse and is therefore redundant and can be removed.
agoscinski added a commit that referenced this pull request Nov 21, 2024
In PR #71 a streaming mechanism has been implemented for the endpoint
`/nodes/{nodes_id}/download`, this however is already taken care by
FastAPI StreamingResponse and is therefore redundant and can be removed.
agoscinski added a commit that referenced this pull request Nov 26, 2024
In PR #71 a streaming mechanism has been implemented for the endpoint
`/nodes/{nodes_id}/download`, this however is already taken care by
FastAPI StreamingResponse and is therefore redundant and can be removed.
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