-
Notifications
You must be signed in to change notification settings - Fork 37
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
Feature/document status check #376
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.
Looks good. Might be worth rebasing over main and using the core_file_uuid
from the File model now we are collecting it, and commit when it's fully working.
from redbox_app.redbox_core import models | ||
|
||
|
||
class ChunkStatus: |
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.
feels like DRF?
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.
I'm 50/50 on adding the extra weight that adding DRF will do, I'm hoping that this will be the only non-view url in the django app
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.
fair point
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.
Fully agree though that if we even think we'll add more in the future then we should add DRF, I'll raise it at tomorrows stand-up
56b1d31
to
d0a2c7c
Compare
…own of response object and raise http codes
…ject for polling document status
…xception cases and return correct object structure
@@ -104,7 +112,7 @@ def upload_view(request): | |||
) | |||
|
|||
|
|||
def injest_file(uploaded_file: UploadedFile, user: User) -> list[str]: | |||
def ingest_file(uploaded_file: UploadedFile, user: User) -> list[str]: |
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.
Doh! Sorry about that.
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.
i think this was my fault
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.
Post MVP it might be worth considering a streaming approach here rather than a polling one. Most of the pieces are in place for this on the Django side, put there for the streaming chat.
…oaded until core can be fully mocked
…us test to match other test approach
Context
Documents being uploaded should update their status as it goes through the system.
Changes proposed in this pull request
Guidance to review
To test error states
unknown
Relevant links
Things to check