Skip to content

Commit

Permalink
Merge pull request #11390 from bjester/concurrent-learner-servers
Browse files Browse the repository at this point in the history
Sequential learner syncing
  • Loading branch information
marcellamaki authored Oct 27, 2023
2 parents c60a31b + cead128 commit b06cfe2
Show file tree
Hide file tree
Showing 22 changed files with 1,061 additions and 1,336 deletions.
9 changes: 2 additions & 7 deletions kolibri/core/auth/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,7 @@
from kolibri.core.auth.constants.morango_sync import ScopeDefinitions
from kolibri.core.device.utils import device_provisioned
from kolibri.core.device.utils import get_device_setting
from kolibri.core.device.utils import is_full_facility_import
from kolibri.core.device.utils import set_device_settings
from kolibri.core.errors import KolibriValidationError
from kolibri.core.fields import DateTimeTzField
Expand Down Expand Up @@ -872,13 +873,7 @@ def full_facility_import(self):
"""
Returns True if this user is a member of a facility that has been fully imported.
"""
return (
Certificate.objects.get(id=self.dataset_id)
.get_descendants(include_self=True)
.exclude(_private_key__isnull=True)
.filter(scope_definition_id=ScopeDefinitions.FULL_FACILITY)
.exists()
)
return is_full_facility_import(self.dataset_id)

@cached_property
def full_facility_on_my_own_setup(self):
Expand Down
Loading

0 comments on commit b06cfe2

Please sign in to comment.