@classmethod
  def Create(cls, **analytics_dict):
    """Create a new analytics object with fields from 'analytics_dict'. Sets timestamp if not
    specified. Payload may be empty.
    """
    create_dict = analytics_dict
    if 'timestamp' not in create_dict:
      create_dict['timestamp'] = util.GetCurrentTimestamp()

    entity = create_dict['entity']
    entry_type = create_dict['type']
    if entry_type.startswith('User.'):
      assert entity.startswith('us:'), create_dict % 'Wrong entity string for type User.*: %r'

    # Always store as int, floats cause problems as sort keys.
    create_dict['timestamp'] = int(create_dict['timestamp'])
    create_dict['sort_key'] = Analytics.CreateSortKey(create_dict['timestamp'], create_dict['type'])

    return cls.CreateFromKeywords(**create_dict)
dataset/ETHPy150Open viewfinderco/viewfinder/backend/db/analytics.py/Analytics.Create/swapped operands of `%`