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
Add processes endpoint #30
Conversation
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.
hi @NinadBhat , fine to continue along these lines
if you have any specific questions let us know
aiida_restapi/models.py
Outdated
_orm_entity = orm.ProcessNode | ||
|
||
id: Optional[int] = Field(description="Unique id (pk)") | ||
uuid: Optional[UUID] = Field(description="Unique uuid") |
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.
UUID stands for "universally unique identifier", i.e. "unique" is already part of the abbreviation
aiida_restapi/routers/process.py
Outdated
@@ -0,0 +1,40 @@ | |||
# -*- coding: utf-8 -*- | |||
"""Declaration of FastAPI application.""" |
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.
"""Declaration of FastAPI application.""" | |
"""Declaration of FastAPI router for processes.""" |
conftest.py
Outdated
@@ -53,6 +55,44 @@ def default_computers(): | |||
return [comp_1.id, comp_2.id] | |||
|
|||
|
|||
@pytest.fixture(scope="function") | |||
def default_process(): |
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.
def default_process(): | |
def example_processes(): |
conftest.py
Outdated
@@ -53,6 +55,44 @@ def default_computers(): | |||
return [comp_1.id, comp_2.id] | |||
|
|||
|
|||
@pytest.fixture(scope="function") | |||
def default_process(): | |||
"""Populate database with some process""" |
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.
"""Populate database with some process""" | |
"""Populate database with some processes""" |
Codecov Report
@@ Coverage Diff @@
## master #30 +/- ##
==========================================
+ Coverage 93.06% 93.53% +0.47%
==========================================
Files 26 27 +1
Lines 879 944 +65
==========================================
+ Hits 818 883 +65
Misses 61 61
Flags with carried forward coverage won't be shown. Click here to find out more.
Continue to review full report at Codecov.
|
.pre-commit-config.yaml
Outdated
@@ -58,6 +58,7 @@ repos: | |||
- passlib | |||
- pytest~=3.6,<5.0.0 | |||
- sphinx<4 | |||
- importlib_metadata~=4.6.1 |
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.
- importlib_metadata~=4.6.1 | |
- importlib_metadata~=4.3 |
to be inline with aiidateam/aiida-core#5058
and in setup.json
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.
@chrisjsewell I have made the changes
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.
Looks good thanks 😄
No description provided.