MCPcopy Create free account
hub / github.com/explorerhq/sql-explorer / get_uuid

Method get_uuid

explorer/models.py:420–429  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

418class ExplorerValueManager(models.Manager):
419
420 def get_uuid(self):
421 # If blank or non-existing, generates a new UUID
422 uuid_obj, created = self.get_or_create(
423 key=ExplorerValue.INSTALL_UUID,
424 defaults={"value": str(uuid.uuid4())}
425 )
426 if created or uuid_obj.value is None:
427 uuid_obj.value = str(uuid.uuid4())
428 uuid_obj.save()
429 return uuid_obj.value
430
431 def get_startup_last_send(self):
432 # Stored as a Unix timestamp

Callers 1

instance_identifierFunction · 0.80

Calls 1

saveMethod · 0.80

Tested by

no test coverage detected