# Path: core/exceptions.py
# class SessionException(Exception):
#     pass


from flask import current_app
from core.exceptions import SessionException
# coding: utf-8



def get_active_providers():
    return [p.info for p in current_app.database.get_active_providers()]


def get_platforms():
    return sorted(current_app.database.get_all_plaftorms_list())


def get_endpoints():
    return current_app.database.get_endpoints_dict()


def get_session(session_id):
    try:
        session = current_app.sessions.get_session(session_id)

# Path: core/exceptions.py
# class SessionException(Exception):
#     pass


# Path: vmmaster/api/helpers.py
from flask import current_app
from core.exceptions import SessionException

# coding: utf-8



def get_active_providers():
    return [p.info for p in current_app.database.get_active_providers()]


def get_platforms():
    return sorted(current_app.database.get_all_plaftorms_list())


def get_endpoints():
    return current_app.database.get_endpoints_dict()


def get_session(session_id):
    try:
        session = current_app.sessions.get_session(session_id)

    except SessionException: