import time


def mkid_series(tdex_id, xdata):
    """
    Create unique series ID
    """
    if xdata['tv'].get('debut', None):
        dyear = str(time.gmtime(float(xdata['tv'].get('debut'))).tm_year)
    else:
        dyear = "90" + str(int(time.time()))[-5:]
    idout = "%s.%s" % (tdex_id, dyear)
    return idout