-
Notifications
You must be signed in to change notification settings - Fork 0
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
story/VOGRE-7 #15
base: develop
Are you sure you want to change the base?
story/VOGRE-7 #15
Conversation
…ngo inlinecss) and added collectstatic
…to fix import for text tor repository
…ory text import for importing and repository text for details
annotations/middleware.py
Outdated
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 don't think this is the right approach. It is likely to cause memory issues once there are sufficiently many relationsets. It also seems unnecessary. The only time we care about the readiness of a relation to be submitted is when we want to submit them or maybe when we look at a text. So it really only needs to be checked when the page shows all relations, and then only the relations that are relevant (not all of them).
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 don't think this is the right approach. It is likely to cause memory issues once there are sufficiently many relationsets. It also seems unnecessary. The only time we care about the readiness of a relation to be submitted is when we want to submit them or maybe when we look at a text. So it really only needs to be checked when the page shows all relations, and then only the relations that are relevant (not all of them).
If we only show the relations that can be submitted, then the user will not be able to see all relations that they have created on the text. Can we still show the relations that cannot be submitted with the disabled checkbox? I'll change the way we check for ready relations.
annotations/utils.py
Outdated
} | ||
} | ||
|
||
|
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.
these two functions are specific to the quadriga api, aren't they? They should not be in the annotations util file.
annotations/views/rest_views.py
Outdated
return Response({'error': 'You are not authorized to submit this RelationSet.'}, | ||
status=status.HTTP_403_FORBIDDEN) | ||
|
||
if relationset.status != 'ready_to_submit': |
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.
this still
annotations/views/rest_views.py
Outdated
return Response({'error': 'You are not authorized to submit this RelationSet.'}, | ||
status=status.HTTP_403_FORBIDDEN) | ||
|
||
if relationset.status != 'ready_to_submit': |
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.
and everywhere else where these strings are used
concepts/tasks.py
Outdated
# logger.debug("Resolve concept failed: %s" % str(E)) | ||
# return | ||
# logger.debug("Resolved concept %s" % manager.instance.uri) | ||
pass |
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.
remove commented out code
@@ -1,5 +1,4 @@ | |||
from __future__ import absolute_import | |||
|
|||
# This will make sure the app is always imported when | |||
# Django starts so that shared_task will use this app. | |||
from .celery import app as celery_app | |||
# Django starts so that shared_task will use this 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.
are these comments still valid?
Resolve conflicts please |
… Remove middleware, complete get queryset method
Can one of the admins verify this patch? |
Resolve conflicts please |
Guidelines for Pull Requests
If you haven't yet read our code review guidelines, please do so, You can find them here.
Please confirm the following by adding an x for each item (turn
[ ]
into[x]
).Please provide a brief description of your ticket
Get rid of celery and submit quaduples on request
Description
Currently, quadruples are submitted via Celery on a cron job. Celery should be completely removed. Instead a project should have a button that will submit quadrupes to Quadriga. This ticket includes multiple tasks:
Quadruples need to have a flag (if they don’t already) that indicates if they ahve been submitted or not
Quaduples need to be submitted to the new Quadriga 2.0
Only quadruples with complete relationships (in which concepts have been resolved and added to conceptpower) should be submitted.
VOGRE-7
Are there any other pull requests that this one depends on?
VOGRE-14
Anything else the reviewer needs to know?
Since VOGRE-14 has url changes which also affect
annotator
andannotator factory
this PR will require changes once VOGRE-14 merged.