# Initial attempt at a task definition. This is the data structure -
# the parsing and interpreting code is elsewhere
import enum
import logging
import emission.core.wrapper.wrapperbase as ecwb

class ParticipantType(enum.Enum):
    INDIVIDUAL = 0
    GROUP = 1
    # TODO: Eventually we should support an "org" level as well, so that
    # we can do an inter-campus challenge, for example. Too advanced
    # for this time, though

class Task(ecwb.WrapperBase):
    props = {
        # The mapper from the metrics to habitica points.
        # Is the name of a function - the function can be fairly complex
        # Takes in the curr_state and returns the new_state
                "mapper": ecwb.WrapperBase.Access.RO,
                "args": ecwb.WrapperBase.Access.RO,
                # unique id for this task. Generated by habitica, which is the source of truth
                "task_id": ecwb.WrapperBase.Access.WORM,
                "habitica_task": ecwb.WrapperBase.Access.WORM
            }

    enums = {"type": ParticipantType}
    geojson = []
    nullable = []
    local_dates = []

    def _populateDependencies(self):
        pass

