def get_active_persona():
    from nucleus.models import Persona

    if 'active_persona' not in session or session['active_persona'] is None:
        """Activate first Persona with a private key"""
        controlled_persona = Persona.query.filter('sign_private != ""').first()

        if controlled_persona is None:
            return ""
        else:
            session['active_persona'] = controlled_persona.id

    return session['active_persona']
Set the upload limit.
dataset/ETHPy150Open ciex/souma/web_ui/helpers.py/get_active_persona--crossover with--dataset/ETHPy150Open correl/Transmission-XBMC/resources/lib/transmissionrpc/torrent.py/Torrent._set_upload_limit