-
Notifications
You must be signed in to change notification settings - Fork 3.2k
fix: FIT-1073: Deleted all tasks but one in Done, project still in Annotating #8932
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
base: develop
Are you sure you want to change the base?
Conversation
✅ Deploy Preview for heartex-docs canceled.
|
✅ Deploy Preview for label-studio-storybook canceled.
|
✅ Deploy Preview for label-studio-docs-new-theme canceled.
|
✅ Deploy Preview for label-studio-playground canceled.
|
label_studio/tasks/models.py
Outdated
| instance.project.update_tasks_states( | ||
| maximum_annotations_changed=False, | ||
| overlap_cohort_percentage_changed=False, | ||
| tasks_number_changed=True, | ||
| ) | ||
| # FSM: Recalculate project state after a single task deletion (signal-based path) via settings | ||
| from core.utils.common import load_func | ||
|
|
||
| update_func = load_func(settings.FSM_UPDATE_PROJECT_STATE_AFTER_TASK_CHANGE) | ||
| update_func(instance.project, user=getattr(instance, 'updated_by', None)) |
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.
We already had an update running here, I guess the same question as above?
| project.update_tasks_states( | ||
| maximum_annotations_changed=False, overlap_cohort_percentage_changed=False, tasks_number_changed=True | ||
| ) | ||
| # FSM: Recalculate project state after deletion/unlink using swappable setting | ||
| update_func = load_func(settings.FSM_UPDATE_PROJECT_STATE_AFTER_TASK_CHANGE) | ||
| update_func(project, user=user) |
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.
We already had a project update running here, is there something wrong with the update_tasks_states function? Is that an FSM-based function, or what is that doing?
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.
It predates FSM, it updates task counters in the project. It also runs async in Redis, so I need to do some thinking about whether this new update is best done sync or async.
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## develop #8932 +/- ##
============================================
+ Coverage 65.93% 81.34% +15.40%
============================================
Files 828 267 -561
Lines 64588 24049 -40539
Branches 10984 0 -10984
============================================
- Hits 42585 19562 -23023
+ Misses 21999 4487 -17512
+ Partials 4 0 -4
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
|
/git merge develop
|
|
/git merge develop
|
|
/git merge develop
|
|
/fmt |
|
/fmt |
|
Realized this is more complex than I thought while using the async job - have to plumb |
|
/fmt |
…d_task_states everywhere" This reverts commit 8f92a5e.
6065053 to
02609ee
Compare
|
/git merge develop
|
|
/git merge develop
|
|
/git merge develop
|
|
/git merge develop
|
|
/git merge develop
|
|
/git merge develop
|
FSM bugfix