V2EX = way to explore
V2EX 是一个关于分享和探索的地方
Sign Up Now
For Existing Member  Sign In
miniyao
V2EX  ›  Flask

求助,那位同学有看过这个视频 four sqlalchemy tips,可以贴下 Tips 吗?

  •  
  •   miniyao · Nov 10, 2019 · 1359 views
    This topic created in 2363 days ago, the information mentioned may be changed or developed.
    光头老师的 video: four sqlalchemy tips,视频地址:youtu.be/5-4W3m5gRAs

    今天的梯子挂了,国内好像还没搜到这个视频的搬运
    3 replies    2019-11-10 14:38:41 +08:00
    gwy15
        1
    gwy15  
       Nov 10, 2019
    复制粘贴:
    1st -> 1:33
    -> when you should commit() your database session
    2nd -> 7:20
    -> three attributes of the session you probably don't know about (new, deleted, dirty) sounds great for all tracking of changes to objects
    3rd -> 11:08
    -> related to 2nd regarding when these 3 lists are cleaned and when the db session is cleared in Flask SQLAlchemy; remove() method of the session; how does it affect long-running tasks (e.g celery); be aware of memory usage
    4th -> 14:09 -> nice way for handling db.session.remove() and keeping clean the session via context manager.
    gwy15
        2
    gwy15  
       Nov 10, 2019
    另外提供自动生成的字幕
    https://c-t.work/s/c6ef099beefe4f
    miniyao
        3
    miniyao  
    OP
       Nov 10, 2019
    @gwy15 这个机翻的坑有点多
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Solana   ·   2507 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 39ms · UTC 15:38 · PVG 23:38 · LAX 08:38 · JFK 11:38
    ♥ Do have faith in what you're doing.