Did I find the right examples for you? yes no      Crawl my project      Python Jobs

All Samples(5)  |  Call(5)  |  Derive(0)  |  Import(0)

src/p/y/pyrone-1.1.2/pyrone/views/blog.py   pyrone(Download)
            article.user_id = user.id
            dbsession.add(article)
            dbsession.flush()  # required as we need to obtain article_id
 
            article_id = article.id
    dbsession.add(comment)
    _update_comments_counters(dbsession, article)
    dbsession.flush()
    dbsession.expunge(comment)  # remove object from the session, object state is preserved
    dbsession.expunge(article)
 
    comment.published = h.str_to_timestamp(request.POST['date'])
    dbsession.flush()
 
    #comment_user = None

src/p/y/pyrone-1.1.2/pyrone/views/admin.py   pyrone(Download)
 
    dbsession.add(file)
    dbsession.flush()
    dbsession.expunge(file)
 

src/p/y/pyrone-1.1.2/pyrone/views/account.py   pyrone(Download)
 
    if is_changed:
        dbsession.flush()
        dbsession.expunge(user)
        user.get_roles()