<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def set_tick(self, index, interval):
 """Update the a tick's interval. Args: index (int):
 The index of the tick that you want to fetch. interval (int):
 The number of seconds between ticks. Setting this to 0 will disable the tick. Returns: int: An error code. """


        name = self.tick_name(index)
        if name is None:
            return pack_error(ControllerSubsystem.SENSOR_GRAPH, Error.INVALID_ARRAY_KEY)

        self.ticks[name] = interval
        return Error.NO_ERROR