<commit_before># -*- coding: utf-8 -*-

import os
import sys
import datetime

from sqlalchemy import Column, ForeignKey, Integer, String, DateTime, Text
from sqlalchemy.ext.declarative import declarative_base
from sqlalchemy.orm import relationship
from sqlalchemy import create_engine
from sqlalchemy.orm import sessionmaker
from sqlalchemy.orm import scoped_session
from sqlalchemy_utils import ChoiceType

import autocloud

Base = declarative_base()


class ComposeJobDetails(Base):
    __tablename__ = 'compose_job_details'

    STATUS_TYPES = (
        ('s', 'Success'),
        ('f', 'Failed'),
        ('a', 'Aborted'),
        ('r', 'Running'),
        ('q', 'Queued')
    )

    IMAGE_FAMILY_TYPES = (
        ('b', 'Base'),
        ('a', 'Atomic')
    )

    ARCH_TYPES = (
        ('i386', 'i386'),
        ('x86_64', 'x86_64')
    )

    id = Column(Integer, primary_key=True)
    arch = Column(ChoiceType(ARCH_TYPES))
    compose_id = Column(String(255), nullable=False)
    created_on = Column(DateTime, default=datetime.datetime.utcnow)
    family = Column(ChoiceType(IMAGE_FAMILY_TYPES))
    image_url = Column(String(255), nullable=False)
    last_updated = Column(DateTime, default=datetime.datetime.utcnow)<commit_msg>Keep the old job details table<commit_after># -*- coding: utf-8 -*-

import os
import sys
import datetime

from sqlalchemy import Column, ForeignKey, Integer, String, DateTime, Text
from sqlalchemy.ext.declarative import declarative_base
from sqlalchemy.orm import relationship
from sqlalchemy import create_engine
from sqlalchemy.orm import sessionmaker
from sqlalchemy.orm import scoped_session
from sqlalchemy_utils import ChoiceType

import autocloud

Base = declarative_base()


class JobDetails(Base):
    __tablename__ = 'job_details'

    STATUS_TYPES = (
        ('s', 'Success'),
        ('f', 'Failed'),
        ('a', 'Aborted'),
        ('r', 'Running'),
        ('q', 'Queued')
    )

    IMAGE_FAMILY_TYPES = (
        ('b', 'Base'),
        ('a', 'Atomic')
    )

    ARCH_TYPES = (
        ('i386', 'i386'),
        ('x86_64', 'x86_64')
    )

    id = Column(Integer, primary_key=True)
    taskid = Column(String(255), nullable=False)
    status = Column(ChoiceType(STATUS_TYPES))
    family = Column(ChoiceType(IMAGE_FAMILY_TYPES))
    arch = Column(ChoiceType(ARCH_TYPES))
    release = Column(String(255))
    output = Column(Text, nullable=False, default='')
    created_on = Column(DateTime, default=datetime.datetime.utcnow)
    last_updated = Column(DateTime, default=datetime.datetime.utcnow)
    user = Column(String(255), nullable=False)


class ComposeJobDetails(Base):
    __tablename__ = 'compose_job_details'

    STATUS_TYPES = (
        ('s', 'Success'),
        ('f', 'Failed'),
        ('a', 'Aborted'),
        ('r', 'Running'),
        ('q', 'Queued')
    )

    IMAGE_FAMILY_TYPES = (
        ('b', 'Base'),
        ('a', 'Atomic')
    )

    ARCH_TYPES = (
        ('i386', 'i386'),
        ('x86_64', 'x86_64')
    )

    id = Column(Integer, primary_key=True)
    arch = Column(ChoiceType(ARCH_TYPES))
    compose_id = Column(String(255), nullable=False)
    created_on = Column(DateTime, default=datetime.datetime.utcnow)
    family = Column(ChoiceType(IMAGE_FAMILY_TYPES))
    image_url = Column(String(255), nullable=False)
    last_updated = Column(DateTime, default=datetime.datetime.utcnow)
{'fraction_non_alphanumeric': 0.13337285121517486, 'fraction_numerical': 0.01926496739774748, 'mean_word_length': 3.5, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6771466', 'n_tokens_mistral': 1174, 'n_tokens_neox': 1104, 'n_words': 236}