Did I find the right examples for you? yes no

All Samples(32)  |  Call(17)  |  Derive(0)  |  Import(15)

src/b/o/bodhi-HEAD/tools/pickledb.py   bodhi(Download)
 
    import transaction
    from bodhi.models import DBSession, Base
    from bodhi.models import Release, Update, Build, Comment, User, Bug, CVE
    from bodhi.models import Package, Group

src/b/o/bodhi-HEAD/alembic/versions/387fda7a1ff0_default_update_sever.py   bodhi(Download)
import transaction
 
from bodhi.models import Base, DBSession, Update, UpdateSeverity
 
 

src/b/o/bodhi-HEAD/alembic/versions/1eb754722e44_default_update_critp.py   bodhi(Download)
import transaction
 
from bodhi.models import Base, DBSession, Release, Update
from bodhi.util import get_critpath_pkgs
 

src/b/o/bodhi-HEAD/alembic/versions/18cad09c8ab6_default_update_sugge.py   bodhi(Download)
import transaction
 
from bodhi.models import Base, DBSession, Update, UpdateSuggestion
 
 

src/b/o/bodhi-HEAD/bodhi/__init__.py   bodhi(Download)
def get_dbsession(request):
    from bodhi.models import DBSession
    return DBSession()
 
 
def main(global_config, testing=None, **settings):
    """ This function returns a WSGI application """
    from bodhi.models import DBSession, Base
    engine = engine_from_config(settings, 'sqlalchemy.')
    DBSession.configure(bind=engine)

src/b/o/bodhi-HEAD/alembic/versions/343bb26e7012_default_update_pushe.py   bodhi(Download)
import transaction
 
from bodhi.models import Base, DBSession, Update
 
 

src/b/o/bodhi-HEAD/bodhi/tests/functional/base.py   bodhi(Download)
 
from bodhi import main
from bodhi.models import (
    Base,
    Bug,
    def populate(self):
        session = DBSession()
        user = User(name=u'guest')
        session.add(user)
        provenpackager = Group(name=u'provenpackager')

src/b/o/bodhi-HEAD/bodhi/tests/functional/test_updates.py   bodhi(Download)
from bodhi import main
from bodhi.config import config
from bodhi.models import (
    Base,
    Bug,
    def test_no_privs(self):
        session = DBSession()
        user = User(name=u'bodhi')
        session.add(user)
        session.flush()
    def test_provenpackager_privs(self):
        "Ensure provenpackagers can push updates for any package"
        session = DBSession()
        user = User(name=u'bodhi')
        session.add(user)
 
        # Now approve one
        session = DBSession()
        session.query(Update).first().date_approved = now
        session.flush()
 
        # Now approve one
        session = DBSession()
        session.query(Update).first().date_modified = now
        session.flush()

src/b/o/bodhi-HEAD/bodhi/tests/functional/test_comments.py   bodhi(Download)
from bodhi import main
from bodhi.config import config
from bodhi.models import (
    Base,
    Bug,
    def test_invalid_update(self):
        session = DBSession()
        res = self.app.post_json('/comments/', self.make_comment(
            update='bodhi-1.0-2.fc17',
        ), status=404)
 
        # Now change the time on one to tomorrow
        session = DBSession()
        session.query(Comment).first().timestamp = tomorrow
        session.flush()

src/b/o/bodhi-HEAD/bodhi/tests/functional/test_users.py   bodhi(Download)
 
from bodhi import main
from bodhi.models import (
    Base,
    Bug,
    def setUp(self):
        super(TestUsersService, self).setUp()
 
        session = DBSession()
        user = User(name=u'bodhi')
    def test_list_users_by_update_alias(self):
        session = DBSession()
        update = session.query(Update).first()
        update.alias = 'some_alias'
        session.flush()

  1 | 2  Next