from collections import OrderedDict


NOTEBOOK_JOB_CONFIGURATION = {'module': 'main', 'package_path': None, 'package_manager': 'pip',
                              'requirements': 'requirements.txt', 'time_limit': 2880, 'datasets_set': [], 'code': None,
                              'code_commit': 'some_hash', 'module_arguments': {}, 'framework': {'slug': 'jupyter'},
                              'python_version': '2.7', 'mode': 'single', 'workers': {'slug': 't2.small', 'replicas': 1},
                              'name': 'snowy-surf-115', 'description': ''}

NOTEBOOK_API_RESPONSE = OrderedDict([
    ('job_id', '853b9f10-36ce-4de4-b2f8-108d69733b42'),
    ('repository', None),
    ('repository_owner', None),
    ('repository_name', None),
    ('repository_owner_photo_url', None),
    ('display_name', 'winter-leaf-119'),
    ('description', ''),
    ('created_at', '2018-05-08T11:32:26.354821Z'),
    ('launched_at', None),
    ('terminated_at', None),
    ('modified_at', '2018-05-08T11:32:26.365201Z'),
    ('current_time_left_percentage', 0),
    ('datasets_set', []),
    ('members', [OrderedDict([
        ('id', 12044),
        ('access', 50),
        ('access_level', 'owner'),
        ('status', 'AC'),
        ('user', 795),
        ('username', 'allgreed'),
        ('photo_url',
         'https://tensorport-api-development.s3.amazonaws.com/images/empty_image_400_400.png'
         ),
        ('email', 'whatever@example.com'),
        ('first_name', 'John'),
        ('last_name', 'Kowalsky'),
    ])]),
    ('total_running_time', 0),
    ('unpaid_running_time', 0),
    ('git_commit_hash', 'some_hash'),
    ('git_commit', None),
    ('created_by', 795),
    ('logs', None),
    ('current_run', None),
    ('runs', []),
    ('tags', []),
    ('user_panel', None),
    ('status', 'created'),
    ('parameters', OrderedDict([
        ('framework', OrderedDict([('slug', 'jupyter'), ('name',
                                                         'jupyter'), ('version', '1.0.0')])),
        ('python_version', '2.7'),
        ('package_manager', 'pip'),
        ('mode', 'notebook'),
        ('requirements', 'requirements.txt'),
        ('time_limit', 2880),
        ('package_path', ''),
        ('module_arguments', OrderedDict()),
        ('module', 'main'),
        ('datasets', []),
        ('workers', OrderedDict([('slug', 't2.small'), ('replicas', 1),
                                 ('queue', 'tensorport-jobmaster-blessed'), ('type', 't2.small'
                                                                             ), ('blessed', True)])),
        ('token', '85c88d21-fb18-42be-8a1a-f73da4585a02'),
    ])),
    ('resources', None),
    ('notebook_url',
     'http://853b9f10-36ce-4de4-b2f8-108d69733b42.jupyter.v2.clusterone.com'
     ),
])
